[SOLVED] Grub Loader -> Grub Page - > Linux Starts Up -> Erorrrrrrrrrr... Doesn't Start Up!
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: On my PC I use RHEL, at office AIX, Solaris, HP-UX, RHEL.
Posts: 254
Rep:
Grub Loader -> Grub Page - > Linux Starts Up -> Erorrrrrrrrrr... Doesn't Start Up!
Hi,
I had setup "dual booting". The first OS is Windows XP Pro SP 2 and the second OS is RHEL 5. The system was running fine until yesterday when I started it up and selected Windows XP from the Grub Page there was an error indicating that a system file was missing or corrupted under ...\system32\ and suggested that the problem could be fixed by booting from the CD of XP and selecting the recovery option (r). So, I did that. However, after the boot process I was presented with the partitions list and was to selected C to install Windows. I am not sure why the recovery option was not presented. Well, I installed Windows again and so Grub was gone.
To reinstall Grub I did this:
Booted the system from RHEL5 DVD:
Code:
linux rescue <enter>
...
#chroot /mnt/sysimage
#grub-install /dev/hda <enter>
Rebooted the system and the Grub Page was there but Linux could not be started up.
I checked the file /etc/grub.conf and changed the partition number in root (hd0,x) and wherever required. But I forgot what partition number it was there before.
So, how can I determine which partition holds the startup files, i.e. the root partition of Linux while Linux is running in rescue mode?
The command e2label didn't seem to work (though I didn't try it last night).
Well, if you happen to have read one of my previous threads you might guess that my system is messing up after Linux crashed the other day and I reinstalled it again and again. (Now, Windows also seemed to be closed so I opened it forcefully!)
You can get your partition information by running the command: fdisk -l (Lower case Letter L) as root user, use any Linux Live CD. It's difficult to give specific advice without this information, how many drives/partitions? Do you have a separate boot partition? Post the fdisk output here and someone should be able to help you.
Distribution: On my PC I use RHEL, at office AIX, Solaris, HP-UX, RHEL.
Posts: 254
Original Poster
Rep:
Hi,
I did that yesterday and today in the evening also. Somehow I was able to fix the problem and got the system ready. Well, I will post my findings here in some minutes.
Thanks!
Quote:
Originally Posted by yancek
You can get your partition information by running the command: fdisk -l (Lower case Letter L) as root user, use any Linux Live CD. It's difficult to give specific advice without this information, how many drives/partitions? Do you have a separate boot partition? Post the fdisk output here and someone should be able to help you.
Distribution: On my PC I use RHEL, at office AIX, Solaris, HP-UX, RHEL.
Posts: 254
Original Poster
Rep:
From linux rescue mode:
Code:
#chroot /mnt/sysimage
#fdisk -l
output:Device :::::::: Id ::::::::::: System ::::::::::::::::
/dev/hda1 * c W95 FAT35 (LBA)
/dev/hda2 f W95 Ext'd (LBA)
/dev/hda5 b W95 FAT32
/dev/hda6 b W95 FAT32
/dev/hda7 83 Linux
/dev/hda8 82 Linux swap / Solaris
/dev/hda9 83 Linux
/dev/hda10 b W95 FAT32
/dev/hda11 b W95 FAT32
So, I edited the /etc/grub.conf file and changed the entry for parition number from whatever it was to (hd0,hd7), (hd0,hd8), and then (hd0,hd9) as those were the only Linux paritions as shown above. But none of them worked. So, I typed in (hd0,hd6) this time and it worked. I figured out that the first parition is internally or logically numbered 0 so (hd0,hdx) should be (hd0,hd6) in the grub.conf.
I tried this to figure out which parition holds the root (/) parition:
Code:
#e2label /dev/hda7
By the way, could you explain me what those "ID" values indicate?
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.