LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Hardware (https://www.linuxquestions.org/questions/linux-hardware-18/)
-   -   missing /dev/sda[6-8] files, use mknod? FC5 (https://www.linuxquestions.org/questions/linux-hardware-18/missing-dev-sda%5B6-8%5D-files-use-mknod-fc5-482364/)

worzel68 09-11-2006 05:13 AM

missing /dev/sda[6-8] files, use mknod? FC5
 
Hello all,

I am wondering whether using mknod would cause files to be lost on the previously existing device file?

First, the hardware arrangments, then the drama .........
I have a Fixed SATA disk & a removable hard drive bay, in which I normally have a FC3 installation. The FC3 still works, which is good.

Now to the cause of the problem.

I had a broken windows installation (explorer doesn't work) in the removable hard drive bay, and was looking at the Disk Management Program. It showed only 5 partitions on the SATA disk. When I went to boot FC5, it failed because it could not find /home & I noticed that it was booting from a /boot1 partition and not /boot.

I think windows has altered the MBR for /dev/sda. Unfortunately I don't have a backup of the MBR. (Big lesson there)

here is the partition table for the SATA disk (/dev/sda):

Code:

[root@wwwbigpondnetau dev]# fdisk /dev/sda -l

Disk /dev/sda: 200.0 GB, 200049647616 bytes
255 heads, 63 sectors/track, 24321 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes

  Device Boot      Start        End      Blocks  Id  System
/dev/sda1  *          1          13      104391  83  Linux
/dev/sda2              14        6387    51199155  83  Linux
/dev/sda3            6388      12761    51199155  83  Linux
/dev/sda4          12762      24321    92855700    5  Extended
/dev/sda5          12762      19135    51199123+  83  Linux


/dev/sda1 is the boot partition
/dev/sda2 is /
/dev/sda3 is /var
/dev/sda5 is /usr

However, before there was also (inside sda4 extended partition):

Quote:

/dev/sda6 vfat 10Gig /vfat
/dev/sda7 swap 2Gig
/dev/sda8 ext3 28Gig /home !!!!!!!!!
they now don't exist.

Quote:

[root@wwwbigpondnetau dev]# ls -l /dev/sd*
brw-rw---- 1 root disk 8, 0 Sep 11 16:04 /dev/sda
brw-rw---- 1 root disk 8, 1 Sep 11 16:04 /dev/sda1
brw-rw---- 1 root disk 8, 2 Sep 11 16:04 /dev/sda2
brw-rw---- 1 root disk 8, 3 Sep 11 16:04 /dev/sda3
brw-rw---- 1 root disk 8, 4 Sep 11 16:04 /dev/sda4
brw-rw---- 1 root disk 8, 5 Sep 11 16:04 /dev/sda5
brw-rw---- 1 root disk 8, 16 Sep 11 16:04 /dev/sdb
I have never been able to mount anything on /dev/sda (FC5) from FC3, but I have been able to mount /dev/hda from FC5 when it was working. There is LVM setup on FC3 disk but not on FC5 disk.

Not surprisingly, I can't use e2fsck on /dev/sda[68], however /dev/sda[1-5] are ok as expected.

Code:

[root@wwwbigpondnetau dev]# fsck -t ext3 /dev/sda8
fsck 1.35 (28-Feb-2004)
e2fsck 1.35 (28-Feb-2004)
fsck.ext3: No such file or directory while trying to open /dev/sda8

The superblock could not be read or does not describe a correct ext2
filesystem.  If the device is valid and it really contains an ext2
filesystem (and not swap or ufs or something else), then the superblock
is corrupt, and you might try running e2fsck with an alternate superblock:
    e2fsck -b 8193 <device>


[root@wwwbigpondnetau dev]# e2fsck /dev/sda2
e2fsck 1.35 (28-Feb-2004)
/: clean, 7463/12812288 files, 512288/12799788 blocks

An attempt to do an upgrade reinstall from FC5 DVD fails because it says that /dev/sda6 is not formatted. (really because it isn't there)

So, back to the origianal question - can I use mknod without destroying any existing files?

Is there any where I can find a backup file of the MBR or partition table to restore using the dd command?

Once I have used mknod, is there any way to re-create the partition table without using fdisk so it doesn't destroy files?

Finally, I am happy using the command prompt from within linux rescue on the FC5 DVD.

Thanks in advance,David


All times are GMT -5. The time now is 12:14 PM.