[NTLUG:Discuss] Grub assistance
Mike LaPlante
mike at dividia.net
Mon Jan 28 08:59:05 CST 2008
Sorry to keep everyone in suspense. I got it working this weekend when I
finally got time to mess with it. Downloaded a Fedora 7 rescue CD, which
I was really hoping to avoid, but in the end it didn't take long to
download and was the quickest way to go about it.
Shutdown the system, re-ordered the drives, booted up the CD. The F7
rescue disk walks you straight through getting into a chrooted
environment. I ran grub-install /dev/sda, it spit out some output that
looked successful so I rebooted. Grub didn't work the first time.
Apparently running that command doesn't change all the lines in
grub.conf like you would think.
Luckily, as was mentioned in the above posts, grub lets you edit it from
the boot prompt. I hit "e" on the line, changed the (hd1,1) to (hd0,1)
and then hit "enter" and "b" to boot. Everything came up as expected. So
I then edited the file to make those changes permanently. Rebooted again
for kicks.
Hope this helps someone in the end. My reason for asking was to save the
time in downloading a CD hoping I could skip a step, but I think this
was quickest.
Mike
terry wrote:
> On Jan 22, 2008 3:20 PM, Mike LaPlante <mike at dividia.net> wrote:
>
>> Okay, I have a Fedora 7 system that has /dev/sda as a windows drive, and
>> /dev/sdb as linux. However, I haven't booted the windows drive in over a
>> year so I was wanting to pull that drive out of the system.
>>
>> My concern is that this will piss off grub. I'm thinking before I do
>> that I need to change some lines in grub. I'm just not sure which ones I
>> need to mess with. Also wonder if I need to mess with fdisk and change
>> the boot partition.
>>
>> Here is my current grub.conf
>> ----------------------------------------
>> # grub.conf generated by anaconda
>> #boot=/dev/sda
>> default=0
>> timeout=5
>> splashimage=(hd1,1)/grub/splash.xpm.gz
>> hiddenmenu
>> title Fedora (2.6.23.12-52.fc7)
>> root (hd1,1)
>> kernel /vmlinuz-2.6.23.12-52.fc7 ro root=LABEL=/1 noapic
>> initrd /initrd-2.6.23.12-52.fc7.img
>> title Other
>> rootnoverify (hd0,0)
>> chainloader +1
>> ---------------------------------------------
>> And here is the output of fdisk -l
>> ------------------------------------------
>> Disk /dev/sda: 61.4 GB, 61471162368 bytes
>> 255 heads, 63 sectors/track, 7473 cylinders
>> Units = cylinders of 16065 * 512 = 8225280 bytes
>>
>> Device Boot Start End Blocks Id System
>> /dev/sda1 * 1 3824 30716248+ 7 HPFS/NTFS
>>
>> Disk /dev/sdb: 120.0 GB, 120000000000 bytes
>> 255 heads, 63 sectors/track, 14589 cylinders
>> Units = cylinders of 16065 * 512 = 8225280 bytes
>>
>> Device Boot Start End Blocks Id System
>> /dev/sdb1 * 1 6374 51199123+ 7 HPFS/NTFS
>> /dev/sdb2 6375 6387 104422+ 83 Linux
>> /dev/sdb3 6388 6648 2096482+ 82 Linux swap / Solaris
>> /dev/sdb4 6649 14589 63786082+ 5 Extended
>> /dev/sdb5 6649 14589 63786051 83 Linux
>>
>>
>> Note it appears I left an NTFS partition on the second drive. I forgot
>> all about that until just now. >.<
>>
>> So do I need to change the commented out boot=/dev/sda in grub? No idea
>> why its commented out, I've never touched the file. And I think I would
>> need to change the root lines to root (hd0,1) or something like that?
>>
>> Thanks
>> Mike
>>
>>
>
> [Assuming this is an IDE drive - and that the new machine will boot to
> master on the second IDE port], install grub to it's own MBR and put
> it in the other machine as is, (as master on the second IDE port), so
> that it comes up as /dev/sdb
>
>
More information about the Discuss
mailing list