domainname command

Hey,

I've been on this for a while... can somebody explain to me what the domainname command really does. The man pages don't tell enough. And how can i have the domain name set so it will be the same all the time when the OS boots up.

for the DOMAIN could i set it in the /etc/sysconfig/network file? And if so would i tlook like this
DOMAINNAME=THE DOMAIN NAME HERE

The solaris manual page is a lot better than most at describing this command (some of the *BSD's I've seen give a terse two sentence description)...

And yes, something along the lines of
DOMAINNAME=foo.net
inside /etc/sysconfig/network should do the trick.

You may also need to specify the local domain name in /etc/resolv.conf

Cheers
ZB

perfect man, that looks as if it'll do the trick! thanks.

ummmmm i edited the /etc/sysconfig/network and added a domain name in there and when i type domainname it doesn't bring anything up. If i type
domainname mydomain.com
then it will work. Weird

I've got a practical test on tuesday so i'm trying to figure everything out haha. Does anybody know why this happens?