# [OmniOS-discuss] ZFS on iSCSI Target. OmniOS as Initiator

Scott LeFevre slefevre at indy.rr.com
Thu Feb 27 21:10:33 UTC 2014

- Previous message: [OmniOS-discuss] ZFS on iSCSI Target. OmniOS as Initiator
- Next message: [OmniOS-discuss] ZFS on iSCSI Target. OmniOS as Initiator
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

    As others have pointed out, setting autoexpand=on on the pool is the key
    to making use of any new space allocated to your drive.

    As a test, I created a 30GB drive and created a new pool.  I then
    expanded that drive to 50GB.  The size of the pool didn't change until I
    turned on autoexpand on the pool.  This was done in a VM and not with a
    iscsi target lun but the principle should apply the same.

    root at omnios1:~# zpool create tank0 /dev/rdsk/c1t2d0
    root at omnios1:~# zpool list
    NAME    SIZE  ALLOC   FREE  EXPANDSZ    CAP  DEDUP  HEALTH  ALTROOT
    rpool  15.9G  2.51G  13.4G         -    15%  1.00x  ONLINE  -
    tank0  29.8G   156K  29.7G         -     0%  1.00x  ONLINE  -
    root at omnios1:~# zpool get autoexpand tank0
    NAME   PROPERTY    VALUE   SOURCE
    tank0  autoexpand  off     default

    root at omnios1:~# prtvtoc /dev/rdsk/c1t2d0s0
    * /dev/rdsk/c1t2d0s0 partition map
    *
    * Dimensions:
    *     512 bytes/sector
    * 62914560 sectors
    * 62914493 accessible sectors
    *
    * Flags:
    *   1: unmountable
    *  10: read-only
    *
    * Unallocated space:
    *       First     Sector    Last
    *       Sector     Count    Sector
    *          34       222       255
    *
    *                          First     Sector    Last
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
           0      4    00        256  62897887  62898142
           8     11    00   62898143     16384  62914526

    ---
    Expanded /dev/rdsk/c1t2d0 to 50GB

    ---

    root at omnios1:~# zpool list
    NAME    SIZE  ALLOC   FREE  EXPANDSZ    CAP  DEDUP  HEALTH  ALTROOT
    rpool  15.9G  2.51G  13.4G         -    15%  1.00x  ONLINE  -
    tank0  29.8G   130K  29.7G       20G     0%  1.00x  ONLINE  -
    root at omnios1:~# zpool get autoexpand tank0
    NAME   PROPERTY    VALUE   SOURCE
    tank0  autoexpand  off     default

    root at omnios1:~# zpool set autoexpand=on tank0
    root at omnios1:~# zpool list
    NAME    SIZE  ALLOC   FREE  EXPANDSZ    CAP  DEDUP  HEALTH  ALTROOT
    rpool  15.9G  2.51G  13.4G         -    15%  1.00x  ONLINE  -
    tank0  49.8G   200K  49.7G         -     0%  1.00x  ONLINE  -

    root at omnios1:~# prtvtoc /dev/rdsk/c1t2d0
    * /dev/rdsk/c1t2d0 partition map
    *
    * Dimensions:
    *     512 bytes/sector
    * 104857600 sectors
    * 104857533 accessible sectors
    *
    * Flags:
    *   1: unmountable
    *  10: read-only
    *
    * Unallocated space:
    *       First     Sector    Last
    *       Sector     Count    Sector
    *          34       222       255
    *
    *                          First     Sector    Last
    * Partition  Tag  Flags    Sector     Count    Sector  Mount Directory
           0      4    00        256 104840927 104841182
           8     11    00  104841183     16384 104857566

    --
    Scott LeFevre

    On Thu, 2014-02-27 at 09:54 +0000, Svavar Örn Eysteinsson wrote:
    > Hello List.
    >
    >
    >
    > I'm experimenting with ZFS on a iSCSI target.
    > Currently I have a OmniOS server which is a iSCSI initiator to a iSCSI
    > target
    > located out on the public internet from my hosting provider.
    >
    >
    > As for now the iSCSI target is about 300GB which I have managed to
    > connect
    > and created a ZFS pool on the target.
    >
    >
    > Now for the questions, what would the scenario be if I asked my
    > provider
    > to extend (grow) the iSCSI target, and how will my ZFS OmniOS box see
    > the new size ? Do I need any to scrub the pool, or how to I grow my
    > pool
    > to the new size provided by my hosting provider ?
    >
    >
    > As before, now I have a 300GB ZFS pool on the iSCSI target.
    > Which I have mounted and everything seems to work fine.
    >
    >
    > Later the iSCSI target will be grown to 500GB. Are there anything
    > special work that needs to be done regarding growing the ZFS datapool
    > from 300GB to 500GB.
    > (those extra 200GB) ?
    >
    >
    >
    >
    > Thanks in advance people.
    >
    >
    > Best regards,
    >
    >
    > Svavar O - Reykjavik - Iceland
    >
    > _______________________________________________
    > OmniOS-discuss mailing list
    > OmniOS-discuss at lists.omniti.com
    > http://lists.omniti.com/mailman/listinfo/omnios-discuss
    -------------- next part --------------
    An HTML attachment was scrubbed...
    URL: <http://lists.omniti.com/pipermail/omnios-discuss/attachments/20140227/0a901960/attachment-0001.html>

- Previous message: [OmniOS-discuss] ZFS on iSCSI Target. OmniOS as Initiator
- Next message: [OmniOS-discuss] ZFS on iSCSI Target. OmniOS as Initiator
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

More information about the OmniOS-discuss mailing list