# File lib/specinfra/command/solaris/base/inventory.rb, line 13
    def get_domain
      # There is no sure way to get the hostname like on linux 
      # This code is somewhat resembiling the functionality 
      # of the dnsdomainname command. 
      # Assumes either /etc/hosts or DNS is properly configured. 
      %Q{getent hosts `uname -n` | } +
      %Q{nawk -v h=`uname -n` '{sub(h".", "", $2); if ($2 != h){ print $2 } else { exit 1 } }'}
    end