Omnios does not have a dns server package in their official repo. In their 'unofficial' ms.omniti.repo they do, but that one lacks the SMF xml script.
The easiest way to get a running bind server is enabling the uulm.mawi repo:
# pkg set-publisher -g http://scott.mathematik.uni-ulm.de/release uulm.mawi
Verify the repo is enabled:
# pkg publisher PUBLISHER TYPE STATUS URI omnios origin online http://pkg.omniti.com/omnios/release/ uulm.mawi origin online http://scott.mathematik.uni-ulm.de/release/
Then we can install it with:
# pkg install service/network/dns/bind
This will install bind but it is not enabled by default. Fortunately this is very easy. First find the service name:
# svcs -a | grep dns disabled 13:21:43 svc:/network/dns/install:default disabled 13:21:43 svc:/network/dns/client:default disabled 13:21:45 svc:/network/dns/multicast:default disabled 14:29:16 svc:/network/dns/server:default
The last one looks like the right one, so we enable it with
# svcadm enable dns/server # svcs -a | grep dns disabled 13:21:43 svc:/network/dns/install:default disabled 13:21:43 svc:/network/dns/client:default disabled 13:21:45 svc:/network/dns/multicast:default online 14:30:50 svc:/network/dns/server:default
So, that was easy. But chances are it will not do much, because we have no /etc/named.conf and consequently, no bind configuration.
This bind package has a file /etc/named.conf.sample, so we copy that to /etc/named.conf and modify it to our liking. For a caching server the only change you probably need to do is adapt the allow-recursion parameter to match your network.
Finally if you want (and probably do want) to control bind using rndc, generate a key using rndc-confgen -a. This will generate the /etc/rndc.key file. After this, just restart bind again:
# svcadm disable dns/server # svcadm enable dns/server
From another host query the dns service, it should work.