Jump to content

No working Ubuntu entry (GRUB problem) [solved]


Recommended Posts

After using using a dual boot of Mandriva Free 2008 and Windows XP for some time I decided to try some other distribution. I chose Ubuntu 8.04.1. I made a new partition on which I would install my third OS.

 

So I installed Ubuntu and rebooted my computer. I then noticed that my graphic GRUB had not only been replaced by a text GRUB but with a text GRUB with the Ubuntu entry as the primary one. I had had (and wished to still have) a graphical GRUB that would boot Mandriva automatically after a few seconds of waiting.

 

I thought I could fix this by booting Mandriva and reinstalling my GRUB. This made the Ubuntu entry disappear completely.

 

I used the Mandriva Control Center's bootloader options and made a new boot entry. I didn't know what I'm supposed to select for that entry's "root", but I think it's /dev/hda8. That's the partition on which I installed Ubuntu.

 

I could now boot Ubuntu, but the mouse cursor didn't move one bit. I'd like to use my mouse so I wasn't truly satisfied yet.

 

When creating a new boot entry I'm supposed to select an "image". I get these to choose from:

/boot/vmlinuz-2.6.22.18-desktop-1mdv,

/boot/vmlinuz-2.6.22.9-desktop-1mdv,

/boot/vmlinuz-2.6.22.12-desktop-1mdv

/boot/vmlinuz-2.6.22.19-desktop-2mdv

 

How about "Append", "Default" and "Initrd"?

 

 

In case you need to know, these are my partitions:

(Partition | Filesystem | Mountpoint | What's this? | Flags)

/dev/sda1 | ntfs | /media/disk-2 | Windows | boot

 

/dev/sda2 | extended | - | - | -

-What is this anyway? It claims to be 100GB but as far as I know this partition doesn't exist..?

 

/dev/sda8 | ext3 | /media/disk-1 | Ubuntu | -

-It's only 3.1GB. Do I need a bigger partition for this?

 

/dev/sda5 | ext3 | /media/disk-3 | Mandriva | -

 

/dev/sda6 | linux-swap | - | swap | -

 

/dev/sda7 | ext3 | /media/disk | my /home partition | -

 

The home partition, of course, is supposed to be used by both Ubuntu and Mandriva.

 

The command find /boot/grub/stage1 returns:

(hd0,4)

(hd0,7)

 

 

I've got no idea what to do.

 

So:

 

A ) how to make an entry that works?

B ) how to fix the entry that does boot Ubuntu but disables my mouse?

 

 

Thanks,

Tapksa

Edited by tapksa
Link to comment
Share on other sites

Could you please provide the contents of /boot/grub/grub.conf

[root@localhost ~]# cd /boot/grub

[root@localhost grub]# d

device.map e2fs_stage1_5 ffs_stage1_5 install.sh.old* jfs_stage1_5 menu.lst.example minix_stage1_5 stage1 ufs2_stage1_5 xfs_stage1_5

device.map.old fat_stage1_5 install.sh* iso9660_stage1_5 menu.lst menu.lst.old reiserfs_stage1_5 stage2 vstafs_stage1_5

 

Maybe that explains something.

Link to comment
Share on other sites

What he means is your grub.conf file itself.

 

cat /boot/grub/grub.conf

 

Might be called menu.lst on some systems. (like yours in the directory listing above)

 

If you can provide that for both the Mandriva grub and the ubuntu one, it would be really helpful.

Edited by liquidzoo
Link to comment
Share on other sites

a bit of topic but only since 2008.1 spring mandriva also recognizes and adds other linux distros to grub ;) if you get spring or upgrade to spring you can fix it with the normal mandriva tools

Edited by ffi
Link to comment
Share on other sites

The contents of Mandriva's menu.lst:

 

timeout 10
color black/cyan yellow/cyan
gfxmenu (hd0,4)/boot/gfxmenu
default 0

title linux
kernel (hd0,4)/boot/vmlinuz BOOT_IMAGE=linux root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788
initrd (hd0,4)/boot/initrd.img

title linux-nonfb
kernel (hd0,4)/boot/vmlinuz BOOT_IMAGE=linux-nonfb root=/dev/hda5 resume=/dev/hda6
initrd (hd0,4)/boot/initrd.img

title failsafe
kernel (hd0,4)/boot/vmlinuz BOOT_IMAGE=failsafe root=/dev/hda5 failsafe
initrd (hd0,4)/boot/initrd.img

title windows
root (hd0,0)
makeactive
chainloader +1

title desktop 2.6.22.9-1
kernel (hd0,4)/boot/vmlinuz BOOT_IMAGE=desktop_2.6.22.9-1 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788
initrd (hd0,4)/boot/initrd.img

title desktop 2.6.22.12-1
kernel (hd0,4)/boot/vmlinuz-desktop BOOT_IMAGE=desktop_2.6.22.12-1 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788
initrd (hd0,4)/boot/initrd-desktop.img

title desktop 2.6.22.18-1
kernel (hd0,4)/boot/vmlinuz-2.6.22.18-desktop-1mdv BOOT_IMAGE=desktop_2.6.22.18-1 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788
initrd (hd0,4)/boot/initrd-2.6.22.18-desktop-1mdv.img

title desktop 2.6.22.19-2
kernel (hd0,4)/boot/vmlinuz-2.6.22.19-desktop-2mdv BOOT_IMAGE=desktop_2.6.22.19-2 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788
initrd (hd0,4)/boot/initrd-2.6.22.19-desktop-2mdv.img

title Ubuntu
kernel (hd0,4)/boot/vmlinuz-2.6.22.19-desktop-2mdv BOOT_IMAGE=Ubuntu root=/dev/hda8 
initrd (hd0,4)/boot/initrd.img

 

There are these weirds desktop 2.6.22.xx-x things the purpose of which I know nothing. I guess I could delete those entries? Well anyway that's not that important.

 

 

 

Ubuntu's menu.lst:

# menu.lst - See: grub(8), info grub, update-grub(8)
#			grub-install(8), grub-floppy(8),
#			grub-md5-crypt, /usr/share/doc/grub
#			and /usr/share/doc/grub-doc/.

## default num
# Set the default entry to the entry number NUM. Numbering starts from 0, and
# the entry number 0 is the default if the command is not used.
#
# You can specify 'saved' instead of a number. In this case, the default entry
# is the entry saved with the command 'savedefault'.
# WARNING: If you are using dmraid do not use 'savedefault' or your
# array will desync and will not let you boot your system.
default		0

## timeout sec
# Set a timeout, in SEC seconds, before automatically booting the default entry
# (normally the first entry defined).
timeout		10

## hiddenmenu
# Hides the menu by default (press ESC to see the menu)
#hiddenmenu

# Pretty colours
#color cyan/blue white/blue

## password ['--md5'] passwd
# If used in the first section of a menu file, disable all interactive editing
# control (menu entry editor and command-line)  and entries protected by the
# command 'lock'
# e.g. password topsecret
#	  password --md5 $1$gLhU0/$aW78kHK1QfV3P2b2znUoe/
# password topsecret

#
# examples
#
# title		Windows 95/98/NT/2000
# root		(hd0,0)
# makeactive
# chainloader	+1
#
# title		Linux
# root		(hd0,1)
# kernel	/vmlinuz root=/dev/hda2 ro
#

#
# Put static boot stanzas before and/or after AUTOMAGIC KERNEL LIST

### BEGIN AUTOMAGIC KERNELS LIST
## lines between the AUTOMAGIC KERNELS LIST markers will be modified
## by the debian update-grub script except for the default options below

## DO NOT UNCOMMENT THEM, Just edit them to your needs

## ## Start Default Options ##
## default kernel options
## default kernel options for automagic boot options
## If you want special options for specific kernels use kopt_x_y_z
## where x.y.z is kernel version. Minor versions can be omitted.
## e.g. kopt=root=/dev/hda1 ro
##	  kopt_2_6_8=root=/dev/hdc1 ro
##	  kopt_2_6_8_2_686=root=/dev/hdc2 ro
# kopt=root=UUID=ff19f81d-10f6-491a-9e48-552ee23ab544 ro

## Setup crashdump menu entries
## e.g. crashdump=1
# crashdump=0

## default grub root device
## e.g. groot=(hd0,0)
# groot=(hd0,7)

## should update-grub create alternative automagic boot options
## e.g. alternative=true
##	  alternative=false
# alternative=true

## should update-grub lock alternative automagic boot options
## e.g. lockalternative=true
##	  lockalternative=false
# lockalternative=false

## additional options to use with the default boot option, but not with the
## alternatives
## e.g. defoptions=vga=791 resume=/dev/hda5
# defoptions=quiet splash

## should update-grub lock old automagic boot options
## e.g. lockold=false
##	  lockold=true
# lockold=false

## Xen hypervisor options to use with the default Xen boot option
# xenhopt=

## Xen Linux kernel options to use with the default Xen boot option
# xenkopt=console=tty0

## altoption boot targets option
## multiple altoptions lines are allowed
## e.g. altoptions=(extra menu suffix) extra boot options
##	  altoptions=(recovery) single
# altoptions=(recovery mode) single

## controls how many kernels should be put into the menu.lst
## only counts the first occurence of a kernel, not the
## alternative kernel options
## e.g. howmany=all
##	  howmany=7
# howmany=all

## should update-grub create memtest86 boot option
## e.g. memtest86=true
##	  memtest86=false
# memtest86=true

## should update-grub adjust the value of the default booted system
## can be true or false
# updatedefaultentry=false

## should update-grub add savedefault to the default options
## can be true or false
# savedefault=false

## ## End Default Options ##

title		Ubuntu 8.04.1, kernel 2.6.24-19-generic
root		(hd0,7)
kernel		/boot/vmlinuz-2.6.24-19-generic root=UUID=ff19f81d-10f6-491a-9e48-552ee23ab544 ro quiet splash
initrd		/boot/initrd.img-2.6.24-19-generic
quiet

title		Ubuntu 8.04.1, kernel 2.6.24-19-generic (recovery mode)
root		(hd0,7)
kernel		/boot/vmlinuz-2.6.24-19-generic root=UUID=ff19f81d-10f6-491a-9e48-552ee23ab544 ro single
initrd		/boot/initrd.img-2.6.24-19-generic

title		Ubuntu 8.04.1, memtest86+
root		(hd0,7)
kernel		/boot/memtest86+.bin
quiet

### END DEBIAN AUTOMAGIC KERNELS LIST

# This is a divider, added to separate the menu items below from the Debian
# ones.
title		Other operating systems:
root


# This entry automatically added by the Debian installer for a non-linux OS
# on /dev/sda1
title		Microsoft Windows XP Professional
root		(hd0,0)
savedefault
makeactive
chainloader	+1


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		linux (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz BOOT_IMAGE=linux root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788 
initrd		(hd0,4)/boot/initrd.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		linux-nonfb (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz BOOT_IMAGE=linux-nonfb root=/dev/hda5 resume=/dev/hda6 
initrd		(hd0,4)/boot/initrd.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		failsafe (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz BOOT_IMAGE=failsafe root=/dev/hda5 failsafe 
initrd		(hd0,4)/boot/initrd.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		desktop 2.6.22.9-1 (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz BOOT_IMAGE=desktop_2.6.22.9-1 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788 
initrd		(hd0,4)/boot/initrd.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		desktop 2.6.22.12-1 (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz-desktop BOOT_IMAGE=desktop_2.6.22.12-1 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788 
initrd		(hd0,4)/boot/initrd-desktop.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		desktop 2.6.22.18-1 (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz-2.6.22.18-desktop-1mdv BOOT_IMAGE=desktop_2.6.22.18-1 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788 
initrd		(hd0,4)/boot/initrd-2.6.22.18-desktop-1mdv.img
savedefault
boot


# This entry automatically added by the Debian installer for an existing
# linux installation on /dev/sda5.
title		desktop 2.6.22.19-2 (on /dev/sda5)
root		(hd0,4)
kernel		/boot/vmlinuz-2.6.22.19-desktop-2mdv BOOT_IMAGE=desktop_2.6.22.19-2 root=/dev/hda5 resume=/dev/hda6 splash=silent vga=788 
initrd		(hd0,4)/boot/initrd-2.6.22.19-desktop-2mdv.img
savedefault
boot

 

Did I misunderstand something?

Link to comment
Share on other sites

add exactly like this to the mandriva menu.lst else everytime you install or remove a kernel in mandriva the grub entries for ubuntu will be wiped out

you will also manually have to change the kernel files in menu.lst if you upgrade kernels in ubuntu (edit though this is not necessary for all upgrades...)

 

title		Ubuntu 8.04.1, kernel 2.6.24-19-generic
kernel	 (hd0,7)/boot/vmlinuz-2.6.24-19-generic root=UUID=ff19f81d-10f6-491a-9e48-552ee23ab544 ro quiet splash
initrd	   (hd0,7)/boot/initrd.img-2.6.24-19-generic
quiet

title		Ubuntu 8.04.1, kernel 2.6.24-19-generic (recovery mode)
kernel	(hd0,7)/boot/vmlinuz-2.6.24-19-generic root=UUID=ff19f81d-10f6-491a-9e48-552ee23ab544 ro single
initrd	  (hd0,7)/boot/initrd.img-2.6.24-19-generic

title		Ubuntu 8.04.1, memtest86+
kernel	(hd0,7)/boot/memtest86+.bin
quiet

Edited by ffi
Link to comment
Share on other sites

Did it and tried booting Ubuntu:

 

Booting 'Ubuntu 8.04.1, kernel 2.6.24-19-generic'

 

kernel (hd0,7) /boot/vmlinuz-2.6.24-19-generic root=UUID=ff19f81d-10f6-491a-9e48-552ee23ab544 ro quiet splash

 

Error 1: Filename must eb either an absolute pathname or blocklist

 

Press any key (pressing any key resulted in a text GRUB, and it didn't work at all better.)

Link to comment
Share on other sites

Two problems with this, the config ffi give you points to an updated kernel, this will not be installed if you have not yet updated the installation. The second issue is the UUID, this is a reference that is pretty much unique to ffi's setup.

it's his uuid, I took it from his ubuntu menu.lst

Link to comment
Share on other sites

title Ubuntu

kernel (hd0,4)/boot/vmlinuz-2.6.22.19-desktop-2mdv BOOT_IMAGE=Ubuntu root=/dev/hda8

initrd (hd0,4)/boot/initrd.img

 

From your menu.lst on Mandriva.

 

You're trying to boot Ubuntu from your Mandriva drive (hd0,4), using a Mandriva kernel :P

 

Yes, replacing this with the suggestion listed above should give you a working system. You could also use this:

 

title ubuntu
kernel (hd0,7)/boot/vmlinuz-2.6.24-19-generic root=/dev/hda8 resume=/dev/hda6 splash=silent vga=788
initrd (hd0,7)/boot/initrd.img-2.6.24-19-generic

Link to comment
Share on other sites

Thanks guys! It now works perfectly.

 

I really need to study all these kernel things a bit. Hopefully I don't end up asking for your help everytime I update something. :P

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...