Find the answer to your Linux question:
Results 1 to 3 of 3
Hello, 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 ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    Feb 2013
    Posts
    1

    Domain Name showing nothing with ~>domainname


    Hello,
    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
    ~>domainname
    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.

    Thanks,

    -Curt

  2. #2
    Just Joined!
    Join Date
    Sep 2012
    Location
    Nashville, TN
    Posts
    98
    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
    Code:
    [root@devapp1 ~]# cat /etc/sysconfig/network
    NETWORKING=yes
    NETWORKING_IPV6=no
    HOSTNAME=devapp1.bsdtux.local
    NISDOMAIN=bsdtux.local
    [root@devapp1 ~]#

  3. #3
    Just Joined!
    Join Date
    Nov 2011
    Posts
    8
    Hi,

    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.

    e.g.

    test:~ # domainname -d
    bogus.com

    test:~ # domainname -f
    test.bogus.com

  4. $spacer_open
    $spacer_close

Posting Permissions

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