LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu
User Name
Password
Ubuntu This forum is for the discussion of Ubuntu Linux.

Notices


Reply
  Search this Thread
Old 07-09-2011, 12:04 AM   #16
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35

How do I purge it...?

d-1
 
Old 07-09-2011, 12:40 AM   #17
andrewthomas
Senior Member
 
Registered: May 2010
Location: Chicago Metro
Distribution: Arch, Gentoo, Slackware
Posts: 1,690

Rep: Reputation: 312Reputation: 312Reputation: 312Reputation: 312
Quote:
Originally Posted by dolphans1 View Post
How do I purge it...?

d-1
Follow this link:
http://ubuntuforums.org/showthread.p...ighlight=grub2
Quote:
Originally Posted by andrewthomas View Post
You probably will have to purge and reinstall grub2, but first could you do as widget suggested EXCEPT run the bootinfoscript from the Ubuntu LiveCD.

Boot the LiveCD and go to http://bootinfoscript.sourceforge.net and post the results between tags in your reply.

What you probably will have to do is follow this:




http://ubuntuforums.org/showthread.p...ighlight=grub2
 
Old 07-09-2011, 12:48 AM   #18
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
Thanks Andrew, I went there previously and followed , and I felt its just way to complicated to go through and its really too way drawn out.

I know that I can go through a whole new reinstall of Ubuntu and resolve this issue, but I'm being stubborn and I'm holding out for a possibly quick fix.

d-1


Quote:
Originally Posted by andrewthomas View Post
 
Old 07-09-2011, 12:55 AM   #19
andrewthomas
Senior Member
 
Registered: May 2010
Location: Chicago Metro
Distribution: Arch, Gentoo, Slackware
Posts: 1,690

Rep: Reputation: 312Reputation: 312Reputation: 312Reputation: 312
Don't reinstall. It is very simple.

Boot into your Ubuntu.

Open a terminal.
Code:
sudo apt-get update
Code:
sudo apt-get purge grub grub-pc grub-common
Quote:
Reinstall the grub packages. Here is what will happen:
You will be given the opportunity to add extra kernel options to the kernel line. If you don't know, you probably don't need them ; TAB to highlight "<OK>" and press ENTER.
Read the installation notes. TAB to "<OK>" to continue.
When presented with the device option, use the UP/DN keys to select the correct drive (sdX).
Make sure the installation drive[*] /dev/sdX has an asterisk next to it ( example:[*] /dev/sda ). If it doesn't, highlight it and press the SPACE bar to select it.
Do not select a partition ( example: [ ] /dev/sda5 , etc).
TAB to "<OK>" and press ENTER. When it has finishing the installation, you should have Grub 2 installed.
Which, in your case would be /dev/sda
Code:
sudo apt-get install grub-common grub-pc
Code:
sudo update-grub
 
Old 07-09-2011, 01:26 AM   #20
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
Okay, I followed all that is this is where I am at -

Creating config file /etc/default/grub with new version
Setting up grub-gfxpayload-lists (0.2) ...
stan@stan-GeForce6100PM-M2:~$ sudo update-grub
Generating grub.cfg ...
cat: /boot/grub/video.lst: No such file or directory
Found linux image: /boot/vmlinuz-2.6.38-8-generic
Found initrd image: /boot/initrd.img-2.6.38-8-generic
Found memtest86+ image: /boot/memtest86+.bin
Found Windows 7 (loader) on /dev/sda1
done
 
Old 07-09-2011, 01:44 AM   #21
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
Ok Andrew, I followed you last post and purged it and now I cant boot at all, the only way I can boot is using my live ubuntu cd or using Super Grub and now it only sees windows and allows me to boot there.

What command must I do to restore boot loader, and I am on live ubuntu cd...?

Thanks,

d-1
 
Old 07-09-2011, 01:51 AM   #22
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
results:

ubuntu@ubuntu:~$ sudo bash ~/Downloads/boot_info_script.sh

boot_info_script version: 0.60 [17 May 2011]


"gawk" could not be found, using "busybox awk" instead.
This may lead to unreliable results.

Identifying MBRs...
Computing Partition Table of /dev/sda...
Searching sda1 for information...
Searching sda2 for information...
Searching sda3 for information...
Searching sda5 for information...
Searching sda6 for information...
Searching sda7 for information...
Searching sda8 for information...
Searching sda9 for information...

Finished. The results are in the file "RESULTS.txt"
located in "/home/ubuntu/Downloads/".
 
Old 07-09-2011, 01:53 AM   #23
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
and more results:

Boot Info Script 0.60 from 17 May 2011


============================= Boot Info Summary: ===============================

=> Grub2 (v1.99) is installed in the MBR of /dev/sda and looks at sector 1 of
the same hard drive for core.img. core.img is at this location and looks
for (,msdos8)/boot/grub on this drive.

sda1: __________________________________________________________________________

File system: ntfs
Boot sector type: Windows Vista/7
Boot sector info: No errors found in the Boot Parameter Block.
Operating System:
Boot files: /bootmgr /Boot/BCD

sda2: __________________________________________________________________________

File system: ntfs
Boot sector type: Windows Vista/7
Boot sector info: No errors found in the Boot Parameter Block.
Operating System: Windows 7
Boot files: /Windows/System32/winload.exe

sda3: __________________________________________________________________________

File system: Extended Partition
Boot sector type: -
Boot sector info:

sda5: __________________________________________________________________________

File system: swap
Boot sector type: -
Boot sector info:

sda6: __________________________________________________________________________

File system: ext3
Boot sector type: -
Boot sector info:
Operating System:
Boot files:

sda7: __________________________________________________________________________

File system: swap
Boot sector type: -
Boot sector info:

sda8: __________________________________________________________________________

File system: ext4
Boot sector type: -
Boot sector info:
Operating System: Ubuntu 11.04
Boot files: /boot/grub/grub.cfg /etc/fstab

sda9: __________________________________________________________________________

File system: swap
Boot sector type: -
Boot sector info:

============================ Drive/Partition Info: =============================

Drive: sda _____________________________________________________________________

Disk /dev/sda: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes

Partition Boot Start Sector End Sector # of Sectors Id System

/dev/sda1 * 2,048 206,847 204,800 7 NTFS / exFAT / HPFS
/dev/sda2 206,848 1,024,591,679 1,024,384,832 7 NTFS / exFAT / HPFS
/dev/sda3 1,024,591,870 1,953,519,119 928,927,250 5 Extended
/dev/sda5 1,049,781,663 1,057,961,519 8,179,857 82 Linux swap / Solaris
/dev/sda6 1,057,961,583 1,953,519,119 895,557,537 83 Linux
/dev/sda7 1,043,757,056 1,049,767,935 6,010,880 82 Linux swap / Solaris
/dev/sda8 1,024,591,872 1,037,729,791 13,137,920 83 Linux
/dev/sda9 1,037,731,840 1,043,742,719 6,010,880 82 Linux swap / Solaris


"blkid" output: ________________________________________________________________

Device UUID TYPE LABEL

/dev/loop0 squashfs
/dev/sda1 286803116802DE06 ntfs System Reserved
/dev/sda2 9E60055060053117 ntfs
/dev/sda5 886238a4-5192-4156-a509-e82d88d07dd3 swap
/dev/sda6 b8a3ab00-1f93-4f5a-9f99-f6697aa48ed3 ext3
/dev/sda7 d62e06de-8148-4aad-a176-497db9829f79 swap
/dev/sda8 85032c9e-8499-480e-9be3-843590f12180 ext4
/dev/sda9 f72a940c-bf59-4ce5-9111-ab0b61c6d68e swap

================================ Mount points: =================================

Device Mount_Point Type Options

/dev/loop0 /rofs squashfs (ro,noatime)
/dev/sr0 /cdrom iso9660 (ro,noatime)


=========================== sda8/boot/grub/grub.cfg: ===========================

--------------------------------------------------------------------------------
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s $prefix/grubenv ]; then
set have_grubenv=true
load_env
fi
set default="0"
if [ "${prev_saved_entry}" ]; then
set saved_entry="${prev_saved_entry}"
save_env saved_entry
set prev_saved_entry=
save_env prev_saved_entry
set boot_once=true
fi

function savedefault {
if [ -z "${boot_once}" ]; then
saved_entry="${chosen}"
save_env saved_entry
fi
}

function recordfail {
set recordfail=1
if [ -n "${have_grubenv}" ]; then if [ -z "${boot_once}" ]; then save_env recordfail; fi; fi
}

function load_video {
true
}

insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos8)'
search --no-floppy --fs-uuid --set=root 85032c9e-8499-480e-9be3-843590f12180
if loadfont /usr/share/grub/unicode.pf2 ; then
set gfxmode=auto
load_video
insmod gfxterm
fi
terminal_output gfxterm
if [ "${recordfail}" = 1 ]; then
set timeout=-1
else
set timeout=10
fi
### END /etc/grub.d/00_header ###

### BEGIN /etc/grub.d/05_debian_theme ###
set menu_color_normal=white/black
set menu_color_highlight=black/light-gray
if background_color 44,0,30; then
clear
fi
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
if [ ${recordfail} != 1 ]; then
if [ -e ${prefix}/gfxblacklist.txt ]; then
if hwmatch ${prefix}/gfxblacklist.txt 3; then
if [ ${match} = 0 ]; then
set linux_gfx_mode=keep
else
set linux_gfx_mode=text
fi
else
set linux_gfx_mode=text
fi
else
set linux_gfx_mode=keep
fi
else
set linux_gfx_mode=text
fi
export linux_gfx_mode
if [ "$linux_gfx_mode" != "text" ]; then load_video; fi
menuentry 'Ubuntu, with Linux 2.6.38-8-generic' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos8)'
search --no-floppy --fs-uuid --set=root 85032c9e-8499-480e-9be3-843590f12180
linux /boot/vmlinuz-2.6.38-8-generic root=UUID=85032c9e-8499-480e-9be3-843590f12180 ro quiet splash vt.handoff=7
initrd /boot/initrd.img-2.6.38-8-generic
}
menuentry 'Ubuntu, with Linux 2.6.38-8-generic (recovery mode)' --class ubuntu --class gnu-linux --class gnu --class os {
recordfail
set gfxpayload=$linux_gfx_mode
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos8)'
search --no-floppy --fs-uuid --set=root 85032c9e-8499-480e-9be3-843590f12180
echo 'Loading Linux 2.6.38-8-generic ...'
linux /boot/vmlinuz-2.6.38-8-generic root=UUID=85032c9e-8499-480e-9be3-843590f12180 ro single
echo 'Loading initial ramdisk ...'
initrd /boot/initrd.img-2.6.38-8-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_linux_xen ###
### END /etc/grub.d/20_linux_xen ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos8)'
search --no-floppy --fs-uuid --set=root 85032c9e-8499-480e-9be3-843590f12180
linux16 /boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
insmod part_msdos
insmod ext2
set root='(/dev/sda,msdos8)'
search --no-floppy --fs-uuid --set=root 85032c9e-8499-480e-9be3-843590f12180
linux16 /boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
menuentry "Windows 7 (loader) (on /dev/sda1)" --class windows --class os {
insmod part_msdos
insmod ntfs
set root='(/dev/sda,msdos1)'
search --no-floppy --fs-uuid --set=root 286803116802DE06
chainloader +1
}
### END /etc/grub.d/30_os-prober ###

### BEGIN /etc/grub.d/40_custom ###
# This file provides an easy way to add custom menu entries. Simply type the
# menu entries you want to add after this comment. Be careful not to change
# the 'exec tail' line above.
### END /etc/grub.d/40_custom ###

### BEGIN /etc/grub.d/41_custom ###
if [ -f $prefix/custom.cfg ]; then
source $prefix/custom.cfg;
fi
### END /etc/grub.d/41_custom ###
--------------------------------------------------------------------------------

=============================== sda8/etc/fstab: ================================

--------------------------------------------------------------------------------
# /etc/fstab: static file system information.
#
# Use 'blkid -o value -s UUID' to print the universally unique identifier
# for a device; this may be used with UUID= as a more robust way to name
# devices that works even if disks are added and removed. See fstab(5).
#
# <file system> <mount point> <type> <options> <dump> <pass>
proc /proc proc nodev,noexec,nosuid 0 0
/dev/sda8 / ext4 errors=remount-ro 0 1
# swap was on /dev/sda9 during installation
UUID=f72a940c-bf59-4ce5-9111-ab0b61c6d68e none swap sw 0 0
/dev/fd0 /media/floppy0 auto rw,user,noauto,exec,utf8 0 0
--------------------------------------------------------------------------------

=================== sda8: Location of files loaded by Grub: ====================

GiB - GB File Fragment(s)

492.691726685 = 529.023713280 boot/grub/grub.cfg 1
493.122852325 = 529.486630912 boot/initrd.img-2.6.38-8-generic 2
492.926403046 = 529.275695104 boot/vmlinuz-2.6.38-8-generic 1
493.122852325 = 529.486630912 initrd.img 2
492.926403046 = 529.275695104 vmlinuz 1

========= Devices which don't seem to have a corresponding hard drive: =========

sdb

=============================== StdErr Messages: ===============================

unlzma: Decoder error
 
Old 07-09-2011, 01:55 AM   #24
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
pure disaster....

one dead end after the other....

I could have done 5 reinstalls....

d-1
 
Old 07-09-2011, 02:35 AM   #25
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
I finally caved into pressure and did a completely new reinstall of Ubuntu, it did see my windows OS during the install process and I went through the motions of installing Ubuntu 11.04 all over again, and I still get that same black screen and no ability to scroll or boot.

I am totally clueless as to why this issue still persists...

All I can say is Ubuntu 11.04 sucks, big time....!!!!

d-1

Last edited by dolphans1; 07-09-2011 at 02:36 AM.
 
Old 07-09-2011, 08:37 AM   #26
widget
Senior Member
 
Registered: Oct 2008
Location: S.E. Montana
Distribution: Debian Testing, Stable, Sid and Manjaro, Mageia 3, LMDE
Posts: 2,628

Rep: Reputation: 497Reputation: 497Reputation: 497Reputation: 497Reputation: 497
Well, on the install that you had first, you some how had mixed grub (grub-legacy) and grub-pc (grub2). This was possible by accident in Ubuntu 9.10 and (I believe)10.04 but not since then. That had something to do with one of your unlisted tweeks.

Also on that install you needed to simply run the command to install grub on the mbr before rebooting. The grub mentioned in your second boot info script is the grub you purged, no wonder it can't find the files.

That problem was simple to correct from a live cd by chrooting in and running the command.

While I agree that 11.04 sucks I do not think this is the basic problem. One of the interesting things on your boot info script is the existence of 3 swap partitions, 1 ext3 partition and 1 ext4 partition. I seriously doubt the installer, in spite of Ubuntus "improvements" to it ever did that on its own.

Reinstalling may satisfy that urge of all MS users to reinstall but it will never teach you a thing. I hope that when you did the reinstall you cleaned up that partition table.
 
Old 07-09-2011, 08:37 AM   #27
andrewthomas
Senior Member
 
Registered: May 2010
Location: Chicago Metro
Distribution: Arch, Gentoo, Slackware
Posts: 1,690

Rep: Reputation: 312Reputation: 312Reputation: 312Reputation: 312
Quote:
Originally Posted by dolphans1 View Post
Ok Andrew, I followed you last post and purged it and now I cant boot at all, the only way I can boot is using my live ubuntu cd or using Super Grub and now it only sees windows and allows me to boot there.

What command must I do to restore boot loader, and I am on live ubuntu cd...?

Thanks,

d-1
https://help.ubuntu.com/community/Gr...stalling GRUB2

Last edited by andrewthomas; 07-09-2011 at 08:38 AM. Reason: fixed link
 
Old 07-09-2011, 09:36 AM   #28
Arcane
Member
 
Registered: May 2006
Location: Latvia, Europe
Distribution: random
Posts: 310

Rep: Reputation: 312Reputation: 312Reputation: 312Reputation: 312
Interesting..if it's version fault try previous 10.10 .iso(under text is links) and follow this grub reinstall guide which is way more simple and easy than above cocktail.
 
Old 07-09-2011, 10:01 AM   #29
dolphans1
Senior Member
 
Registered: Jun 2003
Location: LoneStar
Distribution: Mandriva & Ubuntu
Posts: 1,041

Original Poster
Rep: Reputation: 35
Here's what I had to do:

I had to run "gksu nautilus" or "gedit /etc/defaults/grub"

The VBE resolution was messed up , I wasn't getting any resolution when loading up and that is why my screen would go black during boot stage, so I had to change the VBE resolution to 640X480 manually then run "update-grub".

Now when I boot, I can see the boot-loader for ubuntu and windows7 like I should. and scroll to it.

Your right Andrew, I did not have to do a reinstall, I just grew impatient.

I am not sure how the VBE resolution got messed up and why it wouldn't correct itself during new reinstall.

d-1

Last edited by dolphans1; 07-09-2011 at 10:09 AM.
 
Old 07-09-2011, 10:12 AM   #30
andrewthomas
Senior Member
 
Registered: May 2010
Location: Chicago Metro
Distribution: Arch, Gentoo, Slackware
Posts: 1,690

Rep: Reputation: 312Reputation: 312Reputation: 312Reputation: 312
640x480 is the default, so I don't know why it was wrong.

Maybe you had edited the /etc/default/grub file at some point?
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how to restore the grub loader in ubuntu 10.4 janakiramulu Ubuntu 3 02-06-2011 10:05 AM
How to restore boot loader on Mandriva 09 dual boot ... pruned parts 1 dolphans1 Mandriva 66 02-24-2009 10:04 AM
How to restore boot loader on Mandriva 09 dual boot ... pruned parts 2 Javad_Ed Mandriva 8 01-06-2009 04:11 PM
How to restore boot loader on Mandriva 09 dual boot with Suse 11.0 ? dolphans1 Mandriva 10 01-06-2009 03:43 PM
Cannot restore boot loader lyllo Fedora 4 01-29-2005 12:56 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Ubuntu

All times are GMT -5. The time now is 12:26 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration