2

I'm updating my mail servers' rDNS and I think I have it all figured out except for one thing.

When I installed my OS (Debian Etch), the installer asked me to enter the "domain name".

  1. Is the "domain name" updated by using the hostname command?
  2. If so, which config file(s) are updated when using the hostname command?
  3. If not, how do I change my servers' domain name?

My current /etc/hosts:

127.0.0.1       localhost
67.228.178.164  mrspock.example-old.com      mrspock

My current /etc/hostname:

mrspock

$ hostname -f

mrspock.example-old.com

I need to update hostname -f to be mrspock.example-new.com.

2 Answers 2

2

Answering my own question.

It appears (according to this and this) that you only need to update /etc/hosts to change the domain name specified during install on a Debian system:

127.0.0.1       localhost
67.228.178.164  mrspock.example-new.com      mrspock

That should do it. Please correct me if I'm wrong, but I can't find any other info on changing the domain name. Also, hostname -f produces "mrspock.example-new.com" after updating /etc/hosts, as expected.

0

Is the "domain name" updated by using the hostname command?

If so, which config file(s) are updated when using the hostname command?

No! hostname Command update /etc/hostname

how do I change my servers' domain name?

you can change your domainname by:

# domainname <NEWNAME>

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .