Boot Ubuntu Linux into Rescue mode to fix system

Posted on in Categories , last updated January 8, 2008

Q. How do I boot my Ubuntu Linux server into Rescue mode to fix system?

A. You can boot Ubuntu Linux into rescue mode when things go wrong, there are several ways to work on fixing them. However, you must understand your system and what to fix in case of emergency.

Use this mode only if your system is unbootable. It is also recommended that you make backup of important data.

=> Start Computer / reboot computer

=> Put your Ubuntu install CD

=> Make sure BIOS is set to boot from CD

=> Now booting will start from Ubuntu install CD

=> You will see various option screen – select Recover a broken system

You will system is booting in to rescue mode; system will ask about Network and other information. This is required to setup rescue environment.

Now you will prompted to select root partition or device.

Next it will try to mount root device and it will notify the same.

Now you will see common rescue mode option such as Reinstall GRUB or open / execute a shell etc.

Now you are in rescue mode and you need to use your own knowledge to rescue the system. When things go wrong, there are several ways to work on fixing them.

Few things to remember….

The rescue-mode CD mounts your root filesystem at /target directory. Open or execute a shell and change directory to /target
# ls /target
# cd /target
# mount

If you need to run fsck command use fdisk -l command to find out partition name. Usually they are located at /dev/discs/discX/partY. For example repair 2nd partition (not mounted as /target) you may type command:
# ls -l /dev/discs/disc0
# fsck.ext3 /dev/discs/disc0/part1

To exit type command :
# sync ;sync
# exit
# reboot

As I said earlier in rescue mode, there is no single command that I can recommend to fix problem. You need to use your own knowledge to rescue the system and don’t forget to read command documentation before using any command.

Posted by: Vivek Gite

The author is the creator of nixCraft and a seasoned sysadmin and a trainer for the Linux operating system/Unix shell scripting. He has worked with global clients and in various industries, including IT, education, defense and space research, and the nonprofit sector. Follow him on Twitter, Facebook, Google+.

18 comment

  1. how can you rescue your ubuntu desktop 8.4 if you do not have the rescue option to boot your computer to? spacialy if you lost the grub bootloader becuse of MS windows.

  2. My ubuntu does not load it gives me an error message ‘no module found
    Aborted. Press any key to exit.

    What is the problem and how do i fix this can’t even use my windos.
    HELP some body, anybody.

  3. can you guys help me one thing? i got problem in my Pc, and i use Ubuntu for while and now what i got is , The hard disk get full of file and suddenly , it show me command line which is that i have to remove files but i am not good at it and still, iam not using it ! i need help who know more about Ubuntu just contact me i will show you each and every message by mail . please help !!

  4. I upgraded from 10.o LTS to 12.04. Now it only boots from the rescue mode/root. Not from live cd but from ( recovery mode). It works normally but it’s running in Root mode.
    It doesn’t work right booting in user mode. What did I do wrong? Initially all my Home files were owned by root.I changed that to my user but it still only starts from root.I updated to grub2 (which doesn’t chain load correctly).I can’t find the answer.

Leave a Comment