So, you have a zpool provided by an iscsi LUN which is tight on space, and you’ve done all the tidying you can think of.. what do you do next? Well if you’re lucky, you have space to expand the iscsi LUN and then make it available to your zpool.
First – find the LUN that holds the zpool using zpool status <poolname>
# zpool status zonepool pool: zonepool state: ONLINE scan: none requested config: NAME STATE READ WRITE CKSUM zonepool ONLINE 0 0 0 c0t600144F0A22997000000574BFAA90004d0 ONLINE 0 0 0 errors: No known data errors
Note the lun identifier, starting with c0, ending with ‘d0’
Locate the LUN on your storage appliance. If you are on a ZFS appliance there is a really handy script in Oracle Support Document 1921605.1 Otherwise you’ll have to use the tools supplied with your storage array or your eyes 😉
So, I’ve located my lun on my ZFS appliance by matching the LUN identifier and then I need to change the LUN size..
shares> select sc1-myfs shares sc1-myfs> shares sc1-myfs> select zoneshares_zonepool shares sc1-myfs/zoneshares_zonepool> get lunguid lunguid = 600144F0A22997000000574BFAA90004 shares sc1-myfs/zoneshares_zonepool> set volsize=500G volsize = 500G (uncommitted) shares sc1-myfs/zoneshares_zonepool> commit
Now I just need to get my zpool to expand into the available space on the lun
# zpool online -e zonepool c0t600144F0A22997000000574BFAA90004d0
And now we’re done