herewith is my script
BUT now if a change is made on the database, and the script is run, script does not pick up changes...and does not make any amendments in /etc/passwd file
any ideas?????
Code:
FILE1=$ORACLE_SQL
FILE2=/etc/passwd
cp $FILE2 /etc/passwd.$$.orig
while IFS=":" read user comment
do
user=$(echo $user | tr -d ' ')
[ -z "$(awk -F: "/^$user:/"' && $5 == "" {print $2}' $FILE2)" ] || usermod -c "$
comment" $user
done <$FILE1
BUT now if a change is made on the database, and the script is run, script does not pick up changes...and does not make any amendments in /etc/passwd file
any ideas?????