![]() |
Linux user location/directoires
Hi,
I need to create a user. I know it sounds simple but I'm having a slight issue with it. For example I want to create user1 with home location of /home/projects/user1. I went ahead and created the projects directory using mkdir under /home, and also user1 directory under /projects, but whenever I use the ls -l command to check the structure, the user1 shows under home and nothing under /home. I'm not sure What I'm doing wrong. Also if I wanted to create a directory under user1, should I simply type: mkdir /home/projects/user1/usrdir ??? Is there a better or simpler way? I still a newbie, so please if anyone could point me at the right direction, I would really appreciate it. Thanks in advance. |
Is the desired home directory /home/projects/user1 or /projects/user1?
How did you use vi to create /projects/user1? What is the output of tree -d -L 1 / and tree -d -L 1 /home ? Yes, mkdir /home/projects/user1/usrdir is a good way to create that directory, best done as user1 to get the right ownerships. Alternatively you could do it using a graphical file manager. |
Let's say you begin with only the /home directory and didn't yet create /home/projects nor its sub-directories
Let me quote "man mkdir": Code:
NAMECode:
mkdir -p /home/projects/user1/usrdir |
Sorry for the typo, and thanks
Sorry for the typo, I had vi in my mind at the time I typed the question. I think I figured out most of it. in fedora linux, whenever you create a new user, it by default puts it under the /home directory. Everything made sense after that. Thanks guys for your input. I appreciate it.
|
Quote:
|
| All times are GMT -5. The time now is 12:04 PM. |