Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 29 Nov 2014 16:41:19 +0100
From:      Lorenzo Perone <lopez.on.the.lists@yellowspace.net>
To:        Mykola Golub <to.my.trociny@gmail.com>
Cc:        freebsd-fs@freebsd.org
Subject:   Re: Mounting a filesystem on a HAST provider without HAST
Message-ID:  <5479E91F.6020809@yellowspace.net>
In-Reply-To: <20141129123130.GA21946@gmail.com>
References:  <AANLkTim5FRJkf_S0aSV74S=JY%2Bg1DBZLhjYW7X9C0MkP@mail.gmail.com> <5477B7AF.5020802@yellowspace.net> <54785AA1.10107@yellowspace.net> <20141129123130.GA21946@gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 29.11.14 13:31, Mykola Golub wrote:

> You can obtain the offset by running `hastctl dump' command (localcnt
> field).
>
> If you still want to calulate it yourself, see how hastctl calculates
> hr_localoff in sbin/hastctl/hastctl.c:create_one() with the help of
> sbin/hastd/metadata.c:activemap_calc_ondisk_size(). In short, you need
> to calculate number of extents (mediasize / extentsize) and reserve a
> bit for every extent in the map, rounding up to the sector size.

Thanks a lot for both pointers! hastctl dump will do perfectly well for 
now, it can easilly be wrapped in a local shell script.

Greetings and Regards,

Lorenzo




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5479E91F.6020809>