Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
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.
Introduction to Linux - A Hands on Guide
This guide was created as an overview of the Linux Operating System, geared toward new users as an exploration tour and getting started guide, with exercises at the end of each chapter.
For more advanced trainees it can be a desktop reference, and a collection of the base knowledge needed to proceed with system and network administration. This book contains many real life examples derived from the author's experience as a Linux system and network administrator, trainer and consultant. They hope these examples will help you to get a better understanding of the Linux system and that you feel encouraged to try out things on your own.
Click Here to receive this Complete Guide absolutely free.
I used to have 2OS in my computer, Redhat LINUX and WindowsXP. Last week I reinstall WinXP then my boot loader was gone. I tried to install boot loader back from the Redhat CD but I got message
'No kernel packages were installed on your system. Your boot loader config will not be changed'.
Then I tried using rescue mode. type
grub -install /dev/hda
looked like the result is ok. Now I have grub boot loader. However, when I rebooted my coputer, I got the message
filesystem type unknown, partition type 0xF
kernel /boot/vmlinuz-2.4.20-8 ro root=LABEL=/hdc=ide-scsi
Error 17: cannot mount selected partition
the message appear in broken letters. Then there are options to choose between DOS and LINUX. I can boot DOS (Windows) but not LINUX. Same error message (filesystem type unknow, partition type 0xF, cannot mount selected partition) appear again.
my linux partition is on /dev/hda3, windows on /dev/hda1 (I can see from fdisk -l). The * is on /dev/hda1. Is that correct?
The fact that you can get in using rescue mode is good and means that linux is not hosed.
After you boot into rescue mode and chroot to /mnt/sysimage....
Type: rdev so you can verify that the root partition is indeed on /dev/hda3
If you know where the root partition is you can proceed to repair the GRUB as follows...
Type:grub to get into the grub utility.
Type: root (hd0,2) which is grub speak for the first hard drive and the third partition of that drive. If you got it right, you will see a message like this..... Filesystem type is Ext2fs, partition type is 0x83.
Next type: setup (hd0)
Then type: quit to exit the grub utility.
Then reboot to try it.
I just tried your advice. I got '/dev/hda3 /' from rdev. And after grub, root (hd0,2) give exactly what you said. setup (hd0) told no error message. However, I still cannot solve the problem. Do you have any suggestion? If I have to reinstall linux, do I have to remove the boot loader before?
Ok maybe you do have a problem with the file system. Try the e2fsck routine with your system unmounted. If you plan to reinstall, I would try an upgrade first to see if that fixes it.
You don't have to mess with the old boot loader if you do reinstall.
Distribution: Slack Puppy Debian DSL--at the moment.
If you were reading this before, I was confused, I double checked.
(hd0,0) is the first partition. Did you keep a partition map of your drive?
If so, what is it?
and so on. I never have been able to keep everything straight, Sorry.
grub stage 1 resides in the MBR; stage 2 resides in the MBR; stage 1_5 is /boot/grub/grub.conf; Hey, wait a minute. If your machine will boot linux, or you can go on the internet with another machine why don't you info grub LIKE I JUST DID? Or http://www.google.com/linux info grub.
Another thing, XP wants to be the first operating system on the hard drive. If you moved stuff around with partition magic or anything, put it back. If you are doing a triple boot, things get pretty hinky.
I should not have made any resposes to your post until you gave a partition map. I have been confused and assumed things. Sorry.
I just reinstalled Windows XP to find that it had overwritten the MBR and my Grub bootloader with it. Which I think is the same problem you had. The info on this thread helped me, but it is incomplete.
Boot from the FC disk, go into rescue mode. Now fdisk -l to see what partition you need to boot from (in my case it was /dev/sda3, the third partition on my one and only hard drive. Then you need to edit /mnt/sysroot/boot/grub/grub.conf. In this file you will need to set any erroneous references to (hd0,0) to the correct (hd0,2), which I know from fdisk listing I just mentioned (note the 2 represents the third partition indexed from 0). And that is it. I rebooted and got into Fedora no problem.
If this doesn't work for you could try copying your important files to you windows partition with explore2fs and then try reinstalling or upgrading you linux installation.
Distribution: Slack Puppy Debian DSL--at the moment.
XP ate Grub installation
Actually, if the partition layout is identical to the original; the only thing necessary to do is run grub. This will replace the MBR with the grub boot loader.
**You have to be careful about running Grub from a rescue disk. Print out the portion of the guide which relates to specifically the parameters that you use to inform the program as to the location of the root of the Linux installation; the location of the /boot directory and the location of the program on the hard disk. If it is too late at night; get some rest, as you can end up making the same mistake over and over again--driving you right up the wall.
If the partitions have changed in any way, then the grub "menu.lst" (in Debian and Debian related distros,) or grub.conf (in the others) has to be edited to reflect the layout. The thing is that the grub installation has to be in the MBR of the first Disk (that is if you want to boot into Grub every time.)
I had many problems recreating a set-up on a machine with six discs after changing out the motherboard. It would appear that SIS chips can still cause "little problems" from time to time--even now. Either that or it had been so long that I had forgotten a whole bunch about Grub. I was forced to put a /boot partition as one of the primary partitions in the beginning of the first hard disk on the system; else it just wouldn't boot. The original layout--which worked on a VIA (and Intel) chipset--simply refused to work on a SiS chipset (unless it was because I was holding my lips wrong.)
I have had as many as 7 different installations of different OS-es booting on this machine--but it takes some tinkering, and a lot of reading to get it all to work. When doing multiple boots with different Microsoft products, one has to "hide" all of the other MS-related partitions while doing the installation and boots. This is taken care of by backing up the MBR before re-installation/installation of any MS product (and restoring it afterwards hiding all of the partitions using fdisk/cfdisk (or one of the others) and adding the commands to the entries in the grub/grub.conf or grub/menu.lst.) These things are covered in the different Guides (http://www.google.com/linux is your friend.)