LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 01-17-2003, 09:11 AM   #1
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Rep: Reputation: 0
Kernel panic: VFS: Unable to mount root fs on 07:01


Hello,

I have a Win2K/Red Hat 7.0 Linux dual boot machine where Win2K boots by default and Linux boots when I insert a Linux boot floppy disk.

The Red Hat Linux 7.0 installation was sitting on a FAT32 drive in 2 files:

redhat.img (2GB)
rh-swap.img (32MB)

The FAT32 hard drive began to fail intermittently, so I used WIN2K to copy the 2 files to another FAT32 drive.

Then the original FAT32 hard drive failed and I put the other FAT32 drive in its place.

When I use the floppy to boot Linux, I get a

"Kernel panic: VFS: Unable to mount root fs on 07:01"

I'm betting that the boot floppy has drive-specific information that is now incorrect since the original drive is not around anymore. But I'm having trouble even accessing the floppy disk.

When I use the CDROM's linux rescue feature, I type ls ./dev and I'm do not see the floppy drive (fd*) devices or any of the machine's 6 SCSI hard drive (sd*) devices in the list.

When I type fdisk -l at the command prompt in rescue mode, I see an empty list.

So, I have two questions:

1. Is it possible for me to change the contents of a floppy disk without installing Linux?

2. If I make the changes to the floppy disk, is it possible to boot Linux off of the copied Linux files or is there something special about the original files locations, etc.?

Thank you in advance for any advice/help.

Richard
 
Old 01-17-2003, 11:28 AM   #2
digizer0
LQ Newbie
 
Registered: Jan 2003
Location: Tokyo, Japan
Distribution: Redhat 8
Posts: 15

Rep: Reputation: 0
although i'm an novice to linux, i do think i have some clue to your problems

1)probably you can, the boot disk is just like an ordinary fat filesystem floppy disk i think, but i'm not sure where u should edit the bootup parameters. It's most likely in the boot sector of the floppy. The point is to specify the root file system when booting the kernel. But acturally, this is not the real big problem for your situation i think

2)the real trouble is your whole linux root filesystem(also swap partition, from the info u offered) exists as a single file on fat filesystem, this technic was call umsdos??(not sure) that is not so widely used(as to my knowledge, at least i don't like this kind of usage). And the space the original file occupied must be continous, so that continous area can be simulated as a linux partition. Now since you have copied them in Windows, it's very likely that they are not continous anymore. Though maybe u can make those files continous, u still have to know the absolute sector number of the file's first sector, coz when linux booting, it will use the info in that sector to mount the root filesystem.

These are what i all can say.
 
Old 01-17-2003, 12:19 PM   #3
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Original Poster
Rep: Reputation: 0
Thank you for your help.

I bet you're right about the files needing to be in a contigous space. It might just turn out that way since I copied the files to an empty formatted FAT32 hard drive. But, I doubt the files live on exactly the same sectors, so all might be lost anyway.

I wasn't able to find much information about this kind of installation and will now search for umsdos. Any pointers to descriptions of this kind of installation would be very helpful.

Thank you.

Richard
 
Old 01-17-2003, 01:16 PM   #4
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Original Poster
Rep: Reputation: 0
After looking up umsdos, I discovered that this is *not* how I have Linux installed.

Instead, I used the "partitionless installation" method (see http://www.redhat.com/docs/manuals/l...part-less.html).

The partitionless installation method for installing RedHat Linux 7 gives the option of *not* creating a dedicated partition for Linux. According to what I have read, the downside is basically performance. Some also say that one can only use a floppy to boot the system. Using this method, one can install Linux to an existing FAT32 drive and use a floppy disk to boot Linux. The beauty is, to uninstall Linux all one has to do is delete the 2 files.

umsdos, on the other hand, was developed by Jacques Gelinas in the early 1990s and appears to allow Linux files to co-exist with MS-DOS files. I'm not sure if umsdos is in use anymore but you can read about it at

http://www.linuxpowered.com/archive/...DOS-HOWTO.html

The information I'm now searching for is: is it possible to copy the

redhat.img (2GB)
rh-swap.img (32MB)

files to another drive, update the boot floppy to point to the other drive and successfully boot Linux?

One person said in a discussion thread that the rh-swap.img file must occupy the first 1024 blocks of the hard drive.

Any pointers to more information would be greatly appreciated.

Richard
 
Old 01-18-2003, 01:18 AM   #5
digizer0
LQ Newbie
 
Registered: Jan 2003
Location: Tokyo, Japan
Distribution: Redhat 8
Posts: 15

Rep: Reputation: 0
Maybe you can try to find out who developed the "partitionless install" function, and directly ask the developers.
I think most linux users(for example, me) are not familar with that technic.

Anyway, thank you for the info about "partitionless install", i've never heard of it before

Good Luck.
 
Old 01-18-2003, 06:19 AM   #6
qanopus
Senior Member
 
Registered: Jul 2002
Location: New York
Distribution: Slackware
Posts: 1,358

Rep: Reputation: 45
Ye, I know what you did wrong. I could of told you you would get a kernel panic before you would have done it.
You see, instead of using a partiton to install linux, you are using a file. That file contains a image of an file system. Kind of like an iso image of a cd.
What you actually did was move your virtual dh. No wonder it can find the root fs!!!.
Okey, do this. Download a mini linux distro. You can get one here. Boot from that floppy. You will be in a very limited linux enviroment.
One you have booted, give a command like "mount -t ext2 -o loop redhat.img <mount_point>" . Here mount_point is a directory where you want to mount the image. See if you have a empty directory like "/mnt/" or somthing. If not, create an empty directory, somthing like "/mnt/redhat"
After that do "chroot <mountpoint>". Then make a copy of "/etc/lilo.conf" on a floppy. Go back to windows and post the content of lilo.conf here. We will need to modify that file.

Last edited by qanopus; 01-18-2003 at 06:27 AM.
 
Old 01-18-2003, 09:18 AM   #7
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Original Poster
Rep: Reputation: 0
Thank you for your help.

I have continued to investigate this and found a useful web site that has information about LILO and how it works. It has helped me understand better what is going on. Unfortunately, I still can't figure out if it's possible to change the files on the boot disk to make it work with the copied RedHat image files.

Here's the URL:

http://home.att.net/~lilo-boot/lilohome.htm

I used tomsrtbt to create a generic unix boot disk and booted to the floppy disk, followed the instructions, logged in as root, typed mkdir /mnt/floppy, then inserted my Linux boot floppy and typed mount /dev/fd0 /mnt/floppy.

In the etc folder of the my Linux boot floppy, lilo.conf reads:

boot=/dev/fd0
timeout=100
message=/boot/message
prompt
image=/vmlinuz-2.2.16-22
label=linux
root=/dev/loop1
initrd=/initrd.img

I have read what these settings mean, but still don't quite get it yet. There are a few files on the boot disk that are not mentioned in lilo.conf. For example, the boot.b, boot.0200 and map files. If I understand this correctly, these files are "compiled" from the kernel when the boot disk is created. The map file contains the locations of these other files.

For a while I thought maybe the map file needs to be edited, but I think the map file is for LILO and not for finding the final OS. I also was thinking that the initrd.img file contains the information about where the final OS lives.

I believe the initrd.img file contains a small kernal and is copied to a ram disk. On other threads, some have suggested that initrd.img is optional.

My understanding of this lilo.conf file is that a ram disk is created, a small kernel is copied to it and lilo.conf runs the kernel on the ram disk. It's then up to the kernel to find the final OS and start it up.

I'm not sure what changes I could make to lilo.conf that would make a difference.

Thank you again for your help.

Richard
 
Old 01-18-2003, 10:42 AM   #8
digizer0
LQ Newbie
 
Registered: Jan 2003
Location: Tokyo, Japan
Distribution: Redhat 8
Posts: 15

Rep: Reputation: 0
Richard, it seemed you didn't understand what schatoor expected you to do. Here is the steps:
1. boot from the mini linux floppy(tomsrtbt)

2.mount your fat32 partition contains the 2 files. If you are not sure which device to use, type: fdisk -l /dev/hda(change this, if your harddrive is not /dev/hda), and mount the fat32 partition by typing: mount /dev/hda1(change this if necessary) /mnt/hd(if not exist, create this dir)

3.mount the redhat file in your fat32 partition on the current system by: mount -t ext2 -o loop /mnt/hd/redhat.img /mnt/redhat(create dir if needed)

4.chroot /mnt/redhat

5. copy the contents of /etc/lilo.conf here

that's it. i hope i'm right
 
Old 01-18-2003, 11:15 AM   #9
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Original Poster
Rep: Reputation: 0
Thank you for following up.

I will continue trying but this is what I get when I type mount /dev/sda1 /mnt/hd

"mount: the kernal does not recognize /dev/sda1 as a block device (maybe 'insmod driver'?).

I tried sda1 first because the drive is a SCSI drive and not an IDE drive.

Then I tried mount /dev/hda1 /mnt/hd and got

"mount: /dev/hda1 has wrong major or minor number"

The drive is the second drive of 6 in a Compaq Proliant 3000. This is why I'm using 1 instead of 0. I will try different permutations of this again in a little while.

Richard
 
Old 01-18-2003, 11:54 AM   #10
qanopus
Senior Member
 
Registered: Jul 2002
Location: New York
Distribution: Slackware
Posts: 1,358

Rep: Reputation: 45
I don't understand your situation. You have 6 (!!!) scsi hard drives. Or is that 6 partitons on a single drive. And you had one ide hard drive but that started to fail. Am I correct on that?
Would you specify exactally what your situations was and what it is now.
The thing that i'm trying to do is mount the hard drive images of your red had system. But you can only do that in a linux system via a so caled loop back device. After having gained acces to your red had file system, the lilo.conf file ON THAT SYSTEM should be reconifgured so you can create a new boot disk. Note that i'm asuming that you are using lilo. If you are using grub, grub should be reconfigured. Only, I don't know that grub works.
But now it seems you can't acces the red had files on you hd. It might be because the rescue system you used, tomsrtbt boots to a very minimal linux system. It might be that it does not understand your system. I don't know, i'l have to look in to that.
Post the exact way your system is configured (how many hd's you have, what file systems they contain, what partitons they have and what kind of hd's they are, i.e. ide or scsi).
 
Old 01-18-2003, 03:53 PM   #11
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Original Poster
Rep: Reputation: 0
I guess I don't yet understand well enough what hda*, sda*, etc. mean.

Since you asked:

It's a Compaq Proliant 3000 machine with 6 SCSI hard drives. If you are not familiar with these computers, they have hot-swappable hard drives and are intended to be used as file servers.

This is the only machine I had available to install Linux. I didn't want to change the boot drive so I chose the partitionless installation method and used an existing FAT32 drive (drive #1) to store the 2 RedHat files. While the FAT32 drive was still working, this configuration worked well.

Hard drive #0 is a 4.3GB SCSI drive with NTFS that is mirrored with hard drive #3. This is the Win2K Advanced Server operating system drive.

Hard drive #1 is a 9.1GB SCSI drive with FAT32. This drive has the 2 RedHat files on it. It is not mirrored because it is a basic drive.

Hard drive #2 is a 9.1GB SCSI drive with NTFS that is mirrored with hard drive #4.

Hard drive #5 is a 9.1GB SCSI drive with FAT32. It is not mirrored.

Because these are SCSI drives, I read somewhere that the devices are sda{0-5} instead of hda{0-5}. Or is it sd{a-e}1?

Before drive #1 began to fail, I reformatted drive #5 for FAT32 and copied the 2 RedHat files from drive #1 to drive #5. Later, drive #1 failed completely and I moved drive #5 to the #1 slot and put another FAT32 drive in slot #5.

I didn't expect the Linux boot disk to boot to the new drive -- but I thought that I might be able to change something on the boot disk to make it work.

So far, I do not think this is possible because the boot disk has images of the kernal rather than a script that I can fiddle with.

I hope this is helpful.

Richard
 
Old 01-18-2003, 06:19 PM   #12
qanopus
Senior Member
 
Registered: Jul 2002
Location: New York
Distribution: Slackware
Posts: 1,358

Rep: Reputation: 45
Okey, a crash corse on how unix drive names are given
The fist ide drive on a system is called hda. The second is hdb. In parallel, the first scsi drive is sda. the second sdb, ect. The first partition on the fist scsi drive is sda1. The second partiton on the third ide drive is hdc2.
You want to mount the second scsi drive (the one you call #1) so you should do "mount /dev/sdbx <where_ever>", with x being the xth partition an the second scsi drive.
With the command you gave, the first hd would have gotten mounted, but that has an ntfs formatation. So I would indeed expect an error I you would try to mount that.
Try doing what you did but then with "/dev/sdb" instead of "/dev/sda". See if that works. I did some googling and it turns out tomsrtbt supports scsi devices. So it should work.
And no, you can't change the existing boot floppy so it would boot in the current configuration. You have to make a new boot floppy.

Last edited by qanopus; 01-18-2003 at 06:21 PM.
 
Old 01-18-2003, 11:08 PM   #13
digizer0
LQ Newbie
 
Registered: Jan 2003
Location: Tokyo, Japan
Distribution: Redhat 8
Posts: 15

Rep: Reputation: 0
a bit of suggestion.
Backup your boot floppy disk! Due to frequent access these days, it is possible that the floppy fails, so have a mirror backup(that is not only the contents, but a 1-on-1 copy, include the boot sector, you can use winimage to create mirror backup on windows) is recommended.

BTW, i think there is chance to directly modify the floppy to make it boot. The info we need to modify is not in the kernel file, but in the ram root filesystem in the initrd file, i think.
 
Old 01-20-2003, 07:53 AM   #14
rzward
LQ Newbie
 
Registered: Jan 2003
Posts: 9

Original Poster
Rep: Reputation: 0
I think I understand where you are headed with this. Correct me if I'm wrong:

1. Boot to a floppy with a small linux kernel using a disk like tomsrtbt.

2. Mount the new drive that has the copy of the RedHat files on it.

3. Mount the redhat.img file using the command you mentioned above.

4. Use the lilo.conf information and other information inside redhat.img to create a new boot floppy disk.

5. Use the new boot floppy disk to boot to the new hard drive.

Well, unfortunately, I am still trying to mount the new hard disk using tomsrtbt.

Since I have not been able to mount the new hard drive, I decided to try to mount the bad hard drive, since obviously the Linux boot disk has been able to mount it. The thinking is, if the Linux boot disk can mount the bad hard drive and tomsrtbt can't, then maybe tomsrtbt doesn't support this kind of hard drive. If tomsrtbt can mount the bad hard drive but not the new hard drive, then there's something different about the drives.

This is what I have done:

1. Put the original (bad) FAT32 hard disk in the machine in slot #1 and rebooted using the original Linux floppy boot disk. According to the messages that quickly scroll by (any way to make it pause?), the bad FAT32 hard disk is mentioned this way:

"Detected scsi disk sdb at scsi1, channel 0, id 1, lun 0"

Later in the boot process, the kernel tries to read the disk and fails. Once in every 10 tries, Linux will actually boot and start on the hard drive but whenever I try to copy the 2 RedHat files, I get read errors and most of the time when I boot to Windows, the hard disk is not recognized.

2. Kept the original bad FAT32 disk in slot #1 and rebooted to the tomsrtbt boot disk and have tried every permutation I can think of mounting sdb, sdb1, sdb2, ... and sda, etc. It turns out hda is the CDROM drive.

3. Thinking there might be something wrong with the tomsrtbt boot disk, I used it on an old pentium 100 machine with an IDE hard drive. I was able to mount the FAT drive on that machine without any problem.

So, I am left to think that tomsrtbt does not support the kind of SCSI drives that are in the Compaq 3000. When I boot using the original Linux boot disk, I read

"FAST-20 SCSI 20.0 MB/s (50 ns, offset 15)" and "ANSI SCSI revision: 02"

I plan to now e-mail tom's newsgroup to find out if this hard disk is compatible.

Richard
 
Old 01-20-2003, 10:05 AM   #15
qanopus
Senior Member
 
Registered: Jul 2002
Location: New York
Distribution: Slackware
Posts: 1,358

Rep: Reputation: 45
At this point I thing you have two alternatives.
1) Get a nother linux distro that has more drivers. I would recomment knoppix. It comes on a cd so you will need a fast internet connection (you acctually download the iso image ofcource) It comes with about 2000 progs and configures your hardware for you. But I don't know if your hd's will be supported.
2) Reinstall redhad. You can backup every thing on the redhat images.
Download explore2fs, the prog with which you can do this here. You can tell it to open this and that file system image and you will be able to brouse the redhat system from windows. Notice you don't have to point it to a partition, you can also open a file system image on an windows partition.
From here you could backup the data on the redhat system after which you could reinstall redhat.
I'm sorry i'm not much of a help. But i'm doing the best I can.

Last edited by qanopus; 01-20-2003 at 10:08 AM.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
kernel panic: VFS: Unable to mount root fs in 08:02 sebas_turu Debian 10 01-21-2008 01:04 AM
Kernel Panic: VFS: Unable to mount root fs on 09:02 verbali Linux - Hardware 8 02-24-2004 06:11 PM
Kernel panic: VFS: Unable to mount root cmlo Linux - Software 4 05-20-2003 02:25 AM
Kernel panic: VFS: Unable to mount root cmlo Linux - Newbie 3 05-17-2003 07:55 PM
Kernel Panic: VFS: Unable to mount root fs on 09:02 verbali Linux - General 6 05-26-2002 02:30 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:26 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration