Exporting Solaris zone configurations


I have been using Solaris 10 zone technology for the past 4 - 5 months, and just recently came across the zonecfg(am) “export” option. This option allows you to export the configuration from a specific zone, which can be used to recreate zones, or as a template when adding additional zones (with some adjustments of course). The following example prints the zone configuration for a domain called “irc”:

$ zonecfg -z irc export

create -b
set zonepath=/export/home/zone_irc
set autoboot=false
add net
set address=192.168.1.4
set physical=hme0
end

This is super useful, and can make creating 1000s of zones a snap!

This article was posted by Matty on 2005-11-09 21:36:00 -0400 -0400