On Fri, 22 Jan 2010 12:57:09 +0100, Frank Batschulat (Home) 
<frank.batschu...@sun.com> wrote:

> Hiya, I observed that zone datasets are mounted even though no zones are 
> running.
>
> this strikes me like a bug ? aren't they supposed to be mounted only when the 
> zone boots ?
>
> example from build 130:
>
> osoldev.root./export/home/batschul.=> zoneadm list -cp
> 0:global:running:/::ipkg:shared
> -:zone2:installed:/tank/zones/zone2:8b538910-6026-4342-b342-e7c69c2c14e8:ipkg:shared
>
> looks whats actually mounted right now:
>
> osoldev.batschul./export/home/batschul.=> mount -v|grep zone
> tank/zones on /tank/zones type zfs 
> read/write/setuid/devices/nonbmand/exec/xattr/atime/dev=21000e on Fri Jan 22 
> 09:02:17 2010
> tank/zones/zone2 on /tank/zones/zone2 type zfs 
> read/write/setuid/devices/nonbmand/exec/xattr/atime/dev=21000f on Fri Jan 22 
> 09:02:17 2010
> tank/zones/zone2/ROOT/zbe on /tank/zones/zone2/root type zfs 
> read/write/setuid/devices/nonbmand/exec/xattr/atime/dev=210010 on Fri Jan 22 
> 09:02:22 2010
>
> df confirms:
>
> osoldev.root./export/home/batschul.=> df -lkah
> Filesystem             size   used  avail capacity  Mounted on
>
> tank/zones/zone2       228G    24K   203G     1%    /tank/zones/zone2
> tank/zones/zone2/ROOT/zbe
>                        228G   511M   203G     1%    /tank/zones/zone2/root
>
> osoldev.root./export/home/batschul.=> zfs list -t all
> NAME                                             USED  AVAIL  REFER  
> MOUNTPOINT
>
> tank/zones/zone2                                 511M   203G    24K  
> /tank/zones/zone2
> tank/zones/zone2/ROOT                            511M   203G    21K  legacy
> tank/zones/zone2/ROOT/zbe                        511M   203G   511M  legacy
>
> inspecting the 'canmount' zfs property gives a hint:
>
> osoldev.root./export/home/batschul.=> zfs get canmount tank/zones/zone2
> NAME              PROPERTY  VALUE     SOURCE
> tank/zones/zone2  canmount  on        default
> osoldev.root./export/home/batschul.=> zfs get canmount tank/zones/zone2/ROOT
> NAME                   PROPERTY  VALUE     SOURCE
> tank/zones/zone2/ROOT  canmount  on        default
> osoldev.root./export/home/batschul.=> zfs get canmount 
> tank/zones/zone2/ROOT/zbe
> NAME                       PROPERTY  VALUE     SOURCE
> tank/zones/zone2/ROOT/zbe  canmount  noauto    local
>
> so the 'zonepath' dataset has 'canmount=on' and is thus mounted
> by zfs mount -a, shouldn't that be 'canmount=noauto' ?
>
> the 'zonepath/ROOT' dataset has the same.
>
> even more interesting is that the 'zonepath/ROOT/zbe' apparently
> has the proper 'canmount=noauto' - yet it is mounted as well after boot.
>
> am I missing something obvious ?

for the 'zonepath/ROOT' dataset it's also interesting that 'canmount' is set to 
'on'
as the real systems /ROOT does have it turned off:

osoldev.batschul./export/home/batschul.=> pfexec zfs get canmount
NAME                                            PROPERTY  VALUE     SOURCE
rpool                                           canmount  on        default
rpool/ROOT                                      canmount  off       local
rpool/ROOT/opensolaris-129                      canmount  noauto    local
rpool/ROOT/opensolaris-130                      canmount  noauto    local
rpool/ROOT/opensolaris-...@install              canmount  -         -
rpool/ROOT/opensolaris-...@2009-12-25-08:57:20  canmount  -         -

fwiw, there exists a releated bug to LiveUpdgrade that it should not set 
'canmount' to 'on' in the new BE for the /ROOT dataset:

6747122 lucreate should not set canmount to on for zfs root dataset

---
frankB

_______________________________________________
zones-discuss mailing list
zones-discuss@opensolaris.org

Reply via email to