Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
"passwd -d username" works for command line (I tried on Arch i686 running bash 4.0.033 and kernel 2.6.30.6)
To login with gdm you need to use jonmcc's trick, except on my box the string that worked was "U6aMy0wojraho" (based on http:/ /ubuntuforums.org/archive/index.php/t-1003549.html), this most likely depends on the hash algorithm you use.
I have to agree with cenzole and rvega. The reason for adding a user without a password is not relevant. Either you know how to do it or don't respond. This post (like others) is entirely too long with opinions about whether it's a good ideal or not and short on answering the question. I used homey method and it works the way I need it to (to setup a linux laptop for a 3 yr. old if that really is important to know to answer the question. I suppose I could teach him how to remember his password right after he learns the alphabet). homey stated that cenzole response was impolite, but is it really impolite to tell people that what they are asking for isn't relevant (when it isn't)? This is way people perceive the Linux community as unfriendly.
Minimum Password Age to 0
Maximum Password Age to 99999
Password Inactive to -1
Account Expiration Date to -1
the following will tell you the settings of your user so you can see what needs to be set or changed:
Code:
chage -l username
I guess this doesn't tell you how to create a user without a password, but it will allow you to disable the password on an existing account. I know this is an old thread, but I hope someone can find it useful.
I believe that adduser command with --disabled-password may be specific to Debian and distros based on it, j0hnsmith. The standard useradd command doesn't have a --disabled-password option. Neither does the adduser script packaged with some other distros, such as Slackware.
Assuming that you don't have an adduser command with --disabled-password option, a more general method is to create an account in the normal way and give it a password, then edit /etc/passwd to remove the first x right after the username.
This is what mop was alluding to in post #15, although I wouldn't use his method.
The easy way is to create the the account in the normal fashion with a password, then use the passwd command to remove it with the -d option.
A user without a password might open a security hole on your computer at the very least, but after you have considered it, there is actually some useful places where you want this.
Places where you might want an open door:
Imagine a computer in an information area. It might crash or there might be a power outage. Situations where you want this very limited user have limited access upon startup, but still login without your password each time. It could just be for browser access with a homepage locked on a certain page.
There is also the situation with wine, where you might wish to share a Windows game between users and not spend 10% of your hard disk for each user (this will run out fast, not to mention any quota you might have set for users). Wine itself doesn't have a lot of options to allow it and it denies direct access to the WINEPREFIX for other users, however the drives are accessible. It might be a good idea with a password-less user for write access though. That is the why I ended up here. Looks like https://ubuntuforums.org/showthread.php?t=917422 provides some information.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.