Linux Mint Forums

Forum rules
There are no such things as "stupid" questions. However if you think your question is a bit stupid, then this is the right place for you to post it. Please stick to easy to-the-point questions that you feel people can answer fast. For long and complicated questions prefer the other forums within the support section.Before you post please read how to get help

The Windows boot loader is on the MBR and GRUB 1.99 is I believe in the boot partition.

I have noticed that when Windows has been hibernated the Windows boot loader does not even come up and I am taken straight into Windows. The only way to then get back into Linux is to shut down windows fully.

My question is how do I replace the Windows boot loader with GRUB so I can boot either OS hibernated or not?

If you've got Mint installed, chances are that you've got GRUB as your bootloader (it is usually installed during the installation process for Mint).

As for hibernation, if you hibernate and shut down, then select Windows when you boot, everything should be okay (this sounds like the situation you're in already). If you hibernate, then boot into Linux, and restart and try to boot into Windows, Windows will complain and be unable to restore. To put that simply, what you're trying to do has nothing with GRUB, it won't work because of a restriction with Windows.

GusGF wrote:I have noticed that when Windows has been hibernated the Windows boot loader does not even come up and I am taken straight into Windows. The only way to then get back into Linux is to shut down windows fully.

Given the way most users implement cross-OS file access, this is probably for the best. The problem is that hibernating a computer usually leaves disk access in a "used" state -- that is, the data structures on the disk are not necessarily internally consistent. This is OK if the computer is booted straight back into the original hibernated OS, since the missing information is originally held in memory, then stored on disk for hibernation, and then restored. Thus, after hibernating and returning from hibernation, the OS can still manage the disk and shut it down correctly. If, on the other hand, you reboot into another OS, and if you then attempt to access any filesystems that the first OS had open, the disk will look as if the computer had crashed. Depending on the filesystems and OSes involved and the specific details of what files were being accessed, etc., this could result in an inability to access the disk, in a successful disk "repair" being performed, or even in damage to the filesystem. When the first OS is rebooted, it may end up being confused about the state of the disk, so there's further risk of damage at that point.

Of course, all of this is an issue only if you mount shared filesystems across your OSes. Most Linux users do this on dual-boot configurations, though, so chances are this isn't really an "out." OTOH, the last time I checked, Linux's NTFS drivers tended to refuse to mount an NTFS volume that wasn't properly unmounted, so the risk of damage to an NTFS volume is likely to be fairly low. Still, I prefer to play it safe when it comes to cross-OS filesystem access.

So in sum, if you hibernate, you really should plan on booting back to the original OS the next time you power on. If your boot loader enforces such an action, then that's a good thing, since it makes it less likely that you'll end up trashing your disk through an accidental boot into the wrong OS.

rprego wrote:If you've got Mint installed, chances are that you've got GRUB as your bootloader (it is usually installed during the installation process for Mint).

As for hibernation, if you hibernate and shut down, then select Windows when you boot, everything should be okay (this sounds like the situation you're in already). If you hibernate, then boot into Linux, and restart and try to boot into Windows, Windows will complain and be unable to restore. To put that simply, what you're trying to do has nothing with GRUB, it won't work because of a restriction with Windows.

Sorry rprego not sure what post you were reading but I did state windows bootloader is the first loader since its in the MBR!

if you hibernate and shut down

What?????????

If you hibernate, then boot into Linux

........ eh thats what I'm trying to do and no it won't complain because other people have done it and done it using more than 2 OS. Please see here

Hi srs5694,Thank you for your informative post and for highlighting issues with dual booting systems. It certainly is a concern I will keep in mind and was aware of it though I certainly don't know the ins and outs of it.

But I still do want to have a dual boot post Win7 hibernation which I can do if I can only figure out how to move GRUB to the MBR, but I do need some help and guidance

So hopefully someone can chime in with some help.

Cheers

srs5694 wrote:

GusGF wrote:I have noticed that when Windows has been hibernated the Windows boot loader does not even come up and I am taken straight into Windows. The only way to then get back into Linux is to shut down windows fully.

Given the way most users implement cross-OS file access, this is probably for the best. The problem is that hibernating a computer usually leaves disk access in a "used" state -- that is, the data structures on the disk are not necessarily internally consistent. This is OK if the computer is booted straight back into the original hibernated OS, since the missing information is originally held in memory, then stored on disk for hibernation, and then restored. Thus, after hibernating and returning from hibernation, the OS can still manage the disk and shut it down correctly. If, on the other hand, you reboot into another OS, and if you then attempt to access any filesystems that the first OS had open, the disk will look as if the computer had crashed. Depending on the filesystems and OSes involved and the specific details of what files were being accessed, etc., this could result in an inability to access the disk, in a successful disk "repair" being performed, or even in damage to the filesystem. When the first OS is rebooted, it may end up being confused about the state of the disk, so there's further risk of damage at that point.

Of course, all of this is an issue only if you mount shared filesystems across your OSes. Most Linux users do this on dual-boot configurations, though, so chances are this isn't really an "out." OTOH, the last time I checked, Linux's NTFS drivers tended to refuse to mount an NTFS volume that wasn't properly unmounted, so the risk of damage to an NTFS volume is likely to be fairly low. Still, I prefer to play it safe when it comes to cross-OS filesystem access.

So in sum, if you hibernate, you really should plan on booting back to the original OS the next time you power on. If your boot loader enforces such an action, then that's a good thing, since it makes it less likely that you'll end up trashing your disk through an accidental boot into the wrong OS.

I now have a system in which my dual boot LM/Win7 can hibernate either way or BOTH! and boot up either way...hurrah!

My problem was the MS boot manager was in the MBR and lonely old GRUB was cast out to the boot partition. MS boot manager controlled the booting process in so far as if it knew MS had previously hibernated it would ignore all other OSs installed and go straight back into Windows.

I started off using Boot Repair usually distributed with Ubuntu and actually ended up creating a Live Mint 14 USB to which I added Boot Repair. I had great hopes and installed GRUB using Boot Repair to the MBR from the Live USB. Now after a certain sequence of events which I'm not blaming on Boot Repair but more to my poor memory i.e. not sure what I did but all I know was I had got to a point where nothing was booting Windows or LM13 and I was getting error ....

At this point my priority became rescuing MSWin7 since this is where I had most to lose. I tried Boot Repair many times, Win7 recovery tools, all manner of MS console commands until I came across this little gem...

Now I had my Win7 installation back booting fine with no data loss I decided to install and move up to Linux Mint 14 since I now had it on a Live USB, to hell with it I thought, so I deleted all existing linux partitions from within Win7. Rebooted from the LM14 live usb resized the Win7 partiton sda1 (increased), moved the contents of the ntfs partition sda3 to sda2 and deleted sda3 so MSWin7 was now in the first two partitions. (I guess I just like to be organised)

I then set about installing LM14 but during the installation process it would not recognise my MSWin7 installation no matter what I did, ARRGHHHH!! So I manually created the necessary partitions (no need for boot) and installed LM14 to them making sure this time I installed GRUB to the sda1 partition. I then prayed, rebooted and to my relief GRUB came up offering me a choice of installed OSs, allowing me to hiberate to my hearts content.

I have set up a separate NTFS data partition which at some point will probably be shared between LM and W7. But for now simply having the convenience of being able to save the OS's state for the next boot is a blessing.

Sorry if this reads like a garbled mess from a novice (...and lets face it, it is) if it helps just one person it will have been worth it.