Recover Ubuntu grub without LiveCD - Can't boot with Ubuntu LiveCD after install Windows

I installed Windows after installing Ubuntu. But Ubuntu is still intact in its partition.

I'm trying to run the Ubuntu LiveCD to recover grub, but the LiveCD no longer works. It stops the boot process and does not load completely.

I can not run Ubuntu in live mode to recover grub.

Is there any way to recover the grub/grub2 without the LiveCD?

Edit:

[Important] I've downloaded a new Ubuntu 10.10 ISO. I also did the MD5 check. It's all right. Then, I recorded this .iso and still can not load the LiveCD to the end.

-
1. Backup your data first if you can. 2. Have you tried a different Ubuntu/Linux boot CD/live CD? 3...etc. If you have a second drive that you can make primary, just attach your current drive to investigate and recover. You can re-jigger your partitions from windows if you have to, but I'd do that as a last resort. –  belacq Jan 26 '11 at 2:29

The easiest way would be to indeed create a new LiveCD or even a LiveUSB.

Failing that, you can configure the Windows bootloader to boot Linux. Then, you can use your installed Linux to re-install grub to the MBR. See https://help.ubuntu.com/community/RecoveringUbuntuAfterInstallingWindows (section 2) for information on how to perform this task.

-
In this section, all options require livecd. But I found another option that can run in Windows itself, called AutoSuperGrubDisk. Do you recommend? –  Paulocoghi Jan 26 '11 at 14:20

I could not recover the grub, but I found the problem.

In some machines, the Ubuntu 10.10 LiveCD has a bug. The problem is that the regular ISO still has the error, though a bug fix is available. But the MinimalCD is clean and works fine.

I did this process and managed to install Ubuntu Desktop 10.10 32bit smoothly. It is also valid for other versions.

The bug:

If you're using a regular ISO, and you can not continue the boot process, you can see the bug as follows:

When the boot process stops or freezes, you need to press "F6" and "Esc". Then you can see one or both of these messages:

"GLib-WARNING **: getpwuid_r(): failed due to unknown user id (0)"

or

"Kernel panic - not syncing: Attempted to kill init"

Finally, the solution:

To solve this problem, you can install Ubuntu from a MinimalCD (simply choose which version you want): https://help.ubuntu.com/community/Installation/MinimalCD

After booting the CD, I chose the standard install, and near the end, I chose the version I wanted. In this particular case, Ubuntu Desktop 32bit 10.10.

For more details: http://ubuntuforums.org/showpost.php?p=10169169&postcount=176

-

Sounds like a hardware problem or bad burn. But you should be able to make Windows boot Linux by using 'dd' for Windows (http://www.chrysocome.net/dd). Boot Windows; install dd, run a command prompt and ...

c:
cd \
dd if=\\?\Device\Harddisk0\Partition1 of=ubuntu-linux.bin bs=512 count=1


where \?\Device\Harddisk0\Partition1 is your Linux boot partition. Then...

attrib -r boot.ini


Add a new line to the INI file:

c:\ubuntu-linux.bin="Ubuntu Linux"


Save. Exit notepad. And then ...

attrib +r boot.ini


Reboot.

tsshutdown 0 /delay:0 /reboot


The device name can be discovered with dd --list.

-