System Recovery Techniques
How to check running and stop services at run level :
# cd /etc/rc5.d // To check at run level 5
# ls -ltr
Output :
K01......
K02......
K03......
.........
.........
.........
.........
S01......
S02......
.........
.........
K = Kill, service will be stopped on the current run level
S = Start, service will start on the current run level
--------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------
Condition 1 : /etc/fstab is corrupted, how to recover
Entry of /boot file system is corrupted in /etc/fstab file
1. Insert the Rescue disk
2. continue
3. ok
4. Shell start --- Enter
5. # chroot /mnt/sysimg
6. # mount -o remount / ['/' rewritable form]
7. exit
8. exit
9. reboot reboot
Condition 2 : To Recover /etc/passwd
1. Insert the Rescue disk
2. continue
3. ok
4. Shell start --- Enter
5. # chroot /mnt/sysimg
6. # cd /etc
7. # ls [to view 'passwd-' file]
8. # cp -p passwd - /etc/passwd [-p = with permission]
9. exit
10. exit
11. reboot reboot
--------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------
How to check running and stop services at run level :
# cd /etc/rc5.d // To check at run level 5
# ls -ltr
Output :
K01......
K02......
K03......
.........
.........
.........
.........
S01......
S02......
.........
.........
K = Kill, service will be stopped on the current run level
S = Start, service will start on the current run level
--------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------
Condition 1 : /etc/fstab is corrupted, how to recover
Entry of /boot file system is corrupted in /etc/fstab file
1. Insert the Rescue disk
2. continue
3. ok
4. Shell start --- Enter
5. # chroot /mnt/sysimg
6. # mount -o remount / ['/' rewritable form]
7. exit
8. exit
9. reboot reboot
Condition 2 : To Recover /etc/passwd
1. Insert the Rescue disk
2. continue
3. ok
4. Shell start --- Enter
5. # chroot /mnt/sysimg
6. # cd /etc
7. # ls [to view 'passwd-' file]
8. # cp -p passwd - /etc/passwd [-p = with permission]
9. exit
10. exit
11. reboot reboot
--------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------
No comments:
Post a Comment