# grub and FreeBSD



## rosenburgcomplex (Dec 14, 2012)

Hi, new to freebsd FreeBSD and need some advice. I had windows 8 and Ubuntu installed on my computer and used grub as the boot loader. Deleted both, still have grub rescue up. I've installed freebsd FreeBSD and have no way to get to it. Is there any way I can delete grub without a windows CD. Also it still reads new partitions in rescue grub with (hd0,msdos1).


----------



## UNIXgod (Dec 14, 2012)

you can restore the master boot sector with this utility:

http://gag.sourceforge.net/


----------



## LordInateur (Dec 15, 2012)

Here's a fun way to do it...

You can always use Darik's Boot and Nuke (DBAN). It's free! Just go to www.dban.org. Burn that to CD (or if you know how, to a usb drive, or even a floppy disk) and boot from the cd. Wipe everything out, and when that's finished do a fresh install of FreeBSD with the default boot loader. Just be careful with DBAN... it destroys EVERYTHING.


----------



## wblock@ (Dec 15, 2012)

Erasing the whole disk is not necessary.  If MBR partitioning is used, as it almost always is with multi-boot systems, fdisk(8) can install a standard MBR.  So can gpart(8):
`# gpart bootcode -b /boot/mbr ada0`

mfsBSD works well for this.


----------



## rosenburgcomplex (Dec 15, 2012)

Thanks guys. I used GAG and everythings working smooth. For future cases, I will not delete the whole disk. It has taken a big chunk out of my time. Thank jebus for knoppix though.


----------



## UNIXgod (Dec 16, 2012)

rosenburgcomplex said:
			
		

> Thanks guys. I used GAG and everythings working smooth. For future cases, I will not delete the whole disk. It has taken a big chunk out of my time. Thank jebus for knoppix though.



Hit the thanks button!


----------

