SOLVED mint failing to load

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
rwint

SOLVED mint failing to load

Post by rwint »

i have recently moved from xp to mint and have been enjoying not having errors every 5 minutes..but this is my first problem with mint and is beyond my abilities to fix it.
the problem is,after an update,my mint no longer boots up.i have read as much as i can but cannot fix it.i have found out that my grub menu.1st file has been wiped.so using a live cd,i tried to use details from another menu.1st file just to see if anything would work and i now get the boot menu on start up and then to busybox v1.10.2 but it is not loading my mint or xp,just get errors like dev/sdb3 does not exist..i am not sure what to write in the menu.1st to boot them.
i have managed to get xp to boot using Super grub disk.which was usefull.
i really want to use mint and i have created a desktop that i was very happy with so i don't want to lose it now. :(
please help me out.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 2 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
viking777

Re: mint failing to load

Post by viking777 »

Don't panic rwint, I am sure somebody here can solve this for you - even if it isn't me! First thing I should explain is that the file you are concerned about is called menu.lst not menu.1st (ie the first character after the dot is a letter not a number). This is a minor point but it may prove important later if you have to type the name of the file in some command. Second if you can boot into the live cd then you should be able to fix this problem.

There are probably a dozen ways to fix it, but I would like to start with possibly the simplest. You boot into your live cd, open a file manager and have a look in /boot/grub - this is where menu.lst lives. Have a look in there for a backup file - possibly menu.lst~. If you have one then this is where to start.

I can't remember if the live cd has a root file manager in the menu, if it does search it out and start it. (if it asks for a root password then in a live cd that is usually 'root'). If it doesn't have one then use Alt/F2 followed by 'gksu nautilus' or ' gksudo nautilus' if that doesn't work. Assuming you have a root file manager now then go to /boot/grub right click on menu.lst and rename it menu.lst.old then right click on menu.lst~ and rename it menu.lst. then reboot.

Mint will now start up with your previous version of menu.lst and if this is the problem then it should now be solved - it may not be the problem of course but we have to start somewhere.
distoaddict

Re: mint failing to load

Post by distoaddict »

This topic of piratesmack may be of help http://forums.linuxmint.com/viewtopic.php?f=42&t=19208
rwint

Re: mint failing to load

Post by rwint »

thanks for the replies.
i have been in the boot/grub folder and i don't have any backup of it.next time i will be backing it up!
i have worked out how to edit the file with sudo gedit /boot/grub/menu.lst so at least i am progressing in the right direction.piratesmack is useful but i need help on re writing the menu.lst file for my setup or maybe there is an easier way you can suggest?
distoaddict

Re: mint failing to load

Post by distoaddict »

as i understand it :running update grub in a terminal rebuilds menu.lst
rwint

Re: mint failing to load

Post by rwint »

i gave update-grub ago using the live cd and i got this:

debconf: DbDriver "passwords" warning: could not open /var/cache/debconf/passwords.dat: Permission denied
Searching for GRUB installation directory ...
No GRUB directory found. To create a template run 'mkdir /boot/grub' first. To install grub, install it manually or try the 'grub-install' command. ### Warning, grub-install is used to change your MBR. ###

also tried:

mint@mint /media/disk/boot/grub $ update-grub
debconf: DbDriver "passwords" warning: could not open /var/cache/debconf/passwords.dat: Permission denied
Searching for GRUB installation directory ... found: /boot/grub
Distro title is set to Linux Mint 6
Searching for default file ... Generating /boot/grub/default file and setting the default boot entry to 0
Searching for GRUB installation directory ... found: /boot/grub
/usr/sbin/grub-set-default: 124: cannot create /boot/grub/default: Permission denied
Testing for an existing GRUB menu.lst file ...

Could not find /boot/grub/menu.lst file. Would you like /boot/grub/menu.lst generated for you? (y/N) y


after pressing y it just blinks and nothing happens?not sure what further commands i would have to do?
viking777

Re: mint failing to load

Post by viking777 »

I'm very confused now (but it happens often!). You say you have been into boot/grub/menu.lst and tried to edit the file, yet the update-grub command says that you don't have any such file as boot/grub/menu.lst. If you could explain this it might go some way to solving the problem. Are you sure this isn't a typo (like menu.1st instead of menu.lst?).

If you can find a way to copy the contents of your menu.lst file (if it exists!) and paste them here that would be very helpful. As would the output of

Code: Select all

sudo blkid -c /dev/null

from a terminal. I realise you will have to do this from a live cd which might throw a spanner in the works, but try it anyway and see what you get.

EDIT.I had a look through some old notes of mine and I have found a procedure that is suited to the situation you seem to be in ie. you have lost or corrupted menu.lst. It is a little bit complicated and I haven't used it myself but it is supposed to work. This procedure assumes the worst case scenario, it could be shortened if I knew exactly what you are seeing, but i don't, so you had best follow it like this:

Boot live cd and open a terminal.

Code: Select all

sudo su

Code: Select all

fdisk -l
this will tell you the device address of your linux partition (in fact all your partitions) in case you don't know it. In this example I have assumed it is /dev/sda3 but it might not be so substitute the correct value.

Code: Select all

 mkdir /media/test
creates a directory for you to mount your operating system on

Code: Select all

mount -t ext3 -o dev /dev/sda3 /media/test
mounts your operating system in the directory you have just made. NB. It may not be /dev/sda3

Code: Select all

 chroot /media/test
this switches you into the Mint install so you can execute commands in it

Code: Select all

grub-install /dev/sda
this reinstalls grub completely including rewriting the menu.lst file, but make sure that sda is the disk you want to install grub to. If you have more than one disk it may not be.

Code: Select all

exit
this exits you from Mint back to the live cd

Code: Select all

umount /media/test
unmounts the mint install from the live cd

Code: Select all

rmdir /media/test
removes the directory you created earlier

Code: Select all

init 6
reboots your computer

Fingers crossed, when it boots up again you will see a grub menu (don't panic if it doesn't contain windows - if you have windows that is, it can easily added manually if necessary).
rwint

Re: mint failing to load

Post by rwint »

viking777 wrote:I'm very confused now (but it happens often!). You say you have been into boot/grub/menu.lst and tried to edit the file, yet the update-grub command says that you don't have any such file as boot/grub/menu.lst. If you could explain this it might go some way to solving the problem. Are you sure this isn't a typo (like menu.1st instead of menu.lst?)..
i copied and pasted into the terminal so i am sure that it isn't a mistake.i am confused as well. :lol:
here are the results from your commands:
mint@mint ~ $ sudo blkid -c /dev/null
/dev/sda1: UUID="8038E9E938E9DE62" TYPE="ntfs"
/dev/sda5: UUID="21a14d12-c6f8-422f-a491-b9ded6f9fb5b" TYPE="ext3"
/dev/sda6: TYPE="swap" UUID="a85f69c4-9243-4394-97b5-0e5a4321108b"
/dev/loop0: TYPE="squashfs"
mint@mint ~ $ sudo su
_________________________________________
Disk /dev/sda: 160.0 GB, 160041885696 bytes
255 heads, 63 sectors/track, 19457 cylinders
Units = cylinders of 16065 * 512 = 8225280 bytes
Disk identifier: 0xace22e9e

Device Boot Start End Blocks Id System
/dev/sda1 * 1 10563 84847266 7 HPFS/NTFS
/dev/sda2 10564 19457 71441055 5 Extended
/dev/sda5 10564 19089 68485063+ 83 Linux
/dev/sda6 19090 19457 2955928+ 82 Linux swap / Solaris
mint mint # mkdir /media/test
mkdir: cannot create directory `/media/test': File exists
mint mint # mount -t ext3 -o dev /dev/sda5 /media/test
mount: /dev/sda5 already mounted or /media/test busy
mount: according to mtab, /dev/sda5 is already mounted on /media/test
mint mint # chroot /media/test
_________________________________________
mint / # grub-install /dev/sda
/dev/sda: Not found or not a block device.
mint / #

this is the second time i tried the commands with slightly different outcomes,the first 3 commands worked,but mint / # grub-install /dev/sda didn't seem to work?
am i correct in using dev/sda5?
also you requested my menu.lst file.it may confuse the problems i am having,as when it originally stopped working it only had a one line command in it.i then used some commands of another one i had found of the net.which at least then i had some operating systems to choose from,even though none of them worked.do you still want me to try and paste it on here?
thanks
Fred

Re: mint failing to load

Post by Fred »

rwint,

Not meaning to interfere, but if you have a menu.lst in /boot/grub, it would be helpful to post it along with a screen shot from Gparted of your partition table. Gparted is a partitioning program and can be found in your menu.

Fred
rwint

Re: mint failing to load

Post by rwint »

# 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-legacy-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 change this entry to 'saved' or your
# array will desync and will not let you boot your system.
default 0

## Graphical boot menu location
gfxmenu=/boot/gfxmenu/default.message

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

# 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=/dev/sdb3 ro

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

## 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=(single-user) 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 Linux Mint, kernel 2.6.27-11-generic
root (hd0,4)
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=db4dcb0c-02bd-4d2e-a4fa-deb420b3bfa0 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-generic


title Linux Mint 6, kernel 2.6.27-7-generic (recovery mode)
root (hd0,4)
kernel /boot/vmlinuz-2.6.27-7-generic root=/dev/sdb3 ro single
initrd /boot/initrd.img-2.6.27-7-generic

title Linux Mint 6, kernel Last successful boot
root (hd0,4)
kernel /boot/last-good-boot/vmlinuz root=/dev/sdb3 ro quiet splash last-good-boot
quiet

title Linux Mint 6, memtest86+
root (hd0,4)
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/sdb1
title Windows XP (loader)
root (hd0,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1
viking777

Re: mint failing to load

Post by viking777 »

Well that certainly won't boot because the UUid that you have there is not correct.

In this:
title Linux Mint, kernel 2.6.27-11-generic
root (hd0,4)
kernel /boot/vmlinuz-2.6.27-11-generic root=UUID=db4dcb0c-02bd-4d2e-a4fa-deb420b3bfa0 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-generic

change the UUID to =21a14d12-c6f8-422f-a491-b9ded6f9fb5b

lower down change

title Windows XP (loader)
root (hd0,0)
savedefault
makeactive
map (hd0) (hd1)
map (hd1) (hd0)
chainloader +1

to

title Windows XP (loader)
root (hd0,0)
savedefault
makeactive
chainloader +1

then try again.
It might work if 2.6.27-11 is actually the kernel you have installed. If it isn't you will have to alter that as well. (You can find this out by looking in /boot for something that starts vmlinuz-xx)
Fred

Re: mint failing to load

Post by Fred »

rwint,

How many drives do you have attached to this machine? Just the one? If the answer is one continue, otherwise post back with the answer and tell me if they were connected when you took that screen shot from Gparted.

Go to the url below and download and burn the latest stable version of SuperGrub live cd iso. We will use this to boot Linux with.

http://download.linux-live-cd.org/Super ... sgd/cdrom/

Use this cd to boot into your Linux install. Do not attempt to fix or repair anything with it. Use it just to boot into the Linux install.

When you get to the desktop open a terminal and type:

sudo grub

root (hd0,4)

setup (hd0)

quit

gksu gedit /boot/grub/menu.lst

This will open your menu.lst for editing. I will post below the portions you need to change in bold

## 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=/dev/sda5 ro

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

## ## End Default Options ##

title Linux Mint, kernel 2.6.27-11-generic
root (hd0,4)
kernel /boot/vmlinuz-2.6.27-11-generic root=/dev/sda5 ro quiet splash
initrd /boot/initrd.img-2.6.27-11-generic


title Linux Mint 6, kernel 2.6.27-7-generic (recovery mode)
root (hd0,4)
kernel /boot/vmlinuz-2.6.27-7-generic root=/dev/sda5 ro single
initrd /boot/initrd.img-2.6.27-7-generic

title Linux Mint 6, kernel Last successful boot
root (hd0,4)
kernel /boot/last-good-boot/vmlinuz root=/dev/sda5 ro quiet splash last-good-boot
quiet

title Linux Mint 6, memtest86+
root (hd0,4)
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 Windows XP (loader)
root (hd0,0)
makeactive
chainloader +1


Ok... save and close this file.

OOOps... I am going to need a copy of your /etc/fstab file also. Type /etc/fstab into the url window of your browser. Copy and past the contents back to the forum.

Fred
rwint

Re: mint failing to load

Post by rwint »

I have mint back! :D
some good advice viking777 :D got it working by changing the uuid to the suggested.
Thanks guys,really appreciate the help you have given me.
im gonna go and back up my menu.lst file now..
Fred

Re: mint failing to load

Post by Fred »

Good work to both of you. :-)

Fred
viking777

Re: mint failing to load

Post by viking777 »

That is a relief and thanks for your help as well Fred - we make a good team!!
Fred

Re: mint failing to load

Post by Fred »

viking777,

You are younger and faster than I am. :-)

I was just slowly redoing everything. Slow and plodding, that's me. :-)

You did good. I am sorry I interfered.

Fred
viking777

Re: SOLVED mint failing to load

Post by viking777 »

You are younger and faster than I am.
Fred, It is many years since I have been called 'young' and I have never been called fast :)
Slow and plodding, that's me.
Ditto
I am sorry I interfered
It was your interference that allowed me to see the answer. Feel free to interfere when ever you like.
rwint

Re: SOLVED mint failing to load

Post by rwint »

i have a couple more questions,hopefully you can solve for me.
my recovery mode doesn't boot,what can i change in the menu.lst file to get it working?
also i dont get the mint progress bar loader now,just a screen of commands,anyway of getting that back?
thanks again
viking777

Re: SOLVED mint failing to load

Post by viking777 »

Try this:

title Linux Mint 6, kernel 2.6.27-11-generic (recovery mode)
root (hd0,4)
kernel /boot/vmlinuz-2.6.27-11-generic root=/dev/sda5 ro single
initrd /boot/initrd.img-2.6.27-11-generic

As for progress bars on boot up, I wouldn't tell you the answer to that even if I knew it. Boot splash screens are for pussies, I consider myself a serious user and as such I want to know what is happening to my computer whilst it is booting, not have it hidden with pathetic pictures. I spend ages trying to get rid of the pesky things, if you have done so accidentally then I wish you could tell me how you have done it!!

Rwint, it seems pretty obvious to me that you must have copied somebody elses menu.lst file into your system in order to get into this mess. Please understand you cannot do this. menu.lst is very specific to your computer. When you have it working to your satisfaction back it up somewhere you aren't going to lose it (like an external hard drive or second computer). While you are at it back up /etc/X11/xorg.conf and
/etc/fstab as well.
rwint

Re: SOLVED mint failing to load

Post by rwint »

lol,ok i will leave my boot splash screen.i have no idea how it disappeared :lol:
everything is backed up now
Locked

Return to “Installation & Boot”