Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
GRUB Error 5: Partition table invalid or corrupt [SOLVED]
View unanswered posts
View posts from last 24 hours

Goto page 1, 2  Next  
Reply to topic    Gentoo Forums Forum Index Installing Gentoo
View previous topic :: View next topic  
Author Message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 12:34 am    Post subject: GRUB Error 5: Partition table invalid or corrupt [SOLVED] Reply with quote

I have the same problem with this guy https://forums.gentoo.org/viewtopic-t-828186-start-0.html but it appears that he did not resolve it.

I'm also on (hd2). Windows 7 is on hd2,0 and gentoo boot is on hd2,1.

(hd2,0) Win 7
(hd2,1) gentoo boot
(hd2,2) swap
(hd2,3) root.

what is weird, is that even before, i had to configure grub on /dev/sdb3 and use /sdb instead of /sda...This was for drive (hd0) so I thought it would be on /dev/sda (and it was because it was there). (hd1) was /dev/sdc...does it make this dev/sdd or /dev/sda? I'll try both anyway. However, I think the current config is correct since i do see the splashimage but it's not with the color or anything, it looks really messed up and it's composed of these white lines down the screen. [/code]

I think that I can possibly try disabling the other drives...but this might not work..

Also, I tried dual booting before but that time, i had seperate my partition into:
/dev/sda1 windows boot
/dev/sda2 windows root
/dev/sda3 gentoo boot gentoo
/dev/sda4 extend --
/dev/sda5 swap gentoo
/dev/sda6 root gentoo
--and it had work then, I think if i get desperate enough, I'll try that.


Last edited by Kas_ on Fri Mar 29, 2013 7:37 pm; edited 1 time in total
Back to top
View user's profile Send private message
ShadowHawk92
n00b
n00b


Joined: 04 Mar 2013
Posts: 14
Location: Texas, USA

PostPosted: Thu Mar 28, 2013 1:29 am    Post subject: grub-install Reply with quote

Since the computer seems to be seeing grub, you may just need to run grub-install again.

From reading your post it sounds like you installed on /dev/sdb so the command would be:
Code:
grub-install /dev/sdb

Otherwise replace sdb with whichever partition you installed on.

See if that works.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 5:33 pm    Post subject: Reply with quote

Quote:
but it appears that he did not resolve it.
Actually he resolved the grub error 5 problem which allowed him to discover the kernel configuration was wrong
Quote:
and now the system boots until the kernel crashes
Suggest booting the minimal install cd or a sysresccd and running
Code:
 fdisk -l | wgetpaste
post the url returned. mount the gentoo partitions and run
Code:
wgetpaste /mnt/gentoo/etc/fstab
wgetpaste /mnt/gentoo/boot/grub/grub.conf
ls -l /mnt/gentoo/boot | wgetpaste
ls -l /mnt/gentoo/boot/grub | wgetpaste
wgetpaste /mnt/gentoo/usr/src/linux/.config
post the url's returned.
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 8:46 pm    Post subject: Reply with quote

fdisk -l | wgetpaste
(I got an error when I ran this:
[code]Disk /dev/sdb doesn't contain a valid partition table[/code]
This is technically true because I use the REAL (see notes) /dev/sdb (Slave drive) to store multimedia stuff. )
https://gist.github.com/5266599

/mnt/gentoo/etc/fstab
https://gist.github.com/5266565

grub.conf
https://gist.github.com/5266574

/mnt/gentoo/boot
https://gist.github.com/5266577

/mnt/gentoo/grub
https://gist.github.com/5266583

/mnt/gentoo/usr/src/linux.config
https://gist.github.com/5266592

**Worth Mentioning**
I originally had gentoo on a different hdd and wanted to transfer it. I had transfer the .config from it.

Also, I tried to fix grub from the ORIGINAL drive (TECHNICALLY /dev/sda but gentoo saw it as /dev/sdb so gentoo calls it /dev/sdb but it is ACTUALLY /dev/sda) and that didn't work, so maybe the error is of that drive. That old drive, was one of those old IDE drives that come in two (20gb each) with a Master drive and a Slave drive which I do not think can work without the other.

Also, this drive is TECHNICALLY /dev/sdc but in fstab, I referred to it as /dev/sda (because on the old drive, it was referred to in fstab as /dev/sdb and the slave drive was called /dev/sdc therefore, i figured that this drive was /dev/sda).

I should also mentioned that I had tried to rsync everything from my old drive to this drive but it didn't work. I reformated BOTH the boot and root partition to ext4 and that erased everything.

And last, I had changed the boot order while installing windows 7 on it. I'm not sure if this really matters though.

Thanks for your help.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 9:14 pm    Post subject: Reply with quote

very interesting

what does bios show for boot order and hard drive order? bios default if available.

is the double/hybrid/combo drive on an ide cable? and the single drive sata?

any interest in disconnecting the double/hybrid/combo drive until the new install and win 7 are booting?
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 9:20 pm    Post subject: Reply with quote

BIOS shows boot sequence:
1. HDD:PM-Maxtor
2. HDD:PM-Maxtor
3. IDE:Hitachi HD
4. IDE: HL-DT-ST D

1 and 2 are the two small drives. The Hitachi one is the 1.5 tb one. It says IDE but when I first got it, it said SATA.

I'll try disconnecting it. Will it mess up the numbering /dev/sd<x> stuff?

I'm not too good with hardware, so I don't really know what cable connects it.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 9:39 pm    Post subject: Reply with quote

sata cables are a 1/4 in wide and ide about 3 inches.
Are you communicating on the machine in question?
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 9:44 pm    Post subject: Reply with quote

No, i'm on a laptop.
I'm going to try to disconnect.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 9:45 pm    Post subject: Reply with quote

turning off first :D
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 9:48 pm    Post subject: Reply with quote

OK. Also, I should mention that i used Gparted on a linux mint livecd to partition the drives...I'm not sure if this makes a difference but yeah.

Apparently gparted is an editor...so it should still work?
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 9:52 pm    Post subject: Reply with quote

gparted does the job nicely
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 9:53 pm    Post subject: Reply with quote

K, the 2 of them are connected by a really fat cable and the 1.5 tb one is connected by a skinnier one.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 9:55 pm    Post subject: Reply with quote

disconnecting the fat cable should do it. you can remove power also but do not have to.
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 9:57 pm    Post subject: Reply with quote

Ok, what if the fat cable is kinda stuck?

EDIT---
Nvm, I got it. The two cables join into one cable.


Last edited by Kas_ on Thu Mar 28, 2013 10:02 pm; edited 1 time in total
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:01 pm    Post subject: Reply with quote

either end will do board or drive
even power cable is ok but inelegant
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 10:04 pm    Post subject: Reply with quote

I just pulled the fat cables...like they're wide and flat.

So what do I do now?

I just fdisk -l;
they're all listed as /dev/sda now, I think i should toggle the boot flag to /dev/sda2 since my linux boot is there. I actually think this could have been the problem.

yeah, now there's two boot flags. What am I going to do when I reattach the other 2 drives? I'll have to change all the configs back.


Last edited by Kas_ on Thu Mar 28, 2013 10:08 pm; edited 1 time in total
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:07 pm    Post subject: Reply with quote

2 minutes please for complete, for now boot cd
_________________
Defund the FCC.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:12 pm    Post subject: Reply with quote

the find step below is expected to return (hd0,1) if it doesn't call foul
when disconnected, boot cd, mount the gentoo partitions, enter the chroot, nominally:
Code:
mount /dev/sda4 /mnt/gentoo
mount /dev/sda2 /mnt/gentoo/boot
mount -t proc none /mnt/gentoo/proc
mount --rbind /sys /mnt/gentoo/sys
mount --rbind /dev /mnt/gentoo/dev
chroot /mnt/gentoo /bin/bash
source /etc/profile
export PS1="(chroot) $PS1"
then
Code:
grub
find /boot/grub/stage1
root (hd0,1)
setup (hd0)
quit
nano /boot/grub/grub.conf
Quote:
# This is a sample grub.conf for use with Genkernel, per the Gentoo handbook
# http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=1&chap=10#doc_chap2
# If you are not using Genkernel and you need help creating this file, you
# should consult the handbook. Alternatively, consult the grub.conf.sample that
# is included with the Grub documentation.

default 0
timeout 30
#splashimage=(hd0,1)/boot/grub/splash.xpm.gz

title Gentoo Linux 3.7.10
root (hd0,1)
kernel /boot/kernel-3.7.10-gentoo root=/dev/sda4

title Gentoo Linux 3.7.10
root (hd0,1)
kernel /boot/kernel-3.7.10-gentoo root=/dev/sda4 init=/bin/bb

title Windows 7 Ultimate
rootnoverify (hd0,0)
makeactive
chainloader +1

#kernel /boot/kernel-genkernel-x86-2.6.24-gentoo-r5 root=/dev/ram0 real_root=/dev/sda3
#initrd /boot/initramfs-genkernel-x86-2.6.24-gentoo-r5

# vim:ft=conf:
Code:
nano /etc/fstab
Quote:
# /etc/fstab: static file system information.
#
# noatime turns off atimes for increased performance (atimes normally aren't
# needed); notail increases performance of ReiserFS (at the expense of storage
# efficiency). It's safe to drop the noatime options if you want and to
# switch between notail / tail freely.
#
# The root filesystem should have a pass number of either 0 or 1.
# All other filesystems should have a pass number of 0 or greater than 1.
#
# See the manpage fstab(5) for more information.
#

# <fs> <mountpoint> <type> <opts> <dump/pass>

# NOTE: If your BOOT partition is ReiserFS, add the notail option to opts.
/dev/sda2 /boot ext4 noauto,noatime 1 2
/dev/sda4 / ext4 noatimex 0 1
/dev/sda3 none swap sw 0 0
remove
Quote:
/dev/cdrom /mnt/cdrom auto noauto,ro 0 0
/dev/fd0 /mnt/floppy auto noauto 0 0
unless you have a floppy and do not want to automount cd's
Code:
exit
cd
umount -l /mnt/gentoo/dev{/shm,/pts,}
umount -l /mnt/gentoo{/boot,/proc,}
reboot

_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 10:23 pm    Post subject: Reply with quote

Wait, in my /etc/stab/ it says 'noatimex' under /dev/sda4. is that suppose to be there?

Yay! It works :) But I got a "Switching to clocksourc tsc" and it hangs there. I believe I've gotten this error before.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:27 pm    Post subject: Reply with quote

noatme only , Ihave fat fingers
_________________
Defund the FCC.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:28 pm    Post subject: Reply with quote

Switching to clocksource tsc kernel problem or did you get into sysinit?
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 10:35 pm    Post subject: Reply with quote

Huh? I've had this problem before and you've answered it before. https://forums.gentoo.org/viewtopic-t-938702-postdays-0-postorder-asc-start-25.html

I thought this would copy through since I copied it directly from the old.config but that could be because there is no linux firmware
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:40 pm    Post subject: Reply with quote

ok forgot the previous encounter
Code:
emerge linux-firmware
from the chroot if not there
and correct the kernel which shows
Code:
CONFIG_PREVENT_FIRMWARE_BUILD=y
CONFIG_FW_LOADER=y
CONFIG_FIRMWARE_IN_KERNEL=y
CONFIG_EXTRA_FIRMWARE=""
suggesting that the .config either did not copy or did not get used; will look further
_________________
Defund the FCC.


Last edited by DONAHUE on Thu Mar 28, 2013 10:42 pm; edited 1 time in total
Back to top
View user's profile Send private message
Kas_
Tux's lil' helper
Tux's lil' helper


Joined: 05 Oct 2012
Posts: 124

PostPosted: Thu Mar 28, 2013 10:42 pm    Post subject: Reply with quote

yeah. I reconnected the drives and reboot, and everything still worked. Will I need to change grub?
fdisk is ignoring the slave drive and just lists the 1.5tb drive as /dev/sda and the master drive as /dev/sdb.

And now everything is crashing..like hardcore crashing. The power randomly turns off.
Back to top
View user's profile Send private message
DONAHUE
Watchman
Watchman


Joined: 09 Dec 2006
Posts: 7651
Location: Goose Creek SC

PostPosted: Thu Mar 28, 2013 10:47 pm    Post subject: Reply with quote

power off, unplug the fat cable and power to the double drive
_________________
Defund the FCC.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Installing Gentoo All times are GMT
Goto page 1, 2  Next
Page 1 of 2

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum