Restore root user in suse10

Publication Date:  2012-09-20 Views:  102 Downloads:  0
Issue Description
When connecting with client vulnerability scan program, system cannot switch to root user which is unavailable.
Alarm Information
Handling Process
Using installation CD-ROM booting system, and we should press “ALT” to select Linux rescue at the beginning.
Rescue login# root
Check disk partition:
Rescue# fdisk -l
Device Boot      Start         End        Blocks         Id     System
/dev/sda1               1         1024      1048560      82    Linux swap
/dev/sda2            1025     11264    10485760   83    Linux

Mount disk partition:
Rescue# mount -n / -o remount,rw
Rescue# mount /dev/sda2 /mnt
Rescue# mount -o bind /dev  /mnt/dev

Enter /etc/passwd and add:

Save and set root password. Rebooting server can make it normal.
Root Cause
After consulting technologists, we know that the root user is deleted by this program with command “userdel root”.