Having real trouble since HDD upgrade=solved.

Questions about Grub, UEFI,the liveCD and the installer
Forum rules
Before you post please read this

Having real trouble since HDD upgrade=solved.

Postby confused.brit on Sun Jan 25, 2009 3:44 pm

Some of this is my fault.

I upgraded to a 160GB HDD, brand spanking new, and tried to 'Ghost' my existing Linux mint setup to the new HDD (thinking that since Ghost 2003 was EXT2 compatible, it would be fine...)

I didnt realise that it would mess up Grub, and I certainly didnt expect my original Mint install to be damaged in any way. But it was also rendered unbootable.

I was lucky in that I'd already made a /home partition to keep my documents on, and managed to copy that partition onto the new HDD with rsync.

I wiped the MBR on the old HDD with dd, and made the old drive one whole blank partition then tried to install Mint Elyssa onto the initial partition of the new HDD.

Somehow, the Mint Install will not install grub. I have had to manually copy stage1, e2fs_stage1_5 and stage 2 to /boot/grub on the mint partition from /usr/lib/grub on the LiveCD and tried, using a guide to dualbooting, making a new menu.lst. I then installed it using the grub shell from terminal.

This is not 100% functional, but my inexperienced eye cannot see where the fault is. It is pastebinned here http://pastebin.com/m3e51907a

Here is a ls of my /boot on the system partition. I labelled it and went thru media to ensure I had the right partition, btw.

mint@mint /media/MintGnome/boot/grub $ ls
e2fs_stage1_5 menu.lst rain_drops_splash.xpm.gz stage1 stage2
mint@mint /media/MintGnome/boot/grub $ cd..
bash: cd..: command not found
mint@mint /media/MintGnome/boot/grub $ cd /media/MintGnome/boot
mint@mint /media/MintGnome/boot $ ls
abi-2.6.24-16-generic initrd.img-2.6.24-16-generic.bak
config-2.6.24-16-generic memtest86+.bin
grub System.map-2.6.24-16-generic
initrd.img-2.6.24-16-generic vmlinuz-2.6.24-16-generic
mint@mint /media/MintGnome/boot $

Can anyone see what's missing?

I forgot to mention,

Where booting now fails -
option 1 complains error 15: file not found pressany key, and takes me back to Grub menu.
option 2 (recovery option) begins booting fine, but only reaches
[92.237177] /build/buildd/linux2.6.24/drivers/HID/USBHID/hid-core.c:v2.6 USB HID core driver
then hangs.

I havent tested other options on the list because 1) right now they are leftover code from the example menu.lst I'm working from 2)all bar the memtest code will be deleted soon.
Last edited by confused.brit on Mon Jan 26, 2009 1:44 pm, edited 1 time in total.
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Linux Mint is funded by ads and donations.
 

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 4:28 pm

## hiddenmenu
Code: Select all
# Hides the menu by default (press ESC to see the menu)
#hiddenmenu
# Pretty colours
#color cyan/blue white/blue

#splashimage=(hd0,0)/boot/grub/rain_drops_splash.xpm.gz
#foreground ffffff
#background 008080
#viewport 11 6 66 16

## 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

Hello confused.brit,
Can you please either 'comment out' or delete the splashimage code, and see if that helps?

Regards, Herman :)
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 4:46 pm

Can you please post the outputs from 'sudo fdisk -lu'n and 'sudo blkid' commands.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby confused.brit on Sun Jan 25, 2009 4:59 pm

Thanks Herman.

Commenting out splashimage code and the colours below it does nothing.

As to the output:
sudo fdisk -lu'n
appears to do nothing except print a > and then wait for me to hit ctrl-c
mint@mint ~ $ sudo blkid
/dev/sda1: LABEL="MintGnome" UUID="8d7fc387-a310-4522-811f-36e095b63642" TYPE="ext3"
/dev/sda2: UUID="30163ad4-0728-4cad-8e7b-e7ec6e753f0b" SEC_TYPE="ext2" TYPE="ext3"
/dev/sda4: TYPE="swap" UUID="d131a44f-e3f6-46b0-bad1-0d3738673b3b"
/dev/sdb1: UUID="afa16015-ffe1-49f1-b5d4-2a5847c61ce3" TYPE="ext2"
/dev/loop0: TYPE="squashfs"

MintGnome labelled partition is where the Mint install is.
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Re: Having real trouble since HDD upgrade

Postby confused.brit on Sun Jan 25, 2009 5:06 pm

output from Cfdisk on the new HDD

Code: Select all
 Disk Drive: /dev/sda
                       Size: 160041885696 bytes, 160.0 GB
             Heads: 255   Sectors per Track: 63   Cylinders: 19457

    Name        Flags      Part Type  FS Type          [Label]        Size (MB)
 ------------------------------------------------------------------------------
    sda1        Boot        Primary   Linux ext3       [MintGnome]     23368.03
    sda2                    Primary   Linux ext3                       43190.95
                            Pri/Log   Free Space                       89523.95
    sda4                    Primary   Linux swap / Solaris              3956.36
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 5:17 pm

sudo fdisk -lu'n
Sorry, my bad, (typo), I meant: sudo fdisk -lu
Code: Select all
sudo fdisk -lu

Sorry.
Your menu.lst looks okay to me so far and matches your blkid output.

Thanks for the Cfdisk, that will do instead.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 5:26 pm

Check and make sure the installation has a file called /sbin/init, which is the other file after the kernel and initrd.img that's necessary for booting.
(Since GRUB wasn't installed for some reason, it could be that some other important files are missing as well - just check please).
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby confused.brit on Sun Jan 25, 2009 5:27 pm

yes, this is there.

Also, I dont know why im having this trouble. This is the same LiveCD I installed to the 40GB originally. not just the same ISO, the same, untouched cd media disk with mint burned onto it. And that installed first time round no problems.
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 5:55 pm

I don't know either, it looks to me as if you have done everything correctly and all is well, . . . but yet, it doesn't boot .
I am having to drink an extra cup of coffee for this one.

Okay, I have been delving into my GRUB Error collection, where I record past experiences and possible solutions for every GRUB error I have experience with, here's my reference to GRUB Error 15, http://users.bigpond.net.au/hermanzone/p15.htm#15

I am looking at the second and third possible causes of GRUB Error 15 in that URL, and wondering if the fact that you copied GRUB's stage2 from a CD would have anything to do with your problem, (it shouldn't), or if the third reason (stage2 file corruption) could be the problem? You should normally be able to do what you did alright, it's just that I can't see anything else wrong.

How about we try chrooting into your newly installed operating system from the Live CD and running grub-install while we're in there.
The idea is to refresh the GRUB files from the OS'es own /sbin/grub and that should take care of both of the above-mentioned possibilities in one go.

If you agree, try these commands,
Code: Select all
sudo mount -t proc none /media/MintGnome/proc

Code: Select all
sudo mount -o bind /dev/ /media/MintGnome/dev

Code: Select all
sudo chroot /media/MintGnome /bin/bash

Code: Select all
grub-install /dev/sda

Code: Select all
update-grub

Code: Select all
exit

Code: Select all
sudo umount /media/MintGnome/proc

Code: Select all
sudo umount /media/MintGnome/dev

Code: Select all
sudo umount /media/MintGnome
It's not normally necessary to chroot and run grub-install, the process you used in the first place should be okay, but maybe grub-install will help in this instance.
EDIT: I decided to add 'update-grub' in the list of commands there as well, just for good measure . . . actually, that might even be the one that fixes it for you.
Last edited by herman on Sun Jan 25, 2009 6:02 pm, edited 1 time in total.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby confused.brit on Sun Jan 25, 2009 6:01 pm

Code: Select all
mint@mint ~ $ sudo mount -t proc none /media/MintGnome/proc
mint@mint ~ $ sudo mount -o bind /dev/ /media/MintGnome/dev
mint@mint ~ $ sudo chroot /media/MintGnome /bin/bash
bash: groups: command not found
bash: /usr/bin/mint-fortune: No such file or directory
root@mint / # sudo grub-install /dev/sda
bash: sudo: command not found

I realise Im already root so i try without sudo

Code: Select all
root@mint / # grub-install /dev/sda
Your /usr is broken; please fix it before calling this wrapper!
root@mint / #


Oh, one more thing, I've been asking this question on another forum where techie minded people like myself hang out and they have suggested I might try to disable apci for option 2 by adding the following to the "kernel" option in grub: acpi=off no l apic

Now the only new hardware to this system is this HDD, and a CDRW drive attached to secondary IDE and jumpered Master. Do you think this is worth a shot? Personally, I feel the problem this would solve would have been picked up with the LiveCD, but I've not been using linux long.
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 6:15 pm

Okay, it wouldn't do any harm to try that.
In the meantime, I'll run through those chroot commands in one of my own computers and make sure they will work for me with my own Felicia installation.
I have used those commands for Ubuntu, and Mint is based on Ubuntu, so I was assuming the same commands would work, sorry if I'm wrong.
If the same commands do work properly for me, it might tend to indicate that more than just your GRUB files might be missing from the installation, in which case you might just need to try installing again, and hope for better luck the second time around. Don't give up and re-install yet though, maybe we can still solve this the proper way.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby confused.brit on Sun Jan 25, 2009 6:35 pm

This would be fourth, hence me trying to fix grub myself :|

(once with /home on second partition, once not telling it about /home, once again with second partition as home as its my preferred option, hoping it would write my menu.lst for me!)

Every time I try to reinstall I end up back at square 1 with no /boot/grub

This time im gonna put /boot/grub on a floppy first so I dont loose menu.lst after all the work I put into it!

Related: how do you mount a floppy without formatting it with gfloppy first?
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 6:49 pm

Well, I'm back after having run the commands I gave you earlier for chrooting from my Mint Felicia live CD into a hard disk installed Felicia operating system and those commands worked perfectly for my installation.

If you haven't made any mistakes in those commands then I'm not sure, but it seems as if further investigation might be necessary to investigate the state incompletedness, (or incompletedness), of your new Mint installation.
Or, you might find it faster to just try installing again.
I have had incomplete Linux installations before myself, and the few times it has happened to me, wiping the CD with a soft cloth dipped in methylated spirits (denatured alchohol) seems to have brought me good luck.
Something else I've had to do is dis-assembling the optical drive and wiping the optical drive lense with a cotton bud (Q tip) dipped in metho.
I do live in a particularly dusty climate though, so maybe people in other places wouldn't have the same problems as I do.
Normally if the CD passes it's own inbuilt integrity test, it should be okay to install with.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 6:53 pm

Every time I try to reinstall I end up back at square 1 with no /boot/grub
Sorry, that must be extremely frustrating for you, I feel for you.
This time im gonna put /boot/grub on a floppy first so I dont loose menu.lst after all the work I put into it!
Good idea!
Related: how do you mount a floppy without formatting it with gfloppy first?

I don't know anything about gfloppy, but it doesn't matter what file system you use for GRUB, any file system will do.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 6:55 pm

What jumper settings and IDE cables are you using?
Or is your new hard disk SATA (SCSI).
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 7:04 pm

Wait!
I wiped the MBR on the old HDD with dd, and made the old drive one whole blank partition then tried to install Mint Elyssa onto the initial partition of the new HDD.

Hmmm, I might have overlooked something blindingly simple and obvious way back in your first post: Mint Elyssa

My Mint Elyssa still has the old style 'root (hd0,0)' type hard drive numbering, and 'root=/dev/sda1' in the kernel line in menu.lst.

This doesn't explain why you're having trouble getting GRUB to install properly in the fist place, or why you got 'bash: groups: command not found
bash: /usr/bin/mint-fortune: No such file or directory' when you were chrooting, but certainly you would have had more luck trying to boot it with your copied-in GRUB if you had used the old fashioned kind of menu.lst entry.

Code: Select all
## ## End Default Options ##

title    Linux Mint, kernel 2.6.24-16-generic
root       (hd0,0)
kernel   /boot/vmlinuz-2.6.24-16-generic root=/dev/sda1 ro quiet splash
initrd   /boot/initrd.img-2.6.24-16-generic
quiet
savedefault

 
title    Linux Mint, kernel 2.6.24-16-generic (recovery mode)
root       (hd0,0)
kernel   /boot/vmlinuz-2.6.24-16-generic root=/dev/sda1 ro single
initrd   /boot/initrd.img-2.6.24-16-generic
 

title    Ubuntu, memtest86+
root       (hd0,0)
kernel   /boot/memtest86+.bin
quiet
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby confused.brit on Sun Jan 25, 2009 7:30 pm

IDE cable on HDD drives is brand new 75CM ATA

Jumpers set to 160GB Master 40GB slave on primary IDE
Older IDE cable from secondary IDE to optical drives
CDRW jumpered Master, DVDROM Slave

I never leave my drives on cable select. I am a bit of a control freak in that respect.

Yeah comparing /usr with /usr on the liveCD seems loads of stuff did not copy accross for some reason.

and on the suggestions of the other forum I had tried changing it to (hd0,0) etc but it did nothing.

So, i guess its wipe the partition and reinstall again... :roll:
User avatar
confused.brit
Level 1
Level 1
 
Posts: 37
Joined: Thu Jan 01, 2009 12:33 pm

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 7:41 pm

Okay, most new IDE cables these days are the cable select type. As long as your jumper settings aren't conflicting with the cable-select, I mean your hard drive that is set as master is plugged into the black or end plug and the middle, grey plug is plugged into your slave hard drive isn't it? (Even though you are using jumper settings in addition to that).

I'm sorry you're having so much trouble, I wish you better luck this time.

. . . or download Felicia and install that instead.

Felicia supports UUID booting.
UUID booting is really great, especially for those of us who change hard disks or use USB drives, and also for those if us who have IDE drives and SCSI (SATA) drives in the same computer.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 7:55 pm

If you still have trouble, consider setting your jumper settings to 'cable select', if you're using a 'cable-select' type of IDE ribbon cable, and try installing again and see if that clears up your problems.
The BIOS and jumper settings can be a bit finicky, and can cause all kinds of real problems if they aren't right. :D
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Re: Having real trouble since HDD upgrade

Postby herman on Sun Jan 25, 2009 8:08 pm

75 cm is long for an IDE cable, standard is around 46 cm.
I have read they have been tested and proven to be reliable as long as 69 cm for an 80 conductor cable, and yours is a bit longer than that.
That could be one factor contributing to your problems.
It could be that my information is out of date though, so I'm not sure.
The only way is probably to keep trying until we see what works and what doesn't I suppose, but if a shorter IDE cable will still reach, you might want to try that and see if it helps.
User avatar
herman
Level 1
Level 1
 
Posts: 33
Joined: Tue Jan 13, 2009 4:52 pm
Location: Australia

Linux Mint is funded by ads and donations.
 

Return to Installation & Boot

Who is online

Users browsing this forum: No registered users and 22 guests