Grub boot loader with removable drive tray
I have an internal disk with Linux installed and a removable drive bay for swapping out my windows disks. I'd like to get grub to map one option to the bay and be able to boot whatever disk is in there.
Right now it's mapped by id "/dev/disk/by-id/ata-ST3250310AS_6RY00KB61" but I noticed there is a by-path option. I am not sure how to use it and the documentation isn't very detailed so I could use some help. Is by-path a good way to do this or is there some other way to get this to work? |
mitchpotter, it appears you are using Grub2, isn't it?
Under Grub (legacy) you only need to map drives by way of editing a text file configuration. If you can install grub legacy. Until someone here familiar with grub2. Wish they are coming to help you. Goodluck. |
Actually I am using grub, grub2 is not installed.
The menu file: Code:
default 0 Code:
/dev/disk/by-id/ata-ST3250310AS_6RY00KB61 |
It's probably not the best solution, but if you know that the swapped disks will always be the second, third, fourth, or whichever number hard drive for your system, you could look into chainloading onto that swapped disk.
For example - in grub.cfg # boot up second hard drive - perhaps Windows XP menuentry "boot up second hard drive, first partition" { set root=(hd1,1) chainloader +1 } [note: I've read that you should not directly edit grub.cfg for grub2 Sorry I can't help you more, but I thought this info might get you started. Good luck. one grub2 tutorial I found Edit: Well, my post was late and probably not helpful to you |
Well apparently my post isn't helpful either because now it's working and I have no idea what I did to fix it. I just swapped the drives out again and it started working for two of them so far.
Yast now shows Windows as /dev/sdb1 so it must be changing that value based on the drive that's installed when Linux starts up. The drives are mounting correctly too, which is a relief. The menu file didn't change so the mappings are correct. I guess I'll just chalk this up to "typical" Linux behavior. Thanks for trying to help though. =) |
All times are GMT -5. The time now is 01:26 AM. |