Jump to content

GRUB Chainloading Win 7


V.T. Eric Layton
 Share

Recommended Posts

V.T. Eric Layton

I installed Win 7 (all went perfectly, by the way :thumbsup: ) on a newly-added 120Gig drive today. Unfortunately, GRUB is having a problem booting this baby. I can boot my Win XP installation just fine... and all my Linux installs, but not Win 7. I'm not sure I have the GRUB-speak drive/partition/mapping stuff correct. HOW-SOME-EVER, I found a very easy work-around. I just boot that Win 7 drive from BIOS (hotkey - F12 at boot), so easy-peasy! I won't even bother to use GRUB to boot it. COOL, huh?YAY! ;)

Link to comment
Share on other sites

I have seen that Win7 is much more sensitive about loading and sharing 'it's' computer with other OS than XP.I had Win7 loaded first onto my laptop hdd, then loaded linux after. Used Grub to detect and boot them both.After a recent upgrade and re-install using the same hdd, no loading or Grub detection of the Win7 install. I did not touch the Win7 partitions, but did a fresh install of linux on it's partitions only.XP never complained about something like that, but 7 just plain wouldn't boot or even detect afterwards. I never use it, so no big loss.It's just more finicky.

Link to comment
Share on other sites

securitybreach

For grub2 just use:

## Entry 2 Windowsmenuentry "Windows 7 Ultimate" --class "windows" {set root=(hd0,1)chainloader +1}

for grub-legacy use:

title	 windows7 Ultimateroot	 (hd0,1)savedefaultmakeactivechainloader	+1

Link to comment
Share on other sites

Those Grub2 code samples exactly match mine that worked under Debian sid and Arch.When I tried to manually reload that after reinstalling Arch over my sid partitions, Win7 would not boot. Grub2 did not autofind and configure it either and it had before.

Link to comment
Share on other sites

V.T. Eric Layton

Heh! I tried similar chainloading entries. None worked. :) I read that article on the Arch Wiki, too. ;) That Wiki continues to surprise me. It's very useful, even for other distros. :thumbsup:

Link to comment
Share on other sites

securitybreach
Heh! I tried similar chainloading entries. None worked. :( I read that article on the Arch Wiki, too. :) That Wiki continues to surprise me. It's very useful, even for other distros. ;)
I agree. Even if I did not run Archlinux I think I would still use their wiki for reference :thumbsup:
Link to comment
Share on other sites

V.T. Eric Layton

Well, I haven't quite worked out the bugs on booting this Win 7. I'm up later than I have been in two months. I need to go to sleep now. :thumbsup:

Link to comment
Share on other sites

On this laptop, I have this figured out. It just turns out that Grub does indeed boot up Windows Vista. That was choice #1. Choice #2: Use the f key to select Windows on bootup. Choice #3: Linux is on an external hard drive. And so is Grub. So, if I unplug the USB hard drive, Windows will boot up just fine, and no need for Grub.That's one way of managing it.Cheers!

Link to comment
Share on other sites

V.T. Eric Layton

I got it working, but man! It's weird! :whistling: Every time I went to boot my XP, I noticed that 7 was booting instead (it's on a totally different drive). When I tried to boot 7, XP booted up. I have NO clue what's causing this. However, the easy thing to do was to just change the titles of the two Windows installations in menu.lst and ROCK ON down the road, so that's what I did. ;)menu.lst Windows entries:

# This entry manually added by vtel57 for a non-linux OS# on /dev/sdb1title		MS Windows XP Professional SP3unhide		(hd3,0)hide		(hd2,0)root		(hd3,0)map		(hd0) (hd3)map		(hd3) (hd0)chainloader	(hd3,0)+1# This entry manually added by vtel57 for a non-linux OS# on /dev/hdb1title		MS Windows 7 Enterpriseroot		(hd2,0)map		(hd0) (hd2)map		(hd2) (hd0)chainloader	+1

In actuality, XP is on sdb1(hd2,0) and 7 is on hdb1(hd3,0). However, the entries above are swapped. It works. I don't care how/why. Must be FM. ;)

Link to comment
Share on other sites

I got it working, but man! It's weird! :whistling: Every time I went to boot my XP, I noticed that 7 was booting instead (it's on a totally different drive). When I tried to boot 7, XP booted up. I have NO clue what's causing this. However, the easy thing to do was to just change the titles of the two Windows installations in menu.lst and ROCK ON down the road, so that's what I did. ;)menu.lst Windows entries:
# This entry manually added by vtel57 for a non-linux OS# on /dev/sdb1title		MS Windows XP Professional SP3unhide		(hd3,0)hide		(hd2,0)root		(hd3,0)map		(hd0) (hd3)map		(hd3) (hd0)chainloader	(hd3,0)+1# This entry manually added by vtel57 for a non-linux OS# on /dev/hdb1title		MS Windows 7 Enterpriseroot		(hd2,0)map		(hd0) (hd2)map		(hd2) (hd0)chainloader	+1

In actuality, XP is on sdb1(hd2,0) and 7 is on hdb1(hd3,0). However, the entries above are swapped. It works. I don't care how/why. Must be FM. ;)

Which one is hd2 and hd3 depends upon your hd drive boot order in the BIOS. That's why changing that order will cause it to work or not work. However, I don't think changing the BIOS boot order changes the UUID Edited by lewmur
Link to comment
Share on other sites

V.T. Eric Layton

Strange GRUB behavior. :(When in installed that 4th hdd, it really whacked out my GRUB. None of my operating systems on my SATA2 (originally sdb) would load anymore. All the menu.lst entries were incorrect. GRUB thought that drive was now sdb3, not 2. Sheesh! It had me all discombobulated. Oh, well... no biggie. I just removed the extra drive that had the new Win7 installed and I went back to a backed up menu.lst. I modified the back up to add the new Slack installation and away I went. All's well again.I'll play with Win7 on my lappy, once I get it going in a few days. :unsure: I plan on dual-booting Slackware (Primary OS) and Win7 (just for fun) on it. Later all...

Link to comment
Share on other sites

I plan on dual-booting Slackware (Primary OS) and Win7 (just for fun) on it.
In my (admittedly limited) experience, it's easier to install Windows first and then install Linux onto the drive. Or is the fact that it's easier exactly the reason you're rejecting that approach? :unsure:
Link to comment
Share on other sites

I think 'easier' is a massive understatement.Oh, and please tell me, Eric, What about Windows is still 'fun' for you?I ain't seeing it.I have Windows 7 on my laptop, Windows XP and Vista in VirtualBox, all for work.I kind of like 7, I am familiar with XP, I despise Vista.But fun?

Edited by amenditman
Link to comment
Share on other sites

securitybreach
In my (admittedly limited) experience, it's easier to install Windows first and then install Linux onto the drive. Or is the fact that it's easier exactly the reason you're rejecting that approach? :unsure:
Well the reason it is suggested to install windows first on a dual boot system is because the Windows' bootloader will overwrite the MBR/grub and will not recognize any other operating systems. So it will boot straight into windoze everytime. It is fine to install windows after Linux but you will need to recover Grub (bootloader) afterwards in order to boot into Linux.
Link to comment
Share on other sites

Oh, and please tell me, Eric, What about Windows is still 'fun' for you?I ain't seeing it.I have Windows 7 on my laptop, Windows XP and Vista in VirtualBox, all for work.I kind of like 7, I am familiar with XP, I despise Vista.But fun?
I think it's a lot like owning a classic car. You could easily get something that runs a heck of a lot better, but there's a certain cachet to keeping the old girl running - and particularly in keeping her running WELL.Just ask any old gearhead. :unsure:
Well the reason it is suggested to install windows first on a dual boot system is because the Windows' bootloader will overwrite the MBR/grub and will not recognize any other operating systems. So it will boot straight into windoze everytime. It is fine to install windows after Linux but you will need to recover Grub (bootloader) afterwards in order to boot into Linux.
Thanks Josh - I knew it was true but I never understood why. I appreciate the enlightenment! ;)
Link to comment
Share on other sites

V.T. Eric Layton

Yes. I AM a CERTIFIED Multiboot Expert! Don't try this at home, folks. :thumbsdown: Windows (the Borg of operating systems) should ALWAYS be installed first, if at all possible, to lower install stress and aggravation to tolerable levels. :yes:And about that fun... well, I'm new to laptops (getting one fixed up very shortly) and I want to utilize my free Verizon Wifi system (all over town and the nation). Also, I don't really have anything against MS Windows. I was a BIG fan of 3.1, 98SE, and XP at one time. I never had any exposure to Vista, but I do have a nice fresh (legitimate copy) of 7. Since it's been problematic to install and play with it on my desktop system, I figured I'd install it on the lappy.Also, I have gotten very rusty on XP and have had no experience with Vista. It's getting more and more difficult to help my family and friends (the ones I haven't yet converted to Linux) with their computer issues. I figure it's best to stay abreast of the Windows stuff. Ya' never know where I might need to use it.Weeeeeeeee... Weee-Weee-Weeeeeeeeeee...geico_sqealer.jpg

Link to comment
Share on other sites

I figured that with all that squealing piglet imagery, plus the notification that he was "a CERTIFIED Multiboot Expert" that he might have actually done it already and was wondering if he'd figured out how to phase-shift his weapons to get past those Borg shields! :thumbsdown:

Link to comment
Share on other sites

So DID you actually install "the Borg of operating systems" first? Inquiring minds want to know!
Chip,This is for future reference – knowing that you'll end up tinkering your systems beyond... ahem.So... you have to reinstall Windows [not an unheard-of-scenario], and, Windows is what Windows does, *poof* there went your Grub.Now follows the "stress and aggravation" bit Eric mentioned. It's by no means rocket science, but an extra bit of hassle:Recovering Ubuntu After Installing WindowsNote that – even though that HOWTO is written for Ubuntu – you can use your PCLos disk just as well (just remember that PCLos doesn't use "sudo" so you have to execute every "sudo command" as root... and PCLos 2010 (AFAIK) uses "Grub Legacy" and not "Grub2".)
Link to comment
Share on other sites

Chip,This is for future reference – knowing that you'll end up tinkering your systems beyond... ahem.So... you have to reinstall Windows [not an unheard-of-scenario], and, Windows is what Windows does, *poof* there went your Grub.Now follows the "stress and aggravation" bit Eric mentioned. It's by no means rocket science, but an extra bit of hassle:Recovering Ubuntu After Installing WindowsNote that – even though that HOWTO is written for Ubuntu – you can use your PCLos disk just as well (just remember that PCLos doesn't use "sudo" so you have to execute every "sudo command" as root... and PCLos 2010 (AFAIK) uses "Grub Legacy" and not "Grub2".)
PCLOS uses su instead, as I discovered quite by accident the day before yesterday when I formatted the new drive. Now I'm thinking of creating a boot disc from the basic system and I was browsing through Bruno;s tips and tricks trying to figure out how to do it. Seems pretty straightforward, actually. And since I don't really have much of anything on the drive at all that I'd fret over losing, I figure that NOW is the time to do such a thing!
Link to comment
Share on other sites

securitybreach
Another good thing to do once you get your system set up and tweaked, image the drive as a full restore.For use just in case of total disaster.See here for a good how-tohttp://forums.scotsnewsletter.com/index.ph...showtopic=38812
Yeah I really need to do this sometime. Do not get me wrong, I backup everything. I rsync my /home directory and my /etc directory twice a day to a backup harddrive in my box. I also have my /home directory as a separate partition so if I have to reinstall I do not lose any data. But being able to take a "snapshot" of your installation can be very useful if you bork your install. If you have the time and the space I would recommend taking a "snapshot" of your install using Clonezilla. After all, Frank wrote a nice howto for using it.Archlinux users here is a nice tip:You can get an list of you install package by doing as regular user:
pacman -Qet | awk '{print $1}' > installed_packages.txt

and then you can reinstall everything using the installed_packages.txt file as root:

# pacman -Sy `cat installed_packages.txt`

Now you will still have to edit your configurations if you did not backup those files.

Link to comment
Share on other sites

V.T. Eric Layton
So DID you actually install "the Borg of operating systems" first? Inquiring minds want to know!
On my desktop system? Of course not. I have too many other existing operating systems on there already. I wasn't going to reinstall all of them after Win 7. I did the next best thing... I installed it on its own drive. Worked like a champ, but I didn't like the way adding the extra drive confused my GRUB, so I removed it.On the lappy, I will be installing Win 7 first, then Slackware (primary OS). :yes:
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...