This is a discussion on How to add a user to redhat ?????? within the Shell scripting forums, part of the Development/Scripting category; I have used adduser command with various options to add a user. And it is also get replect in /etc/passwd ...
|
|||||||
| Register | FAQ | Members List | Calendar | Forgotten your password? | Mark Forums Read |
|
|||
|
I have used adduser command with various options to add a user. And it is also get replect in
/etc/passwd file. But whenever I login it says that incorrect username or password. Is there any shellscript for that ????? |
| Sponsored Links | ||
|
|
|
|||
|
I have written the code like that :::::
user is added but I m not able to login. echo "enter the name of user " read user; echo " enter the user id" read uid; echo " enter the group id" read gid; echo "enter the home directory" read home echo "enter the shell script" read shell echo "enter the password" read password grep $user /etc/passwd > /dev/null if [ $? -eq 0 ]; then adduser -u $uid -g $gid -d $home -s $shell -p $password $user else echo "$user already exist" fi |
|
|||
|
I go for command icon in Redhat but no manual entry for this command. If you have
written the shell script for deleting user the definitely u wld have been having shell script for adding user. And u wd have been logged in to the system after adding user. Please le me know in detail. |
![]() |
| Bookmarks |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) |
|
| Thread Tools | |
| Display Modes | |
|
|
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Add normal user / FTP user usein NORMAL user(non-root) | anilvrathod | Shell scripting | 0 | 12-07-2007 07:04 PM |
| how to enable a user and disabling a user | narasimha.reddygnv | Shell scripting | 1 | 03-31-2007 01:31 AM |