1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to remove boot manager in freebsd 8.0 ?

Discussion in 'Installing & Upgrading' started by riku, Apr 13, 2010.

  1. riku

    riku New Member

    Messages:
    14
    Likes Received:
    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
     
  2. Bunyan

    Bunyan New Member

    Messages:
    143
    Likes Received:
    0
    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.
     
  3. vermaden

    vermaden New Member

    Messages:
    2,352
    Likes Received:
    0
    @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.
     
  4. Bunyan

    Bunyan New Member

    Messages:
    143
    Likes Received:
    0
    Perhaps I should have said devices i.e files that are in use.
     
  5. phoenix

    phoenix Moderator Staff Member Moderator

    Messages:
    3,404
    Likes Received:
    0
    And, depending on the version of FreeBSD, you may need to set debugflags to 17 before you can manipulate an in-use device.
     
  6. riku

    riku New Member

    Messages:
    14
    Likes Received:
    0
    Thanks !