Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I boot with liveUSB. But how do i fix now my MBR, so that i can re-install Ubuntu? (after installing ubuntu i get mostly this blinking cursor and black screen)

root@ubuntu:~# fdisk -l

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000638ad

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1       59769   480092160   83  Linux
/dev/sda2           59769       60802     8291329    5  Extended
/dev/sda5           59769       60802     8291328   82  Linux swap / Solaris

Disk /dev/sdb: 2013 MB, 2013265920 bytes
58 heads, 58 sectors/track, 1168 cylinders
Units = cylinders of 3364 * 512 = 1722368 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x1965c912

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1   *           1        1169     1965056   83  Linux

root@ubuntu:~# fdisk /dev/sda

WARNING: DOS-compatible mode is deprecated. It's strongly recommended to
         switch off the mode (command 'c') and change display units to
         sectors (command 'u').

Command (m for help): p

Disk /dev/sda: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0x000638ad

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1               1       59769   480092160   83  Linux
/dev/sda2           59769       60802     8291329    5  Extended
/dev/sda5           59769       60802     8291328   82  Linux swap / Solaris

Command (m for help): 

enter image description here

share|improve this question
    
What does your partition table look like after you install Ubuntu? –  bbaja42 Oct 28 '11 at 21:21
    
@bbaja42: see above plz updated. –  YumYumYum Oct 28 '11 at 21:22
3  
Is sda1 marked as bootable? –  bbaja42 Oct 28 '11 at 21:25
    
@bbaja42: i do not know. This is the preview you see with my Live CD. When i install i assume its sda1 still? or MBR sits in sda? –  YumYumYum Oct 28 '11 at 21:28
1  
sda is your hard drive , while numbers represent the partitions on it. –  bbaja42 Oct 28 '11 at 21:36
show 2 more comments

2 Answers

up vote 2 down vote accepted

It looks like none of your partitions on /dev/sda have bootable flag set - compare the fdisk -l output with /dev/sdb - see the star in the Boot column next to /dev/sdb1? You need to set it on /dev/sda1

To set bootable flag, start fdisk with

fdisk /dev/sda

(from your LiveCD, as root). There, press "a" and then enter "1". then press "w" to write your changes to disk. Reboot. Enjoy.

share|improve this answer
    
Thanks thats what i was trying to do with LiveUSB. So that i can continue. I was experimenting to remove Ubuntu desktop. So i was using 1) Alternate install CD: releases.ubuntu.com/natty 2) help.ubuntu.com/community/Installation/MinimalCD one of those distro Grub2 failed and that caused MBR failure. –  YumYumYum Oct 28 '11 at 22:10
add comment

For the simplest solution, try installing Ubuntu by letting installer configure partitions.

Set 1 partition to be boot able and install either "/" on it or "/boot" on it.

share|improve this answer
    
That i did, and failed, thats the result we are trying to fix. (somehow the MBR of the installer failed). –  YumYumYum Oct 28 '11 at 21:41
    
Can the MBR details sit on SDA or SDA1? –  YumYumYum Oct 28 '11 at 21:42
1  
following link explains how create bootable partition after install help.ubuntu.com/community/CreateBootPartitionAfterInstall –  bbaja42 Oct 28 '11 at 21:43
    
Its very difficult how they explained. 1. I am doing with Ubuntu live CD a fresh installation, so that it breaks the MBR existing one 2. Then i will use my random Ubuntu again once the first one gets running. Is there any small or easy tools to simply break what ever MBR is? (like REDHAT old versions had some). –  YumYumYum Oct 28 '11 at 21:54
    
What do you mean by simply break what ever MBR ? –  bbaja42 Oct 28 '11 at 21:56
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.