Hi all,
I have a problem, when I use script with 'expect', accidentally I was deleted root account by "userdel root". Unfortunately, it works, because no other root user login on it. Solaris document said that root cannot delete root, but in my case it works because it deleted by script, not physically log in.
My question is: how to restore my root account? I can log in using other account, but not root and no other account have privilege as root.
Any help would be appreciated. Thank you
boot from cd/dvd and create the root account again. haven't done something like that but i would try to copy the information for /etc/passwd and /etc/shadow from another machine.
Thanks DukeNuke2 for your help, I will try it.
But, could you please share to me, how the steps and to create again? only using 'useradd' ? or other command? or just add root line at /etc/passwd and /etc/shadow ?
Thank you
Ok boot into solaris into solaris failsafe login , this will boot mini root
then mount FS on /a
then execute sys-unconfig
answer on few questions and you will be promoted to enter password for root , follow instructions , reboot PC and your root account maybe will be backed
Dear Joash, Kindly take note, before you post a question, please do a search within the forum on your query. There are plenty of such examples for you to refer from.
Thanks. This is part of the forum rules