Moving GELI to an oversized provider

fluffles.net bsd at fluffles.net
Fri Sep 19 05:10:45 UTC 2008


Pete wrote:
> In order to avoid having to rewrite all data I readded a GEOM label,
> placing it at the very last sector (but leaving the old one in place).
> I then 'geli restore':ed the GELI metadata to the newly created label,
> so that the end of the disk looks like:
>
> sector -1: new GEOM label
> sector -2: copy of old GELI metadata
> ...
> sector -10: old GEOM label
> sector -11: old GELI metadata
>   

This would leave you with:
1) tasting a geom label on the last sector
2) a geom label device is created with -2 as its last sector
3) geli gets detected on last sector of geom label device
4) old labels are not detected

This should work without problems, though i would suggest transferring
the metadata while the relevant kernel modules are unloaded.

Only when you create more 'nested' geom layers like GNOP so eventually
you will hit sector -10 on the disk, will you get into trouble. If
you're worried about that, why not just blank those sectors using dd? be
sure to get the oseek parameter correct, however ;-)
Might not be a bad idea to backup the last X sectors of your disks just
in case you make a mistake.

Kind regards,
Veronica


More information about the freebsd-geom mailing list