Linux - SoftwareThis forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.
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.
I'd like to use grub on a cd (or preferably a usb stick) to boot to grub somewhere else (in my case /dev/sda5).
I have a work laptop that I really don't want to mess with the MBR of which is running WXP, but it has loads of space on the hard drive which I'd like to install a linux (or two) on. So if I installed grub on a cd (or usb stick) and aimed it at /dev/sda5 (but have to work out where that is in grub language), then had grub installed on that partition, then whenever I made changes to the linux(es), I would only change the grub setup on sda5, and not on the cd. To be clear, the aim is not to boot a kernel with the grub on the cd (or usb stick), but to boot another instance of grub. Is this possible?
So the cd (or stick) would just be a key, which would allow access to /dev/sda5, and would work for whatever I setup in grub in sda5. And without the key, WXP would boot in blissful ignorance of the power above.
So, the bits I can't yet figure...
Is this chainloading? Like what grub does to get Windows loaded?
So I'd use chainloader in grub on the cd? But point it where?
And does this mean a logical partition has a boot record of its own to load grub into? So I just install grub onto that partition, not that disk MBR? But then that goes back to the question of where to point the chainloader command on grub on the cd.
Do I need to makeactive the linux boot partition, and if I do, will this stop WXP from booting if the machine is booted without the CD (this I really don't want)?
Also am I right in thinking that WXP won't see any linux ext2, ext3 or swap partitions?
Normally I'd just blast away and get there in the end, but I don't want to have to go back to the excellent IT support staff and tell them I've broken the new toy so quickly and ask could they please reinstall all that lovely network software. So this time I will be careful and know what I'm doing before I do it. I really don't want any interaction with the Windows partition when I do this (including unsetting its active state, if that has any meaning).
right, back to reading manuals - any guidance appreciated
What is known to work: Make a boot floppy with grub on it---that is how my home system works.
Also, you might look at the "Ultimate boot CD"---I think (not sure) that their site has suggestions for setting up OSes so that this CD sees them.
You can configure the **Windows** bootloader to boot other OSes. You edit a little file called "boot.ini" Advantage of this is that it is easy to keep a backup of this file for restoring if you make a boo-boo.
For the ultimate in multi-booting tips, Search on "Saikee" here and look in his sig.
can't use a floppy - haven't got a drive
but i'll do what you suggest on a cd as a beginning.
i have a slax cd image that is very easy to modify - easier than building my own - think it uses grub, so just have to change the menu.lst (i hope)
i'm pretty sure that it's going to be something like this:
title linux
root (hd0,5)
chainloader +1
boot
(hd0,5) is hda6 on this thing
then do a grub-install onto hda6
lets see how much plastic i can turn into frisbees
put grub onto a USB stick, which chainloads grub on a hd partition. this leaves my work Windows install with its MBR untouched.
the USB stick is now just a key, if it's not in at boot then Windows loads from the MBR.
any changes to menu.lst are made to the one on the hard-drive partition.
one small, but annoying, complication. when you boot to the stick, grub calls it hd0, so the hard drive becomes hd1. so if you do any autoupdating of menu.lst with package managers, you need to change the automagicked
root (hd0,X)
to
root (hd1,X)
else grub won't find your kernel/initrd
this may also be the reason that Windows didn't want to be chainloaded using this method (but I don't care about that, cause I can boot it the old-fashioned MBR way)
there might be a way around this that involves whipping the usb stick out before it chainloads the second instance of grub, but i'll be happy with this for a while i think
if anyone ever follows this thread, look where pixellany said in the post 2 up from this one, that Saikee is a grub-booting guru, also read the grub manual. there are a couple of ways to do it.
the partitioning/formatting of the usb stick so it would be bootable was most challenging for me. i tried qtparted first, then cfdisk, then finally fdisk. again, there's plenty written on the topic. ask me if you can't find the way.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.