On Sun, Sep 18, 2016 at 9:55 AM, Richard Skelton <skelt...@btconnect.com> wrote:
> Hi, > I would like to create a zfs file system in my zone and create snapshots > like I would in a global zone. > In the zone I see:- > root@fred5:/root# zfs list > NAME USED AVAIL REFER MOUNTPOINT > rpool 38.6G 93.2G 23.5K /rpool > rpool/zones 2.94G 93.2G 19K /zones > rpool/zones/fred5 1.85G 93.2G 19K /zones/fred5 > rpool/zones/fred5/ROOT 1.85G 93.2G 19K legacy > rpool/zones/fred5/ROOT/zbe 1.85G 93.2G 1.85G legacy > root@fred5:/root# ls /zones/fred5 > ls: cannot access '/zones/fred5': No such file or directory > So the way it works is this: the dataset rpool/zones/fred5/ROOT is delegated to the zone. Anything above that is associated with the global zone; that dataset or below is associated with the local zone. You get to see all the parents in the hierarchy, with their mountpoints in their own context, which is a bit confusing. > root@fred5:/root# zpool list > NAME SIZE ALLOC FREE EXPANDSZ FRAG CAP DEDUP HEALTH ALTROOT > rpool 136G 30.3G 106G - 19% 22% 1.00x ONLINE - > root@fred5:/root# > > Before I install any optional software I would like to create a zfs file > system and mount it on /opt in the zone. > How can I do this? > In this case, it could be: zfs create -o mountpoint=/opt rpool/zones/fred5/ROOT/opt However, I wouldn't normally do this. If I was creating datasets for use by a zone, I would create a separate dataset such as rpool/fred5 in the global zone (with mountpoint set to none), use 'add dataset' in the zone configuration to delegate that dataset to the zone, and use that to create my own filesystems in the zone. The aim being to separate my own data from that managed by the operating system. (Although the same issue of conflicts arises with the use of /opt, which the OS might think it has control of. Creating /opt/local or /opt/company-name one level down might be a better choice.) -- -Peter Tribble http://www.petertribble.co.uk/ - http://ptribble.blogspot.com/
_______________________________________________ OmniOS-discuss mailing list OmniOS-discuss@lists.omniti.com http://lists.omniti.com/mailman/listinfo/omnios-discuss