LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Ubuntu (http://www.linuxquestions.org/questions/ubuntu-63/)
-   -   How to mount/recover files from crashed Linux OS? (http://www.linuxquestions.org/questions/ubuntu-63/how-to-mount-recover-files-from-crashed-linux-os-483280/)

alar 09-13-2006 08:50 PM

How to mount/recover files from crashed Linux OS?
 
I hope I will be clear and concise here. I have two failed OS's on the same hard-drive. My working system is Ubuntu on hda.

hdb was originally a dual-boot Fedora/W2K:

It was the only hard-drive before I installed Ubuntu (on an old Maxtor) now known as hda. (My son set it up :)

I can't restore W2K because it isn't the primary drive.
And, I don't know a quick and easy way to mount the Linux (Fedora4) partitions from Ubuntu to recover my data off of Fedora. I care about the Fedora data...

Tried fstab but:

mount point /rescueA does not exist.

So I think I need to create a mount point for the broken Fedora install first. To retrieve files and such.

I'll deal with w2k install later... BTW: Tried unplugging the Ubuntu hard-drive but W2K can only see Disk 0 ID 0 and not Disk 0 ID1 on the w2k install. W2k is confused, it can only see the Fedora partition...(suggestions are welcome!)
Windoze install thinks drive d is my CDROM. Hmmmmm.

Okay, this all started with a new linux friendly Nvidea install...

We killed Fedora on the install of Ubuntu --oops, and I personally killed W2K on the video card install later...

Primary question:

How to set up fstab to mount other Linux distro's?

Yes I use grub.
I forget how or what to log/backup the grub(Ubuntu install): before I start reformatting drives I want to recover data from...

I know- too many questions... But when I figure it out I will document it. Promise....

All comments welcome :)
Thx,
Alar

zhangmaike 09-13-2006 10:31 PM

You need to first figure out which device you want to mount. You then need to make a directory to mount the device on (a "mount point"). The error you're getting which says that /rescueA doesn't exist means exactly that: the directory /rescueA does not exist... so make it.

When you've made the mount point, edit your /etc/fstab to your liking. In fact, to just test whether or not you can mount it, you don't need to edit /etc/fstab. As long as you're root, you can mount any device anywhere.

Quote:

I don't know a quick and easy way to mount the Linux (Fedora4) partitions from Ubuntu
The quick and easy way is (as root):
Code:

mount /dev/hdb1 /rescueA
Make sure /rescueA exists.

Your device may be different:
/dev/hda is the master on the first IDE bus
/dev/hdb is the slave on the first IDE bus
/dev/hdc is the master on the second IDE bus
/dev/hdd is the slave on the second IDE bus
The number is the number of the partition (/dev/hda1 is the first partition of the master drive on the first IDE bus, while /dev/hda is the entire drive including partition table, master boot record, all partitions, etc.)

weibullguy 09-13-2006 10:47 PM

You don't edit fstab to mount other distros in the sense that you want to dual boot Linux distros. That would be done by editting /boot/grub/menu.lst. Do you want to dual boot Ubuntu and Fedora?

To simply mount the old Fedora partition and recover the data, you really don't need to edit fstab unless you plan to mount the Fedora partition regularly. To mount it once from Ubuntu and recover your data, then

Code:

install -dv /rescueA
install -dv /recovered
mount /dev/hdb1 /rescueA
ls -l /rescueA
cp /rescueA/* /recovered
umount /rescueA

To edit fstab, then

Create a mount point, edit the file.
Code:

nano -w /etc/fstab
/dev/hdb1  /rescueA  ext3  defaults 0 0


alar 09-14-2006 06:13 PM

I can't believe that (in the moment of panic?)
I forgot to create rescueA :confused:

After all that and combined with fdsik -l

/boot/grub/menu.lst

seems pretty clear to me now.

Thankyou both so much :)


All times are GMT -5. The time now is 08:48 PM.