On 16/02/2012 05:54, albumns wrote:

> in fact, it doesn't work with command: hostname -f
> it said in terminal:
> hostname: Unknown host

I can confirm on SLES11 SP1 that hostname -f a) works, and b) works
correctly _provided_ /etc/hosts has the correct entry in the form

IP-Address Full-Qualified-Hostname Short-Hostname

With a default install (plus OES11) the entry for my host was

IP-Address Short-Hostname Short-Hostname

so whilst hostname correctly returned Short-Hostname, hostname -f also
returned Short-Hostname whilst hostname -d returned nothing. Editing the
/etc/hosts entry to append domain to first Short-HostName value "fixed"
the output of both hostname -f and hostname -d.

Novell/SUSE/NetIQ Knowledge Partner

Do you work with Novell technologies at a university, college or school?
If so, your campus could benefit from joining the Novell Technology
Transfer Partner (TTP) program. See novell.com/ttp for more details.