Hi All,
I am new to shell scripting and have a task which need to be completed ASAP.
I have searched all the forum and couln't find excat script which could run on solaris.can someone give me the fully working script for below.
Bash shell script to create user account with paraments as below.
useradd -c "${FNAME} ${LNAME}" -d ${HOMEDIR}/${USERNAME} -m -g ${PRIGROUP} -s ${USERSHELL} ${USERNAME} > /dev/null \
|| exit 1
user should be added to /etc/passwd and I am wondering what could be the command to add password to /etc/shadow, if possible please include that in the script.
If the user already exits then exit from the script otherwise add user.
Thanks in Advance