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.
I am taking a class in Linux and we are kind of winging it, so I could really use some help.
I am trying to practice adding users, creating files, and all of the other basic things. I am using Ubuntu Linux - Feisty Fawn. To add a user I logged in as root, added her with a home directory, and gave her a password. My problem is when I try to log in as her. I have tried using login <user> as well as su <user>, but neither of them lists the full location of the user when I do this. All I get is this:
$
The prompt is there, and it seems I am able to do things, but then when I do things like make a file, (vi <file>) the file doesn't seem to save right, and funny things like that. Can someone tell me if I am missing something?
I do not use Ubuntu but I believe user management should be similar on all *nix systems. Anyway, please post what commands you used to create the user. When you get the "$" prompt after logging in as that user, please do the following and post the results:
$ pwd
$ ls -a
$ env | grep HOME
$ echo $PS1
Also, I think you should use "su - <userid>" instead of just "su <userid>". I believe "su - <userid>" make sure the shell inherit all the environment variables of the new user. Might be someone with more knowledge confirm this. Thanks.
I do not use Ubuntu but I believe user management should be similar on all *nix systems. Anyway, please post what commands you used to create the user. When you get the "$" prompt after logging in as that user, please do the following and post the results:
$ pwd
$ ls -a
$ env | grep HOME
$ echo $PS1
Also, I think you should use "su - <userid>" instead of just "su <userid>". I believe "su - <userid>" make sure the shell inherit all the environment variables of the new user. Might be someone with more knowledge confirm this. Thanks.
I have the same question! I think this is Nice answer, I'll try this
thanks for sharing!
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.