Grub help...need to change from hda to sda
I've just installed a 3ware raid card, copied, via dd, an old IDE drive to a new drive attached to the raid card and now need to know how to change grub to point to the new drive. Here's what my current grub.conf says on the new drive: root (hd0,1) install --stage2=/boot/grub/stage2 /boot/grub/stage1 d (hd0) /boot/grub/stage2 0x8000 (hd0,1)/boot/grub/menu.lst quit I believe I should change the hd0 to sd0....correct? Once I do that, do I need to do something else to get it to setup properly? I changed my fstab already on the new drive. Thanks, Tom -- Tom Nielsen Neuro Logic Systems 805.389.5435 x18 www.neuro-logic.com
I've just installed a 3ware raid card, copied, via dd, an old IDE drive to a new drive attached to the raid card and now need to know how to change grub to point to the new drive. Here's what my current grub.conf says on the new drive:
root (hd0,1) install --stage2=/boot/grub/stage2 /boot/grub/stage1 d (hd0) /boot/grub/stage2 0x8000 (hd0,1)/boot/grub/menu.lst quit
I believe I should change the hd0 to sd0....correct? Once I do that, do I need to do something else to get it to setup properly? I changed my fstab already on the new drive.
Tom, I have the same setup as you, except I have 4 IDE drives in RAID 0 on a 4 port Escalade ( 3Ware Card ). Here are my setup files. This may or may not help you out. FSTAB ===== falcon:/etc # cat fstab /dev/sda1 / reiserfs defaults 1 1 /dev/hdb1 /boot ext2 defaults 1 2 /dev/sda3 /home reiserfs defaults 1 2 /dev/sda2 /usr reiserfs defaults 1 2 /dev/hdb2 swap swap pri=42 0 0 devpts /dev/pts devpts mode=0620,gid=5 0 0 proc /proc proc defaults 0 0 usbdevfs /proc/bus/usb usbdevfs noauto 0 0 /dev/cdrom /media/cdrom auto ro,noauto,user,exec 0 0 /dev/fd0 /media/floppy auto noauto,user,sync 0 0 /dev/hdb3 /scratchspace reiserfs defaults 1 2 /dev/hdb4 swap swap pri=42 0 0 /dev/hdc /media/burner auto no,noauto,user,exec 0 0 /dev/cdrom1 /media/cdrom1 auto ro,noauto,user,exec 0 0 /dev/cdrom7 /media/cdrom7 auto ro,noauto,user,exec 0 0 /dev/sdb1 /media/iomega128 vfat default,user,exec 0 0 NOTE: /dev/sda1, /dev/sda2 and /dev/sda3 are all partitions carved out of the single 3Ware raid "disk". MTAB ==== falcon:/etc # cat /etc/mtab /dev/sda1 / reiserfs rw 0 0 proc /proc proc rw 0 0 devpts /dev/pts devpts rw,mode=0620,gid=5 0 0 /dev/hdb1 /boot ext2 rw 0 0 /dev/sda3 /home reiserfs rw 0 0 /dev/sda2 /usr reiserfs rw 0 0 shmfs /dev/shm shm rw 0 0 usbdevfs /proc/bus/usb usbdevfs rw 0 0 /dev/sdb1 /media/iomega128 vfat rw,nosuid,nodev,default,user=jrn 0 0 Again, the /dev/sda1, /dev/sda2 and /dev/sda3 are the partitions carved out of the single 3Ware raid "disk". GRUB MENU.LST ============== falcon:/boot/grub # cat menu.lst gfxmenu (hd0,0)/message color white/blue black/light-gray default 6 timeout 8 title floppy root (fd0) chainloader +1 title failsafe kernel (hd0,0)/vmlinuz.shipped root=/dev/sda1 ide=nodma apm=off acpi=off vga=normal nosmp maxcpus=0 disableapic 3 initrd (hd0,0)/initrd.shipped title Linux-2.4.20-test2 kernel (hd0,0)/linux-2.4.20-test2 root=/dev/sda1 hdc=ide-scsi hdd=ide-scsi title Linux-2.4.21 kernel (hd0,0)/linux-2.4.21 root=/dev/sda1 hdc=ide-scsi title Linux-2.4.21-2 kernel (hd0,0)/linux-2.4.21-2 root=/dev/sda1 hdc=ide-scsi initrd (hd0,0)/initrd-linux-2.4.21-2 title Linux-2.4.21-3 kernel (hd0,0)/linux-2.4.21-3 root=/dev/sda1 hdc=ide-scsi title Linux-2.4.21-test kernel (hd0,0)/linux-2.4.21-4 root=/dev/sda1 hdc=ide-scsi initrd (hd0,0)/initrd-linux-2.4.21-4 title Linux-2.4.22-pre10 kernel (hd0,0)/linux-2.4.22-pre10 root=/dev/sda1 title Linux-2.4.22 kernel (hd0,0)/linux-2.4.22 root=/dev/sda1 hdc=ide-scsi NOTE: root=/dev/sda1 ( this is my 'root' partition ) Again, hope this helps. -Jim-
On Thu, 2003-09-04 at 09:55, Jim Norton wrote: [snip]
GRUB MENU.LST ==============
falcon:/boot/grub # cat menu.lst
gfxmenu (hd0,0)/message color white/blue black/light-gray default 6 timeout 8
title floppy root (fd0) chainloader +1
title failsafe kernel (hd0,0)/vmlinuz.shipped root=/dev/sda1 ide=nodma apm=off acpi=off vga=normal nosmp maxcpus=0 disableapic 3 initrd (hd0,0)/initrd.shipped
title Linux-2.4.20-test2 kernel (hd0,0)/linux-2.4.20-test2 root=/dev/sda1 hdc=ide-scsi hdd=ide-scsi
title Linux-2.4.21 kernel (hd0,0)/linux-2.4.21 root=/dev/sda1 hdc=ide-scsi
title Linux-2.4.21-2 kernel (hd0,0)/linux-2.4.21-2 root=/dev/sda1 hdc=ide-scsi initrd (hd0,0)/initrd-linux-2.4.21-2
title Linux-2.4.21-3 kernel (hd0,0)/linux-2.4.21-3 root=/dev/sda1 hdc=ide-scsi
title Linux-2.4.21-test kernel (hd0,0)/linux-2.4.21-4 root=/dev/sda1 hdc=ide-scsi initrd (hd0,0)/initrd-linux-2.4.21-4
title Linux-2.4.22-pre10 kernel (hd0,0)/linux-2.4.22-pre10 root=/dev/sda1
title Linux-2.4.22 kernel (hd0,0)/linux-2.4.22 root=/dev/sda1 hdc=ide-scsi
NOTE: root=/dev/sda1 ( this is my 'root' partition )
Again, hope this helps.
-Jim-
Since mine grub says: root (hd0,1) install --stage2=/boot/grub/stage2 /boot/grub/stage1 d (hd0) /boot/grub/stage2 0x8000 (hd0,1)/boot/grub/menu.lst quit Do you think I'll have a problem booting? Do I need to reference anything in grub like hdc=scsi? Tom -- Tom Nielsen Neuro Logic Systems 805.389.5435 x18 www.neuro-logic.com
GRUB MENU.LST ==============
falcon:/boot/grub # cat menu.lst
gfxmenu (hd0,0)/message color white/blue black/light-gray default 6 timeout 8
title floppy root (fd0) chainloader +1
title failsafe kernel (hd0,0)/vmlinuz.shipped root=/dev/sda1 ide=nodma apm=off acpi=off vga=normal nosmp maxcpus=0 disableapic 3 initrd (hd0,0)/initrd.shipped
title Linux-2.4.20-test2 kernel (hd0,0)/linux-2.4.20-test2 root=/dev/sda1 hdc=ide-scsi hdd=ide-scsi
title Linux-2.4.21 kernel (hd0,0)/linux-2.4.21 root=/dev/sda1 hdc=ide-scsi
title Linux-2.4.21-2 kernel (hd0,0)/linux-2.4.21-2 root=/dev/sda1 hdc=ide-scsi initrd (hd0,0)/initrd-linux-2.4.21-2
title Linux-2.4.21-3 kernel (hd0,0)/linux-2.4.21-3 root=/dev/sda1 hdc=ide-scsi
title Linux-2.4.21-test kernel (hd0,0)/linux-2.4.21-4 root=/dev/sda1 hdc=ide-scsi initrd (hd0,0)/initrd-linux-2.4.21-4
title Linux-2.4.22-pre10 kernel (hd0,0)/linux-2.4.22-pre10 root=/dev/sda1
title Linux-2.4.22 kernel (hd0,0)/linux-2.4.22 root=/dev/sda1 hdc=ide-scsi
NOTE: root=/dev/sda1 ( this is my 'root' partition )
Again, hope this helps.
-Jim-
Since mine grub says:
root (hd0,1) install --stage2=/boot/grub/stage2 /boot/grub/stage1 d (hd0) /boot/grub/stage2 0x8000 (hd0,1)/boot/grub/menu.lst quit
Do you think I'll have a problem booting? Do I need to reference anything in grub like hdc=scsi?
Tom
Tom, it's really hard to say. You really need to make sure your entries in fstab,mtab and /boot/grub/menu.lst agree. If you post the contents of those three files, we might be able to give an accurrate or better answer. Those (hdx,y) numbers are affected by where drives are installed and how the system sees them. Correct me if I'm wrong on that point folks. For example, an IDE drive on IDE channel 1 port 0 will have a different (hdx,y) value than if that drive was on IDE channel 1 port 1 or channel 2 port 0. Clear as mud? -Jim-
On Thu, 2003-09-04 at 10:45, Jim Norton wrote: Firstly, let me say that I'm sorry about being such a pain and thanks to all for working with me on this.
Tom, it's really hard to say. You really need to make sure your entries in fstab,mtab and /boot/grub/menu.lst agree. If you post the contents of those three files, we might be able to give an accurrate or better answer. Those (hdx,y) numbers are affected by where drives are installed and how the system sees them. Correct me if I'm wrong on that point folks. For example, an IDE drive on IDE channel 1 port 0 will have a different (hdx,y) value than if that drive was on IDE channel 1 port 1 or channel 2 port 0.
Here's the information from my new drive (which I dd'd from my old drive) on my raid card. I only changed info on FSTAB FSTAB /dev/sda2 / reiserfs defaults 1 1 (this used to be hdc2 - I can manually mount this drive now....and it is connected to my raid card) /dev/sda1 swap swap pri=42 0 0 (this used to be hdc1) devpts /dev/pts devpts mode=0620,gid=5 0 0 proc /proc proc defaults 0 0 usbdevfs /proc/bus/usb usbdevfs noauto 0 0 /dev/cdrom /media/cdrom auto ro,noauto,user,exec 0 0 /dev/fd0 /media/floppy auto noauto,user,sync 0 0 GRUB.CONF root (hd0,1) install --stage2=/boot/grub/stage2 /boot/grub/stage1 d (hd0) /boot/grub/stage2 0x8000 (hd0,1)/boot/grub/menu.lst quit MTAB /dev/hdc2 / reiserfs rw 0 0 proc /proc proc rw 0 0 devpts /dev/pts devpts rw,mode=0620,gid=5 0 0 shmfs /dev/shm shm rw 0 0 usbdevfs /proc/bus/usb usbdevfs rw 0 0 /BOOT/GRUB/MENU.LST # Modified by YaST2. Last modification on Wed Sep 3 23:30:14 2003 color white/blue black/light-gray default 0 timeout 8 title linux kernel (hd0,1)/boot/vmlinuz root=/dev/hdc2 vga=0x31a splash=silent showopts initrd (hd0,1)/boot/initrd title floppy root (fd0) chainloader +1 title failsafe kernel (hd0,1)/boot/vmlinuz.shipped root=/dev/hdc2 showopts ide=nodma apm=off acpi=off vga=normal nosmp noapic maxcpus=0 3 initrd (hd0,1)/boot/initrd.shipped I gather that I'm going to have to change all the hd to sd. No? Tom -- Tom Nielsen Neuro Logic Systems 805.389.5435 x18 www.neuro-logic.com
On Thursday 04 September 2003 12:42 pm, Tom Nielsen wrote:
I've just installed a 3ware raid card, copied, via dd, an old IDE drive to a new drive attached to the raid card and now need to know how to change grub to point to the new drive. Here's what my current grub.conf says on the new drive:
root (hd0,1) install --stage2=/boot/grub/stage2 /boot/grub/stage1 d (hd0) /boot/grub/stage2 0x8000 (hd0,1)/boot/grub/menu.lst quit
I believe I should change the hd0 to sd0....correct? Once I do that, do I need to do something else to get it to setup properly? I changed my fstab already on the new drive.
B--zzzz-T wrong. Grub doesn't care whether a drive is scsi or IDE and it calls them both: hdx So you may not need to change anything... assuming your partitions look the same (are in the same numbering position) as they were. You didn't say enough about your config to comment.
Thanks, Tom
-- +----------------------------------------------------------------------------+ + Bruce S. Marshall bmarsh@bmarsh.com Bellaire, MI 09/04/03 12:56 + +----------------------------------------------------------------------------+ "A diplomat is someone who can tell you to go to hell and make you feel you feel happy to be on your way."
participants (3)
-
Bruce Marshall
-
jrn@oregonhanggliding.com
-
Tom Nielsen