Bootloader Erased After Suspend to RAM
This thread is related to this thread. I can't figure out why Mandriva, Mageia, Mint and Fedora destroyed the bootloader after suspending to RAM. Each distro was tested after installed on my netbook via suspend to RAM menu on KDE.
My netbook is an ASUS 1215B with AMD E350 APU which the spec you can see here. Everything works just fine after wake up from sleeping mode except that after rebooting I always found that the bootlader was erased. I got "_" blinking on the upper-left corner of the screen. I have to reinstall GRUB via live USB to fix this. |
It is (extraordinarily) unlikely the Linuxen are doing this.
Check your BIOS for a "Virus Protection" option that may be getting in the way. Dell laptops have some "handy" Windoze tools that protect you and have this effect - only when run unannounced from Windoze tho'. |
Linuxen? I've never heard anything about that. Can you explain me what is Linuxen?
Okay, I've searched through my BIOS settings but there is not something like "Virus Protection" exists. |
Could you verify if anything actually gets changed on the MBR and/or /boot partition while suspending? Do a binary compare before and after suspend.
|
Quote:
|
What exactly did you mean that GRUB disappears / gets erased? Did you mean that the screen becomes black and doesn't show the bootloader screen on reboot? That does not necessarily mean your entire boot loader is gone. It's still strange that you get a black screen. And this only happens after you suspend, not poweroff/reboot normally without suspending?
What is the partition layout for your setup? In a terminal type "fdisk -l" and print the output here. Do you have a swap partition? What is the amount of your RAM? You can calculate a hash for any file (or partition while logged in as root - in linux a partition is a file!). Assuming your /boot files are on a separate partition you can do "shasum /dev/sda1" inside a root terminal. This should print something like: a57ab8c4f4c7800b3ab649eee3200419794a2f13 /dev/sda1 Do it before and after suspending. Compare both numbers - they must be identical. If not then something has been modified for sure! |
Quote:
This is fdisk -l output. Code:
Disk /dev/sda: 320.1 GB, 320072933376 bytes Code:
total used free shared buffers cached Code:
f322f3215a6f08f18a830d737d1f78e5dfd856b3 /dev/sda5 Code:
d95fbd674a44acd0126d01cf82fc42bff4efb605 /dev/sda5 |
The root hash isn't going to do here because it hashes the entire root partition. The files on root partition are bound to change over time - take the /var/log folder for example where the logs can change every minute. I see you're dual-booting linux and windows.
If your /boot is not on another partition then you can do this instead: tar -cf - /boot | shasum You might also want to check the first 2047 sectors (including MBR) that reside on your HDD before the 1st partition: dd if=/dev/sda of=/root/sectors.tmp bs=512 count=2047 shasum /root/sectors.tmp Exercise caution when using the "dd" as the root account because you can easily erase your MBR, if you're not careful! ~dis |
Some new bios's do an odd deal where you can only return to the saved OS if you hibernate. It may be that some issue is going on there.
It also might even be some oddity of overlapping partitions. Swap has to be (I forget how much) more than ram but use some factor more. |
Quote:
I've tried your command and nothing was changed after suspending to RAM. |
Strange. And you say this happens after rebooting, but only if you suspend to ram before rebooting? Does it happen if you reboot without suspending to ram? The only other thing I can imagine is that something changes when you poweroff/reboot. Could you repeat the process to get the black screen at boot again? Then when the "grub disappears", boot to a rescue system and do the hashing from there. Hashing the first 2047 sectors should be the same as above, but you will need to mount the main partition to hash the /boot folder. I hope you still have the old HASH numbers somewhere!
cd /mnt mkdir disk mount /dev/sda5 /mnt/disk tar -cf - /mnt/disk/boot | shasum umount /mnt/disk If this doesn't show any changes then there must be a hardware/firmware problem somewhere. Likely with BIOS. |
Quote:
|
Yeah, it's not "being erased". I've tried to suspend to RAM and then reinstalled GRUB immediately, rebooted and still got "_" blinking on the top-left corner.
Even more surprising is that after I booted to Debian Live, Mageia Installer without doing anything and then rebooting, I could get into my installed Mageia in sda5. I haven't done that shasum thing. edit: I have tried it and the hash wasn't changed. |
Does the black screen only happen when you suspend? Does it happen, if you install Mageia and reboot a couple of times without suspending to ram? I see that the boot loader remains unchanged, so there's little point in reinstalling grub2.
|
This blank screen never occurred before the day I started to suspend my system.
|
All times are GMT -5. The time now is 09:27 PM. |