How to add user on Embedded System


 
Thread Tools Search this Thread
Top Forums UNIX for Advanced & Expert Users How to add user on Embedded System
# 1  
Old 01-04-2007
How to add user on Embedded System

The directions below were provided by someone on the unslung mailing list. unslung is a linux OS for LinkSys's $100 NSLU2 NAS controller.

I'm posting the query here because
(1) I think it is really a generic linux/unix questions
(2) I did not get a response in the unslung mailing list.

I thought it was standard to put user "siegfried"'s directory the users in /home/siegfried but Lance (the author of the instructions below) claims /home/user/siegfried is the convention he is going to follow.

So after creating /home/user with the root account, what "chown" or "chmod" (or other commands) do I want to apply to /home/user so that when I log in as siegfried, I can be in the /home/user/siegfried account?

Thanks,
siegfried
-----------------------------------------------------------------------

Here is my original post to the nslu2-general mailing list:

>
># mkdir /home/user/xyz
># mkdir /home/user/xyz/src
># mkdir /home/user/xyz/bin
>
>To make xyz the owner of this directory, and its contents:
>
># chown -R xyz /home/user/xyz
>
>In order to give xyz a way to execute the gcc compiler which you have
>installed, and other programs, create a file called .profile
>(Commands for the vi editor may be found at
>http://www.chem.brown.edu/instructions/vi.html):
>
># vi /home/user/xyz/.profile
>("i" enters insert mode,
>type "PATH=/bin:/sbin:/opt/bin:/opt/sbin:/home/user/xyz/bin" (without
>quotes), <ESC>, ZZ (to save and exit))
>
>Next modify the password file to change the home directory of xyz,
>and to use the bash shell
>
># vi /etc/passwd
>
>Edit the xyz line to replace the text after the second-to-last colon
>(":") with "/home/user/xyz:/sbin/bash"
>
>When you've exited vi, you can use the following command to print the
>file to the screen to see that it looks right
>
># cat /etc/passwd
>
>Now you can login to xyz and enter your password
>
># login xyz
>
Here is what I get:
bash-3.2$ ssh -p 22 root@10.169.1.10
root@10.169.1.10's password:
Welcome to Unslung V2.3R63-uNSLUng-6.8-beta
---------- NOTE: THIS SYSTEM IS CURRENTLY UNSLUNG ----------
BusyBox v0.60.4 (2005.03.22-06:52+0000) Built-in shell (ash)

Enter 'help' for a list of built-in commands.

# login siegfried

Password:
No directory, logging in with HOME=/
Welcome to Unslung V2.3R63-uNSLUng-6.8-beta
---------- NOTE: THIS SYSTEM IS CURRENTLY UNSLUNG ----------
BusyBox v0.60.4 (2005.03.22-06:52+0000) Built-in shell (ash)
Enter 'help' for a list of built-in commands.

$

I cannot cd into /home/user/siegfried

I tried doing chmod 777 /home/user but this did not help!

What am I doing wrong?

Thanks,

Siegfried
# 2  
Old 01-06-2007
There are several standards whether /home/siegfried or /home/user/siegfried doesn't matter. But you need to pick something and stick with it. Do this command:
grep siegfried /etc/passwd
to see where the system thinks the directory should be. And siegfried should own his home directory.
chown siegfried /home/user/siegfried

There are differing standards on permissions...my choice:
chmod 755 /home/user/siegfried

Just remember that the directory must agree with what is in /etc/passwd.
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

How to know which user is messing up with the system?

Hello, In our environment some users mess up with the system ( install / uninstall ) software.. unfortunately the root is open to several users (several of them have sudo access) How to track which user is trying to do this ( I'd like to know which user and what ipaddress. ) Experts please... (2 Replies)
Discussion started by: ramky79
2 Replies

2. BSD

single user mode under system v

Hello! I am new to the forum and I need help on restoring root user's password or access the form of single user mode under operating system very long-standing family bsd - Unix system V I think it's also called srv4. I managed to enter the owner of IPL, and a moment after the rise of system... (2 Replies)
Discussion started by: hmalool
2 Replies

3. Shell Programming and Scripting

find a user on the system

i am prompting for a name to search. read user if then however, i get this error: please enter a username on the system: fool menu_script2.sh: line 123: (4 Replies)
Discussion started by: icelated
4 Replies

4. Shell Programming and Scripting

Problem with embedded FTP command in Ksh - System Cannot find the specified path.

I have the following FTP embedded in a Ksh script on AIX 5.3 ftp -n <<WHATEVER open 10.101.26.218 user hcistats ******* ascii put $thupdatefile put $thcollectfile quit WHATEVER Here is what my script returns: ... (3 Replies)
Discussion started by: troym72
3 Replies

5. UNIX for Dummies Questions & Answers

Compiling Kernel for an Embedded System

-----Edit----- My original post was long and confusing. To sum it up, I am wondering how to do the following Debian based commands on an RPM type system. dpkg -i XXX.deb update-initramfs -k xxx -c update-grub I hope someone can provide some insight. Thanks in advance! --------------... (0 Replies)
Discussion started by: b4sakenxx
0 Replies

6. Solaris

add administrator user to system

Hello I have a new job and I need change the last user administrator, I dont know if is easier change some things about this user or add my user in the group with every permission, how can I do it. I dont know which is the group. I think is no only useradd en after modify /etc/passwd. Tank... (14 Replies)
Discussion started by: cata
14 Replies

7. Solaris

diff b/w /etc/system and user profile..

Hi Everybody, Can somebody tell me the difference between /etc/system and user profile???? (2 Replies)
Discussion started by: tirupathiraju_t
2 Replies

8. UNIX for Advanced & Expert Users

user is not able to FTP to system.

Helo, I have created one group called RBAC.(roll back access control) Now when I created user of RBAC its entry in /etc/passwd file is given below: roleadm:x:120:109:RBAC User:/home/pds_RBAC:/bin/false I have keep at the end /bin/false because I dont want to give direct login to the user... (2 Replies)
Discussion started by: amitpansuria
2 Replies

9. Solaris

How to check the last login user were doing in the system

Hi, I'm new to solaris/ Unix and would like to know how to check in the system what was the last login user were doing. Is there any way to check this? Thanks in advanced. (1 Reply)
Discussion started by: raziayub
1 Replies

10. UNIX for Dummies Questions & Answers

kicking a telneted user from the system

hi there, does anyone know how to kick a telneted user from a the system? thx (3 Replies)
Discussion started by: crashnburn
3 Replies
Login or Register to Ask a Question