[OmniOS-discuss] New updates for LX Zones for OmniOS - zonecfg(1M) networking

Dan McDonald danmcd at omniti.com
Thu Sep 1 22:18:57 UTC 2016


Aka. "A tale of two LX zonecfgs".

I've updated the io-lx-public repo

	https://github.com/danmcd/io-lx-public/

AND the IPS server for bloody+LX:

	http://pkg.omniti.com/omnios/LX/

to include the Joyent-style zonecfg(1M) method of LX zone network configuration.  For example, a worked LX zone before would have:

	# zonecfg -z lx0 export
	create -b
	set zonepath=/zones/lx0
	set brand=lx
	set autoboot=false
	set ip-type=exclusive
	add net
	set physical=lx0
	end
	add attr
	set name=kernel-version
	set type=string
	set value=2.6.32
	end
	#

But now, you can add attributes to pre-configure the LX zone's basic networking (changes prefixed with '+'):

 	# zonecfg -z lx0 export
	create -b
	set zonepath=/zones/lx0
	set brand=lx
	set autoboot=false
	set ip-type=exclusive
	add net
	set physical=lx0
+	add property (name=gateway,value="192.168.0.1")
+	add property (name=ips,value="192.168.0.69/24")
+	add property (name=primary,value="true")
	end
+	add attr
+	set name=dns-domain
+	set type=string
+	set value=example.com
+	end
+	add attr
+	set name=resolvers
+	set type=string
+	set value=192.168.0.1
+	end
	add attr
	set name=kernel-version
	set type=string
	set value=2.6.32
	end
	#

And your LX zone, thanks to the lxinit(1M) binary will do the right thing.

Update your LX test boxes to this, and see how it works.

Thanks,
Dan



More information about the OmniOS-discuss mailing list