Find the answer to your Linux question:
Results 1 to 3 of 3
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1

    Domain Name showing nothing with ~>domainname

    I am stuck with this issue and am a newbie.
    I am running SUSE 11.
    In the Yast2 Network Settings application in the Hostname/DNS tab, I am saving the Hostname and Domain Name, but running
    still returns nothing.

    How can I set the local domain on my OS? Do I need to enable a protocol or something?

    I am running this on Win8 under VMWare 5.

    Any help would be very much appreciated. So far everything else with this OS has gone really well. If I get this worked out I can start spending more time at WORK doing Linux stuff.



  2. #2
    Linux Newbie
    Join Date
    Sep 2012
    Nashville, TN
    You should be able to edit the /etc/sysconfig/network and set the hostname name in there.

    Here is a sample from one of my vm lab servers
    [root@devapp1 ~]# cat /etc/sysconfig/network
    [root@devapp1 ~]#

  3. #3

    without switch "domainname" command sets domainname.

    Check help/man.

    domainname --help
    Usage: hostname [-v] {hostname|-F file} set hostname (from file)
    domainname [-v] {nisdomain|-F file} set NIS domainname (from file)
    hostname [-v] [-d|-f|-s|-a|-i|-y|-n] display formatted name
    hostname [-v] display hostname

    hostname -V|--version|-h|--help print info and exit

    dnsdomainname=hostname -d, {yp,nis,}domainname=hostname -y

    -s, --short short host name
    -a, --alias alias names
    -i, --ip-address addresses for the hostname
    -f, --fqdn, --long long host name (FQDN)
    -d, --domain DNS domain name
    -y, --yp, --nis NIS/YP domainname
    -F, --file read hostname or NIS domainname from given file

    This command can read or set the hostname or the NIS domainname. You can
    also read the DNS domain or the FQDN (fully qualified domain name).
    Unless you are using bind or NIS for host lookups you can change the
    FQDN (Fully Qualified Domain Name) and the DNS domain name (which is
    part of the FQDN) in the /etc/hosts file.


    test:~ # domainname -d

    test:~ # domainname -f

  4. $spacer_open

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts