0
0
Fork 0
zblog/content/post/72.md

1.8 KiB

+++ title = "How to use sysidcfg for zone deployment" date = "2011-10-28T13:41:53+00:00" author = "Gibheer" draft = false +++

This is mostly for myself that I can remember how to use the least documented feature of Solaris and openindiana - the sysidcfg files.

These files help deploying new zones faster, as you don't have to configure them by hand afterwards. But what is the syntax and how can you use them?

Here is an example file

name_service=NONE
# name_service=DNS {domain_name=<your_domain> name_server=<your_dns_server>}
nfs4_domain=dynamic
timezone=Europe/Stockholm
terminal=xterms
root_password=<crypted_password>
security_policy=NONE
network_interface=<interface1> {primary hostname=<hostname> default_route=<route_ip> ip_address=<if_ip> netmask=<if_netmask> protocol_ipv6=yes}
network_interface=<interface2> {hostname=<hostname> ip_address=<if_ip> netmask=<if_netmask> protocol_ipv6=yes default_route=NONE}`

The most important thing first: you don't need system_locale after openindiana 151 anymore. If you have it in your config, even with C, delete it or else the setup will not work!

If you don't have a dns record for your zone yet, set the @name_service@ to NONE. If you have already a record set, use the commented syntax.

The next interesting setting is root_password. Here you don't input the password in cleartext but crypted. I wrote a little script to generate this string. You can find the code here.

The network_interface part is pretty easy, if you take these lines as a dummy. If you have only one interface, you can name the first interface PRIMARY. That way, you have a bit less to write.

That's all so far. I will update this post, when I have figured out, what to fill into nfs4_domain and security_policy.