How to remove boot manager in freebsd 8.0 ?

I can not use this command

Code:
fdisk -B -b /boot/boot0 ad0

error info

Code:
fdisk: Class not found
fdisk: Faild to write sector zero
 
You'll never do that as long as the filesystems are mounted (fdisk operates on unmounted filesystems only).
You need a FreeBSD LiveFS CD.
I am not sure whether it works in single-user mode.
 
@riku

Try that:
Code:
# sysctl kern.geom.debugflags=16
# kldload geom_mbr
# fdisk -B -b /boot/boot0 ad0
# sysctl kern.geom.debugflags=0
# kldunload geom_mbr

@Bunyan

fdisk(1) does not operate on filesystems ... no matter if mounted or unmounted.
 
And, depending on the version of FreeBSD, you may need to set debugflags to 17 before you can manipulate an in-use device.
 
vermaden said:
@riku

Try that:
Code:
# sysctl kern.geom.debugflags=16
# kldload geom_mbr
# fdisk -B -b /boot/boot0 ad0
# sysctl kern.geom.debugflags=0
# kldunload geom_mbr

@Bunyan

fdisk(1) does not operate on filesystems ... no matter if mounted or unmounted.

Thanks !
 
Back
Top