LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   install grub to new clean hard drive? (https://www.linuxquestions.org/questions/linux-general-1/install-grub-to-new-clean-hard-drive-466377/)

Hosiah 07-21-2006 06:50 PM

install grub to new clean hard drive?
 
Here's my situation: picked up old computer at a yard sale. It's a middle-line NEC from about 1998 or so. Wiped all traces of Windows off it with a dd if=/dev/zero of=/dev/hda like I normally would before installing Linux.

This time, the hard drive is 80Gigs! So I want to slice it in pieces and do multiboot. So I want to put GRUB on the front MBR. Except simply saying "grub-install /dev/hda" gets me "device not found or not a block device".

Do I need to make a partition for it first?
What about a file system on a partition first?
Is this a problem because of the huge IDE disk?

Always before I've just started with a Linux install disk. Every Google search I make for this addresses everything about dual-booting Windows, recovering systems, etc. Nothing seems to talk about starting from the bare iron.

twantrd 07-21-2006 07:04 PM

I haven't installed grub this way in a while so someone please chime in :). However, I think you need to partition your drive and install a filesystem first before you install grub into your MBR.

-twantrd

Hosiah 07-21-2006 07:43 PM

Actually, I think I have found a page that can explain it to my simple little brain. Finally thought to google "grub tutorial". I think the reason I got lost is because I thought this would be a one-minute job, like fdisk is.

pixellany 07-21-2006 08:26 PM

The normal way to do things would be to install a Linux distro and let it install GRUB. Also--according to the GRUB manual, it is better to install from the GRUB shell, using:
root (hdX,Y) X,Y being the partition where the OS is rooted
setup (hd0) to put grub on the mbr of drive 1.

Hosiah 07-21-2006 08:55 PM

"root (hdX,Y) X,Y"

tried that too, it *still* can't find the hard drive, although I followed the recipe on the page I linked to and got a generic grub boot floppy, menu and all. But I'll now try the same method that I used on the floppy (you have to create a file system on the floppy first) on the hard drive. No matter what the size, I should be able to plonk down a /boot partition at {hda1 to +128MB} and write the floppy files into it. Therafter I can add partitions going forward.

I theee-e-e-nk...

syg00 07-21-2006 09:02 PM

You need a partition for the stage files.
On a system that old I'd make a small (128M is *plenty*) ext2 partition at the beginning of the disk to ensure you don't have any BIOS issues with the 1024 cylinder problem.
Not likely, but easy to avoid any "funnies".

Then grub-install (which is just a wrapper) should work fine - IIRC it needs to be able to find /boot.


All times are GMT -5. The time now is 04:16 PM.