Background: This is a dual boot (Windows XP and CentOS 5.2 (32 bit) box. There were four (4) NTFS partitions. The C partition got full. I deleted the 4 NTFS partitions and did a clean install of Windows XP, into one (1) NTFS partition. I knew that I would need to install GRUB again and I did that, using the CentOS 5 Installation DVD. When I tried to boot into Linux, no joy. this is the GRUB error I got:
Booting 'CentOS (2.6.18-92.1.17.el5)' root (hd0,2) Filesystem type unknown, partition type 0x8e Kernel /vmlinuz-2.6.18-92.1.17.el5 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
Error 17: Cannot mount selected partition Press any key to continue
(same error, trying to boot the 2 older Linux Kernels)
The CentOS 5 Installation DVD apparently is now damaged (Murphy's Law). I have available to me: (a) CentOS 5.2 i386 Live CD (I am running on that, as I write this email) (b) Knoppix Live Disk, V.5.1.1 (c) SystemRescueCD V.0.2.15
The partitions on my hard drive, as shown by QTParted on the Knoppix Live CD are now:
01 /dev/hda1 ntfs Active 02 /dev/hda2 ext3 (/boot) 03 /dev/hda3 unknown (CentOS LVM)
My belief is that /hda3 is not mounted. If I click on the "Local Hard Drives" Icon under "disc" it only shows hda2 (the Linux /boot partition). How and where do I fix that?
When I view /etc/fstab as centos user with the CentOS 5.2 Live CD, I see that the line I had to mount the NTFS data partition (E: when I had 4 NTFS partitions) showed it as /dev/hda6 Now, the only NTFS partition, C, is /dev/hda1. Viewing it as centos user, in gedit, it is read only. When I try to view it as root, it shows me a /etc/fstab file that apparently is created by the LiveCD and doesn't show the Windows partition. How do I edit the /etc/fstab file so I can change it from /hda6 to /hda1? Here's the file contents:
/dev/VolGroup00/LogVol00 / ext3 defaults 1 1 LABEL=/boot /boot ext3 defaults 1 2 devpts /dev/pts devpts gid=5,mode=620 0 0 tmpfs /dev/shm tmpfs defaults 0 0 proc /proc proc defaults 0 0 sysfs /sys sysfs defaults 0 0 /dev/VolGroup00/LogVol01 swap swap defaults 0 0 /dev/hda6 /mnt/win ntfs-3g rw,umask=0000,defaults 0 0
TIA! Lanny
There is a Permissions problem, when I try to access /boot/grub/grub.conf and /etc/fstab so I can edit them. How can I do that, using the Live CD's I have? I need root access.
On 11/8/08, Lanny Marcus lmmailinglists@gmail.com wrote:
Background: This is a dual boot (Windows XP and CentOS 5.2 (32 bit) box. There were four (4) NTFS partitions. The C partition got full. I deleted the 4 NTFS partitions and did a clean install of Windows XP, into one (1) NTFS partition. I knew that I would need to install GRUB again and I did that, using the CentOS 5 Installation DVD. When I tried to boot into Linux, no joy. this is the GRUB error I got:
Booting 'CentOS (2.6.18-92.1.17.el5)' root (hd0,2) Filesystem type unknown, partition type 0x8e Kernel /vmlinuz-2.6.18-92.1.17.el5 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
Error 17: Cannot mount selected partition Press any key to continue
(same error, trying to boot the 2 older Linux Kernels)
The CentOS 5 Installation DVD apparently is now damaged (Murphy's Law). I have available to me: (a) CentOS 5.2 i386 Live CD (I am running on that, as I write this email) (b) Knoppix Live Disk, V.5.1.1 (c) SystemRescueCD V.0.2.15
The partitions on my hard drive, as shown by QTParted on the Knoppix Live CD are now:
01 /dev/hda1 ntfs Active 02 /dev/hda2 ext3 (/boot) 03 /dev/hda3 unknown (CentOS LVM)
My belief is that /hda3 is not mounted. If I click on the "Local Hard Drives" Icon under "disc" it only shows hda2 (the Linux /boot partition). How and where do I fix that?
When I view /etc/fstab as centos user with the CentOS 5.2 Live CD, I see that the line I had to mount the NTFS data partition (E: when I had 4 NTFS partitions) showed it as /dev/hda6 Now, the only NTFS partition, C, is /dev/hda1. Viewing it as centos user, in gedit, it is read only. When I try to view it as root, it shows me a /etc/fstab file that apparently is created by the LiveCD and doesn't show the Windows partition. How do I edit the /etc/fstab file so I can change it from /hda6 to /hda1? Here's the file contents:
/dev/VolGroup00/LogVol00 / ext3 defaults 1 1 LABEL=/boot /boot ext3 defaults 1 2 devpts /dev/pts devpts gid=5,mode=620 0 0 tmpfs /dev/shm tmpfs defaults 0 0 proc /proc proc defaults 0 0 sysfs /sys sysfs defaults 0 0 /dev/VolGroup00/LogVol01 swap swap defaults 0 0 /dev/hda6 /mnt/win ntfs-3g rw,umask=0000,defaults 0 0
TIA! Lanny
Lanny Marcus wrote:
There is a Permissions problem, when I try to access /boot/grub/grub.conf and /etc/fstab so I can edit them. How can I do that, using the Live CD's I have? I need root access.
Instead of using a LIVECD, have you tried using the CentOS rescue CD and then using the grub command. I don't have Centos 5 but you can look at the CentOS docs or a quick Fedora example below.
http://dailypackage.fedorabook.com/index.php?/archives/158-System-Recovery-W...
Regards, Vandaman.
On Sun, Nov 9, 2008 at 4:22 AM, Vandaman vandaman2002-sk@yahoo.co.uk wrote:
There is a Permissions problem, when I try to access /boot/grub/grub.conf and /etc/fstab so I can edit them. How can I do that, using the Live CD's I have? I need root access.
Instead of using a LIVECD, have you tried using the CentOS rescue CD and then using the grub command. I don't have Centos 5 but you can look at the CentOS docs or a quick Fedora example below.
http://dailypackage.fedorabook.com/index.php?/archives/158-System-Recovery-W...
Initially, I was able to boot the CentOS 5 Installation DVD and that is how I reinstalled GRUB, using "linux rescue", after the reinstallation of MS Windows on this dual boot box. Somehow, the CentOS 5 Installation DVD got damaged, as I tried to resolve this problem, so now I am limited to the Live CDs I have and since I am very limited in my knowledge of Linux, I don't know how to get real root privileges, while using the Live CDs.
Seems like I need to solve two (2) problems, in order to get GRUB working properly again on this dual boot box and be able to boot into Linux again: (a) Get real root access, while using Live CD's (b) Modify one or two configuration files (/etc/fstab and /boot/grub/grub.conf) to reflect the fact that now there is only one partition for Windows, where previously there were four Windows partitions.
Question: You mentioned the "CentOS rescue CD". Is there something else, other than the CentOS 5 Installation DVD I have, which is damaged? Our DSL is very slow (550) so it would take me a long time to try to download that.
Note: Sorry for my delay in replying to you. Our ADSL went down yesterday and the phone company just fixed their problem. TIA.
Lanny Marcus wrote:
Booting 'CentOS (2.6.18-92.1.17.el5)' root (hd0,2) Filesystem type unknown, partition type 0x8e Kernel /vmlinuz-2.6.18-92.1.17.el5 ro root=/dev/VolGroup00/LogVol00 rhgb quiet
Error 17: Cannot mount selected partition Press any key to continue
01 /dev/hda1 ntfs Active 02 /dev/hda2 ext3 (/boot) 03 /dev/hda3 unknown (CentOS LVM)
AFAIK,in centos or fedora a boot partition cannot reside in an LVM volume.a boot partition must be a regular ext2 or ext3 file system.
or are you trying to boot from from wrong partition ? /dev/hda2 is labled as boot and is an ext3 filesystem. so i am inclined to believe that is the partition where the vmlinuz and initrd file resides. you need to change the line "root (hd0,2)" to "root (hd0,1)" during booting.
On Sun, Nov 9, 2008 at 9:06 AM, partha chowdhury kira.laucas@gmail.com wrote:
Lanny Marcus wrote:
<snip>
01 /dev/hda1 ntfs Active 02 /dev/hda2 ext3 (/boot) 03 /dev/hda3 unknown (CentOS LVM)
AFAIK,in centos or fedora a boot partition cannot reside in an LVM volume.a boot partition must be a regular ext2 or ext3 file system.
Yes. There's a separate ext3 partition, /boot, with 102 MB, that's /dev/hda2 and it isn't in an LVM.
Problem now, as I just replied to Vandaman, is that my CentOS 5 Installation DVD got damaged, after I reinstalled GRUB and before I could modify two configuration files. I have several Live CDs, but don't know how to get real "root" privileges with them.
Sorry for delay in my reply. Our ADSL was down.
On Mon, Nov 10, 2008 at 11:38 AM, Phil Schaffner Philip.R.Schaffner@nasa.gov wrote:
Lanny Marcus wrote:
I have several Live CDs, but don't know how to get real "root" privileges with them.
Often "su -" in a terminal window is all that's required to get root for a live CD.
Phil: I think I tried that, Saturday afternoon, but I will try it again, after my daughter gets home. As I recall, that did not get me into the true "root" environment, but into root for the Live CD. I will try it again, with each of the 3 Live CD's, and report back to the list. When I tried to edit one of the configuration files I need to edit, it was a different configuration file, provided by the Live CD. Thanks! Lanny
On Mon, Nov 10, 2008 at 11:38 AM, Phil Schaffner Philip.R.Schaffner@nasa.gov wrote:
Lanny Marcus wrote:
I have several Live CDs, but don't know how to get real "root" privileges with them.
Often "su -" in a terminal window is all that's required to get root for a live CD.>
Phil: I'm running on my CentOS 5.2 Live CD, in the belief that one is better able to help me than the Knoppix or SystemRescue Live CDs (the SystemRescue CD is very old).
On the GNOME Desktop, there's an Icon for "Local Hard Drives". If I double click on that, it shows hda2 which is the /boot ext3 partition (102 MB)
There is also an Icon for "Local Logical Volumes". If I double click on that, it shows VolGroup00-LogVol00 and everything is there, in the LVM. :-)
Here's the result of the "mount" command
[centos@localhost ~]$ mount /dev/mapper/livecd-rw on / type ext3 (rw,noatime) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) tmpfs on /dev/shm type tmpfs (rw) none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw) /dev/hdc on /mnt/live type iso9660 (ro) /dev/hda2 on /mnt/disc/hda2 type ext3 (ro) /dev/mapper/VolGroup00-LogVol00 on /mnt/lvm/VolGroup00-LogVol00 type ext3 (ro) sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw) [centos@localhost ~]$
Question: Is /hda3 mounted properly? I don't think so, because when I try to boot Linux from the Grub menu on the HD, it gives me "Error 17: Cannot mount selected partition"
Here's the contents of fstab (which I'm looking at Read Only)
/dev/VolGroup00/LogVol00 / ext3 defaults 1 1 LABEL=/boot /boot ext3 defaults 1 2 devpts /dev/pts devpts gid=5,mode=620 0 0 tmpfs /dev/shm tmpfs defaults 0 0 proc /proc proc defaults 0 0 sysfs /sys sysfs defaults 0 0 /dev/VolGroup00/LogVol01 swap swap defaults 0 0 /dev/hda6 /mnt/win ntfs-3g rw,umask=0000,defaults 0 0
What I need to modify in fstab is the last line. I need to change it from /dev/hda6 to /dev/hda1 so I can read/write NTFS files from CentOS.
If I can get to the 2 configuration files (fstab and grub.conf) with true root access, so I can modify them, with Gedit I should be able to get this box working on Linux again.
Not sure of the proper locations to give for those files, so I can get to them from a terminal window, after "su -", with gedit.
These are the types of trivial problems which cause newbies frustration. On the other hand, there have been times, when my wife and daughter cannot do something on M$ Windows and they can do it on Linux. :-) This would be easier, I'm sure, if my CentOS 5 Installation DVD hadn't gotten damaged Saturday.
Your time, help and willingness to share your expertise are much appreciated! Lanny
On Mon, Nov 10, 2008 at 12:58 PM, Lanny Marcus lmmailinglists@gmail.com wrote:
Here's the result of the "mount" command
[centos@localhost ~]$ mount /dev/mapper/livecd-rw on / type ext3 (rw,noatime) proc on /proc type proc (rw) sysfs on /sys type sysfs (rw) devpts on /dev/pts type devpts (rw,gid=5,mode=620) tmpfs on /dev/shm type tmpfs (rw) none on /proc/sys/fs/binfmt_misc type binfmt_misc (rw) /dev/hdc on /mnt/live type iso9660 (ro) /dev/hda2 on /mnt/disc/hda2 type ext3 (ro) /dev/mapper/VolGroup00-LogVol00 on /mnt/lvm/VolGroup00-LogVol00 type ext3 (ro) sunrpc on /var/lib/nfs/rpc_pipefs type rpc_pipefs (rw) [centos@localhost ~]$
Question: Is /hda3 mounted properly? I don't think so, because when I try to boot Linux from the Grub menu on the HD, it gives me "Error 17: Cannot mount selected partition"
When I had this error, it meant that grub could not find the boot partition itself. (The boot PROM did, but grub doesn't see the disks the same way and can get lost.)
Someone just answered earlier in this thread that you need to change your hd(0,2) to hd(0,1) on the grub boot line. That should work. You don't need to do this from any special rescue boot, just boot the system, and when the grub stage 2 boot selection shows with its countdown, stop it (with the space bar) and use the grub shell to edit that line and it _should_ boot properly.
If WCTW, instead of downloading the CentOS 5 DVD, just pull down the first CD image and burn that. It's a lot shorter than the whole DVD, and it's all you need to get into rescue mode.
HTH
mhr