Étiquette : lvs

  • Grow a zpool ZFS On Linux + LVM

    I’m actually heavily testing ZFS On Linux. As hard drive, I’m using a volume from LVM (named data-zfs2) :

     NAME STATE READ WRITE CKSUM
     backup ONLINE 0 0 0
       data-zfs2 ONLINE 0 0 0

     

    But my volume is now nearly full :

    [10:31:23]root@direct:~$ zpool list
    NAME SIZE ALLOC FREE CAP DEDUP HEALTH ALTROOT
    backup 599G 584G 15.2G 97% 1.00x ONLINE -

    So first, let’s tell ZFS to auto-expand :

    zpool set autoexpand=on backup

    And now, extend the volume underneath :

    lvextend -L +100G data/zfs2
    LV VG Attr LSize Pool Origin Data% Meta% Move Log Cpy%Sync Convert
    zfs2 data -wi-ao---- 700.00g

    Let’s see what zpool is now reporting :

    zpool list
    NAME SIZE ALLOC FREE CAP DEDUP HEALTH ALTROOT
    backup 599G 584G 15.2G 97% 1.00x ONLINE -

    Not good 🙁

    You need to « refresh » the device :

    zpool online backup data-zfs2

    And now :

    zpool list
    NAME SIZE ALLOC FREE CAP DEDUP HEALTH ALTROOT
    backup 699G 584G 115G 83% 1.00x ONLINE -

    Voilà !

  • LVM attributes

    When you type ‘lvs’ on Linux, you get a list of logical volume system with their attributse as a single letter : /// LV VG Attr LSize Origin Snap% Move Log Copy% Convert lv_hdd hdd -wi-a- 232.00g /// We’ll explain all attr fields in this post.
    (suite…)