LinuxQuestions.org
Help answer threads with 0 replies.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 11-14-2009, 12:48 AM   #1
BlueSkull
Member
 
Registered: Sep 2009
Posts: 73

Rep: Reputation: 17
Question Problem in Grub Boot Loader in ubuntu 9.10


Hi..

I'm using Ubuntu 9.10 and Its working fine but yesterday I installed some updates from update manager and when I restart my Laptop It did not load the GRUB ( It show Grub... but without showing Booting option ubuntu 9.10 or recovery mode ........ it just got boot up and show the gnome login screen).

There is no menu.lst file in /boot/grub/
can this be a problem.

Please Help.

Actually its working fine but I have not changed my root password after installation
and I don't know the default password of root in ubuntu 9.10.
The only way I know to change it was to go to recovery mode and then droping in root shell nad changing it by passwd command.
Now grub is not loading so I'm not able to go in recovery Mode.

Please Help How can I make my Grub load and Is there any other method to change my root passwd if I dont know the old one.


Thanks

Aduait
 
Old 11-14-2009, 02:28 AM   #2
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Quote:
Originally Posted by BlueSkull View Post
Hi..

I'm using Ubuntu 9.10 and Its working fine but yesterday I installed some updates from update manager and when I restart my Laptop It did not load the GRUB ( It show Grub... but without showing Booting option ubuntu 9.10 or recovery mode ........ it just got boot up and show the gnome login screen).

There is no menu.lst file in /boot/grub/
can this be a problem.

Please Help.

Actually its working fine but I have not changed my root password after installation
and I don't know the default password of root in ubuntu 9.10.
The only way I know to change it was to go to recovery mode and then droping in root shell nad changing it by passwd command.
Now grub is not loading so I'm not able to go in recovery Mode.

Please Help How can I make my Grub load and Is there any other method to change my root passwd if I dont know the old one.


Thanks

Aduait
The menu.lst in Ubuntu 9.10 is called boot.cfg
To become root in UBUNTU 9.10 if that is what you mean use command sudo su at the same time and use you're own password.
If you can not find the error in boot.cfg post it , and we try to help you

Last edited by ronlau9; 11-14-2009 at 02:30 AM.
 
Old 11-14-2009, 02:51 AM   #3
BlueSkull
Member
 
Registered: Sep 2009
Posts: 73

Original Poster
Rep: Reputation: 17
Thanks
But where this boot.cfg file is located in file system.
Its not there In /boot/grub directry.
Only two files named boot, boot.img and boot.mod.

I'm not able to find boot.cfg from search for files in file System.
 
Old 11-14-2009, 03:29 AM   #4
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Quote:
Originally Posted by BlueSkull View Post
Thanks
But where this boot.cfg file is located in file system.
Its not there In /boot/grub directry.
Only two files named boot, boot.img and boot.mod.

I'm not able to find boot.cfg from search for files in file System.
Try cd /boot/grub/
ls
Is it a typo that you stated /boot/grub
 
Old 11-14-2009, 03:40 AM   #5
BlueSkull
Member
 
Registered: Sep 2009
Posts: 73

Original Poster
Rep: Reputation: 17
No Its not there.

Code:
 aduait@BlueSkull:~$ cd /boot/grub/
aduait@BlueSkull:/boot/grub$ ls -a
.                  echo.mod       lsmmap.mod      read.mod
..                 efiemu32.o     ls.mod          reboot.mod
915resolution.mod  efiemu64.o     lspci.mod       reiserfs.mod
acpi.mod           efiemu.mod     lvm.mod         scsi.mod
affs.mod           elf.mod        mdraid.mod      search.mod
afs_be.mod         ext2.mod       memdisk.mod     serial.mod
afs.mod            extcmd.mod     memrw.mod       setjmp.mod
aout.mod           fat.mod        minicmd.mod     sfs.mod
ata.mod            font.mod       minix.mod       sh.mod
ata_pthru.mod      fs_file.mod    mmap.mod        sleep.mod
at_keyboard.mod    fshelp.mod     moddep.lst      tar.mod
befs_be.mod        fs.lst         msdospart.mod   terminfo.mod
befs.mod           fs_uuid.mod    multiboot.mod   test.mod
biosdisk.mod       gfxterm.mod    normal.mod      tga.mod
bitmap.mod         gptsync.mod    ntfscomp.mod    true.mod
blocklist.mod      grub.cfg       ntfs.mod        udf.mod
boot.img           grubenv        ohci.mod        ufs1.mod
boot.mod           gzio.mod       part_acorn.mod  ufs2.mod
bsd.mod            halt.mod       part_amiga.mod  uhci.mod
bufio.mod          handler.lst    part_apple.mod  unicode.pf2
cat.mod            handler.mod    part_gpt.mod    usb_keyboard.mod
cdboot.img         hdparm.mod     partmap.lst     usb.mod
chain.mod          hello.mod      part_msdos.mod  usbms.mod
cmp.mod            help.mod       part_sun.mod    usbtest.mod
command.lst        hexdump.mod    parttool.lst    vbeinfo.mod
configfile.mod     hfs.mod        parttool.mod    vbe.mod
core.img           hfsplus.mod    password.mod    vbetest.mod
cpio.mod           iso9660.mod    pci.mod         vga.mod
cpuid.mod          jfs.mod        play.mod        vga_text.mod
crc.mod            jpeg.mod       png.mod         video_fb.mod
datehook.mod       kernel.img     probe.mod       video.mod
date.mod           keystatus.mod  pxeboot.img     videotest.mod
datetime.mod       linux16.mod    pxecmd.mod      xfs.mod
device.map         linux.mod      pxe.mod         xnu.mod
diskboot.img       lnxboot.img    raid5rec.mod    xnu_uuid.mod
dm_nv.mod          loadenv.mod    raid6rec.mod    zfsinfo.mod
drivemap.mod       loopback.mod   raid.mod        zfs.mod
aduait@BlueSkull:/boot/grub$
 
Old 11-14-2009, 04:11 AM   #6
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Sorry I made a mistake it is grub.cfg

Last edited by ronlau9; 11-14-2009 at 04:12 AM.
 
Old 11-14-2009, 05:12 AM   #7
BlueSkull
Member
 
Registered: Sep 2009
Posts: 73

Original Poster
Rep: Reputation: 17
Its Mine grub.cfg file
Code:
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s /boot/grub/grubenv ]; then
  have_grubenv=true
  load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
  saved_entry=${prev_saved_entry}
  save_env saved_entry
  prev_saved_entry=
  save_env prev_saved_entry
fi
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
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/white
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Ubuntu, Linux 2.6.31-15-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-15-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro   quiet splash
	initrd	/boot/initrd.img-2.6.31-15-generic
}
menuentry "Ubuntu, Linux 2.6.31-15-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-15-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro single 
	initrd	/boot/initrd.img-2.6.31-15-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro   quiet splash
	initrd	/boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro single 
	initrd	/boot/initrd.img-2.6.31-14-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
	linux16	/boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
	linux16	/boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
if [ ${timeout} != -1 ]; then
  if keystatus; then
    if keystatus --shift; then
      set timeout=-1
    else
      set timeout=0
    fi
  else
    if sleep --interruptible 3 ; then
      set timeout=0
    fi
  fi
fi
### 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 ###
I dont know much about it.
Just tell me the changes
or corrections to be made in it so that grub loads with booting options at the startup.

Thanks
 
Old 11-14-2009, 05:50 AM   #8
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Quote:
Originally Posted by BlueSkull View Post
Its Mine grub.cfg file
Code:
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#

### BEGIN /etc/grub.d/00_header ###
if [ -s /boot/grub/grubenv ]; then
  have_grubenv=true
  load_env
fi
set default="0"
if [ ${prev_saved_entry} ]; then
  saved_entry=${prev_saved_entry}
  save_env saved_entry
  prev_saved_entry=
  save_env prev_saved_entry
fi
insmod ext2
set root=(hd0,1)
search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
if loadfont /usr/share/grub/unicode.pf2 ; then
  set gfxmode=640x480
  insmod gfxterm
  insmod vbe
  if terminal_output gfxterm ; then true ; else
    # For backward compatibility with versions of terminal.mod that don't
    # understand terminal_output
    terminal gfxterm
  fi
fi
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/white
### END /etc/grub.d/05_debian_theme ###

### BEGIN /etc/grub.d/10_linux ###
menuentry "Ubuntu, Linux 2.6.31-15-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-15-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro   quiet splash
	initrd	/boot/initrd.img-2.6.31-15-generic
}
menuentry "Ubuntu, Linux 2.6.31-15-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-15-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro single 
	initrd	/boot/initrd.img-2.6.31-15-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	set quiet=1
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro   quiet splash
	initrd	/boot/initrd.img-2.6.31-14-generic
}
menuentry "Ubuntu, Linux 2.6.31-14-generic (recovery mode)" {
        recordfail=1
        if [ -n ${have_grubenv} ]; then save_env recordfail; fi
	insmod ext2
	set root=(hd0,1)
	search --no-floppy --fs-uuid --set ff2962f7-8e70-4397-8453-238f3ef31f50
	linux	/boot/vmlinuz-2.6.31-14-generic root=UUID=ff2962f7-8e70-4397-8453-238f3ef31f50 ro single 
	initrd	/boot/initrd.img-2.6.31-14-generic
}
### END /etc/grub.d/10_linux ###

### BEGIN /etc/grub.d/20_memtest86+ ###
menuentry "Memory test (memtest86+)" {
	linux16	/boot/memtest86+.bin
}
menuentry "Memory test (memtest86+, serial console 115200)" {
	linux16	/boot/memtest86+.bin console=ttyS0,115200n8
}
### END /etc/grub.d/20_memtest86+ ###

### BEGIN /etc/grub.d/30_os-prober ###
if [ ${timeout} != -1 ]; then
  if keystatus; then
    if keystatus --shift; then
      set timeout=-1
    else
      set timeout=0
    fi
  else
    if sleep --interruptible 3 ; then
      set timeout=0
    fi
  fi
fi
### 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 ###
I dont know much about it.
Just tell me the changes
or corrections to be made in it so that grub loads with booting options at the startup.

Thanks
There are two thinks I do not know what you have done.
When you upgrade iF I remember it well there was a question about if it should use the local GRUb installation ore something like that .
The correct answer to that guestion is yes
Second looking to you're grub.cfg UBUNTU is installed on partition two
of you're HD .
Because (hd0,1) means installed on SDA partition 2
GRUB start counting by 0
What is the contents of partition 1 ?
In other words is UBUNTU you're only OS ?
If not post the outcome of fdisk -l (L lowercase ti)
This to know the the partitioning of you're hd and the file types
If UBUNTU is installed on the first partition than it should be (hd0,0)
 
Old 11-14-2009, 05:59 AM   #9
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
You should read what it says at the beginning of grub.cfg
Code:
#
# DO NOT EDIT THIS FILE
#
# It is automatically generated by /usr/sbin/grub-mkconfig using templates
# from /etc/grub.d and settings from /etc/default/grub
#
It is there for a reason. Do a grub-install instead of changing the file manually.

Kind regards,

Eric
 
Old 11-14-2009, 06:14 AM   #10
BlueSkull
Member
 
Registered: Sep 2009
Posts: 73

Original Poster
Rep: Reputation: 17
I have only ubuntu OS and I have installed it in 1st partition.
It was used to show booting from hd(0,0) when grub was used to load.

The output of command fdisk -l is

Code:
Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xaa737648

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        5221    41935872   83  Linux
/dev/sda2            5222       30401   202258350    b  W95 FAT32
My 2nd partition is FAT32.
 
Old 11-14-2009, 07:03 AM   #11
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Quote:
Originally Posted by BlueSkull View Post
I have only ubuntu OS and I have installed it in 1st partition.
It was used to show booting from hd(0,0) when grub was used to load.

The output of command fdisk -l is

Code:
Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xaa737648

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *           1        5221    41935872   83  Linux
/dev/sda2            5222       30401   202258350    b  W95 FAT32
My 2nd partition is FAT32.
So to correct if it was my pc sudo su enter
password enter
nano /boot/grub/grub.cfg
And every were change (hd0,1) by (hd0,0)
ctrl O to save the changes be sure it write the changes

Last edited by ronlau9; 11-14-2009 at 07:05 AM.
 
Old 11-14-2009, 08:49 AM   #12
BlueSkull
Member
 
Registered: Sep 2009
Posts: 73

Original Poster
Rep: Reputation: 17
I made the changes
and restart my lap but grub boot options were not shown and ubuntu booted directly.
After entering my user name and password in login screen
System Hanged up.
mouse or keyboard none worked.
I have to shutdown lap by pressing shutdown key and then with live cd undo the changes.
Now its again same as before.
 
Old 11-14-2009, 09:13 AM   #13
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Than there is no other option than reinstalling UBUNTU , and when updating
beware of that question I stated before and be sure to give the correct
answer
 
Old 11-14-2009, 10:29 AM   #14
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
As stated before, do a
Code:
grub-install
You don't have to reinstall Ubuntu entirely just because the boot manager is failing. You went ahead and edited the grub.cfg manually although it's not to be edited. So now your in trouble.

Run the grub-install.

Kind regards,

Eric
 
Old 11-14-2009, 11:36 AM   #15
ronlau9
Senior Member
 
Registered: Dec 2007
Location: In front of my LINUX OR MAC BOX
Distribution: Mandriva 2009 X86_64 suse 11.3 X86_64 Centos X86_64 Debian X86_64 Linux MInt 86_64 OS X
Posts: 2,369

Rep: Reputation: Disabled
Quote:
Originally Posted by EricTRA View Post
As stated before, do a
Code:
grub-install
You went ahead and edited the grub.cfg manually although it's not to be edited. So now your in trouble.

Run the grub-install.

Kind regards,

Eric
Why not ?
I can assure you that I did it already a couple of times .
Just like everything it should be done properly
But maybe you will share me you're knowledge why I should not do so.
And why every time I have done so fare everything is going great

Last edited by ronlau9; 11-14-2009 at 11:37 AM.
 
  


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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Ubuntu without Grub boot loader???? ratman1 Linux - Newbie 6 10-18-2009 02:24 AM
How do I uninstall Ubuntu and Grub loader from a dual boot system? wired_retired Linux - Newbie 7 08-13-2008 05:59 PM
Ubuntu GRUB boot loader SickNick Ubuntu 10 04-06-2007 02:42 PM
Boot Loader (grub) will not work with Ubuntu ajd344 Linux - Newbie 6 08-21-2006 05:42 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 09:55 PM.

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