Configuring DNS client in solaris 11

Configuring DNS client in solaris 11

Make sure DNS is turned off
# svcs -a|grep dns
disabled 15:14:09 svc:/network/dns/multicast:default
disabled 15:14:11 svc:/network/dns/server:default
disabled 16:16:33 svc:/network/dns/client:default
# svcs -a|grep switch
disabled 11:04:22 svc:/system/name-service/switch:default

Fix up or build resolv.conf and nsswitch.conf just like in the old days.
These files are no longer used but you can import from them
# vi /etc/resolv.conf
# vi /etc/nsswitch.conf

Values are now stored in the services facility. Lets import.
# nscfg import dns/client
# nscfg import name-service/switch

Turn it back on
# svcadm enable svc:/system/name-service/switch:default
# svcadm enable dns/client
# svcs -a|egrep -e "dns/client|switch"
online 11:05:43 svc:/system/name-service/switch:default
online 11:06:06 svc:/network/dns/client:default

Test it
# dig|grep 3416 IN A

Leave a Reply

Your email address will not be published. Required fields are marked *