Partition-Rescue HOWTO
Prev |  | Next

# 1. Beginning

## 1.1. What's in

This HOWTO addresses only the "lost partition table" problem. This can be when :

- you have no more access to your computer, with the "no operating system" message ;

- you have installed a new system (i.e. MS Windows) and you see no more Linux, and MS Windows take up all the capacity of the disk ;

- you have just partitioned the wrong drive with fdisk (for example in the way of changing your hard drive).

Here you will learn that if you know the right thing and do it, Linux comes usually safe from such things. MS Windows can, but it's luckier.

We will first see what you can do before the problem to ease the future recovery and what you must do after to recover. There is little to do to prevent from erasing a disk, usually this is done by automatic MS Windows or Linux-install ill behaved programs or users mistakes - nothing can be done to prevent this except care, but you are already careful, isn't it ?

It can also be done by the use of MSDOS/Windows fdisk. Avoid it as most as you can, but you probably can't.

I have done this many times, on my computer and on others guy computers and restored Linux most of the time and MS Windows sometimes. I wish you luck !

## 1.2. What to do right now ?

If you don't have any problem yet, if you read this by curiosity or just seeking information and you are on a running Linux system, do immediately the following :

- open a root terminal or xterm ;

- key in “/sbin/fdisk -l” (that last character being l for Lima). Then do fdisk -u -l ;

You will be gratified by a list of all current partitions on all disks presents on your computer. The second one gives the listing in sectors units in place of cylinder and this is sometime necessary.

- Write this back on paper (or do "/sbin/fdisk -l | lpr" and "/sbin/fdisk -u -l | lpr" to print it) and save it in a safe place for future use.

If you are not the system administrator, you should not be concerned by the problem and can stop reading this.

## 1.3. Legal stuff

This HOWTO is Copyright (c) 2000-2001 by Jean-Daniel Dodin.

As of November 2003, the licence is LGPL.

I am not responsible of any damage on any computer as a result of anyone reading this HOWTO. If you do any damage, _it is YOUR fault, NOT MINE_! Be careful when partitioning disks, and don't make any mistakes, because it can be fatal ! Backup all your important data and check that everything you do is correct ! What is described here worked on my computer, but it may or may not work on your computer. Although it should work for everyone, I can't guarantee anything. This is the last warning you get: BACKUP IMPORTANT DATA ! Or, to put it short: Use at your own risk !

## 1.4. What do I must know right now?

You must know that in case of any major problem with your hard disk, you must stop using it at all in write mode, at least the time necessary to understand what happens. Information there is very volatile...

If ever, one morning, awaking, you computer say "can't load, no system installed", you must not begin reinstalling all the stuff.

If you have MS Windows installed, I can't promise you can recover your data, but it's likely you will recover all your Linux stuff, provided it's not located too low (near the beginning of the disk) in the disk structure. This is because some MS Windows viruses erases the very first disk cylinder, whatever is on. However I didn't ever experiment such virus and can't say for sure. Try recovering anyway.

You must also know that I give you all this information only for this - information purpose. Neither I nor any other people but you can be held responsible for any problem your data can have using this info. There are too many different systems on the world for anybody being able to promise anything. I can only wish you luck and hope you, like me, will be happy recovering data.

Prev | Home | Next
Partition-Rescue HOWTO |  | Technical info