For Solaris Zones, the method I use is the one devised by Menno Lageman (http://blogs.sun.com/menno). Mount the global zone's /etc/nodename using a read-only LOFS mount on /etc/chassis in the non-global zone. It automatically changes whenever the nodename of the global zone changes, whether it is because the name of the global zone is modified or because the zone is moved to another physical host using zoneadm detach/attach. Just do this:
# zonecfg -z zone
zonecfg:zone> add fs
zonecfg:zone:fs> set dir=/etc/chassis
zonecfg:zone:fs> set special=/etc/nodename
zonecfg:zone:fs> set type=lofs
zonecfg:zone:fs> add options ro
zonecfg:zone:fs> end
Taken from here:
http://blogs.sun.com/apatoki/entry/how_do_i_know_my
I did not try this yet, I have no appropriate Solaris box by hand. But that could be useful.
No comments:
Post a Comment