boot0cfg and mask - BSD

This is a discussion on boot0cfg and mask - BSD ; Hello, I see in the man page an example for masking any other partition other than 1 and 2 with: boot0cfg -m 0x3 ad0 Since I don't understand 0x3, I can't figure out what to use for showing partition 2 ...

+ Reply to Thread
Results 1 to 6 of 6

Thread: boot0cfg and mask

  1. boot0cfg and mask

    Hello,

    I see in the man page an example for masking any other partition other than
    1 and 2 with:

    boot0cfg -m 0x3 ad0

    Since I don't understand 0x3, I can't figure out what to use for showing
    partition 2 and 4 only.

    Also, is it possible to set a specific delay before booting the default
    value? For now, it seems it's 10 secondes.

    Thanks!
    --
    Mark

  2. Re: boot0cfg and mask

    Mark Vasles wrote:
    > Also, is it possible to set a specific delay before booting the default
    > value? For now, it seems it's 10 secondes.


    In the file /boot/loader.conf, say things like:

    | autoboot_delay="3"

    cheers,
    Florian

  3. Re: boot0cfg and mask

    Mark Vasles writes:

    > I see in the man page an example for masking any other partition other than
    > 1 and 2 with:
    >
    > boot0cfg -m 0x3 ad0
    >
    > Since I don't understand 0x3, I can't figure out what to use for showing
    > partition 2 and 4 only.


    It's a bit mask. Setting bits 2 and 4 will give you a value of 10 (0xa).

    > Also, is it possible to set a specific delay before booting the default
    > value? For now, it seems it's 10 secondes.


    There is a "-t" option to boot0cfg to do that.

  4. Re: boot0cfg and mask

    Lowell Gilbert wrote:
    > Mark Vasles writes:
    >
    > > I see in the man page an example for masking any other partition other than
    > > 1 and 2 with:
    > >
    > > boot0cfg -m 0x3 ad0
    > >
    > > Since I don't understand 0x3, I can't figure out what to use for showing
    > > partition 2 and 4 only.

    >
    > It's a bit mask. Setting bits 2 and 4 will give you a value of 10 (0xa).


    I suspect you need to set bits 1 and 3 instead, because slices begin at
    1 not at 0.


    --

    Michel TALON


  5. Re: boot0cfg and mask

    talon@lpthe.jussieu.fr (Michel Talon) writes:

    > Lowell Gilbert wrote:
    >> Mark Vasles writes:
    >>
    >> > I see in the man page an example for masking any other partition other than
    >> > 1 and 2 with:
    >> >
    >> > boot0cfg -m 0x3 ad0
    >> >
    >> > Since I don't understand 0x3, I can't figure out what to use for showing
    >> > partition 2 and 4 only.

    >>
    >> It's a bit mask. Setting bits 2 and 4 will give you a value of 10 (0xa).

    >
    > I suspect you need to set bits 1 and 3 instead, because slices begin at
    > 1 not at 0.


    Right. Drives 2 and 4 require setting bits 1 and 3 respectively,
    which gives you the value of 10.

    --
    Lowell Gilbert, embedded/networking software engineer
    http://be-well.ilk.org/~lowell/

  6. Re: boot0cfg and mask

    Lowell Gilbert wrote:
    > talon@lpthe.jussieu.fr (Michel Talon) writes:
    >
    > > Lowell Gilbert wrote:
    > >> Mark Vasles writes:
    > >>
    > >> > I see in the man page an example for masking any other partition other than
    > >> > 1 and 2 with:
    > >> >
    > >> > boot0cfg -m 0x3 ad0
    > >> >
    > >> > Since I don't understand 0x3, I can't figure out what to use for showing
    > >> > partition 2 and 4 only.
    > >>
    > >> It's a bit mask. Setting bits 2 and 4 will give you a value of 10 (0xa).

    > >
    > > I suspect you need to set bits 1 and 3 instead, because slices begin at
    > > 1 not at 0.

    >
    > Right. Drives 2 and 4 require setting bits 1 and 3 respectively,
    > which gives you the value of 10.


    OK, i had understood he wanted to show 1 and 3 and hide 2 and 4,
    must have been sleeping.

    >


    --

    Michel TALON


+ Reply to Thread