Fully Qualified Domain Name (FQDN) ?

I have some confusion about the /etc/hosts and /etc/hostname files. Yep, I'm new to both linux and apache. I followed the linode setup guide, but I think I missed something. First, when I restart apache I get an error:

apache2: aprsockaddrinfo_get() failed for snake

apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName

Second, how do I create a Fully Qualified Domain Name (FQDN)? The examples I've looked at seem to have many different formats such as www.domain.com, mail.domain.com, host.domain.com, something.domain.com. How do you know what to put in for the first part (????.domain.com)?

Third, does the name of my linode under Linode Manager make any difference?

My /etc/hostname file

snake

My /etc/hosts file

127.0.0.1          localhost
74.XXX.XXX.XX      snake.myDomain1.com      myDomain1
74.XXX.XXX.XX      snake.myDomain2.com      myDomain2

3 Replies

OK the first part ???.domain.com can be whatever you like, I personally name mine after greek gods (yeah sad I know).

If you like snake then yours would be snake.domain.com

To set it, ssh to your server as root and type

hostname snake.domain.com

Also you can edit your apache httpd.conf and add the line

ServerName snake.domain.com

near the top.

You should then go to the linode manager, network tab, and set your reverse dns to snake.domain.com

@eekeek:

How do you know what to put in for the first part (????.domain.com)?
It's up to you what you name your computer. Think of something. Or name it "linoderocks". :D

[Edit: In other words, use the name of the computer. You seem to have picked "snake", so, yeah.]

@eekeek:

Third, does the name of my linode under Linode Manager make any difference?
No.

Awesome guys - Thanks for the input! It all seems to be working fine now. :D

Reply

Please enter an answer
Tips:

You can mention users to notify them: @username

You can use Markdown to format your question. For more examples see the Markdown Cheatsheet.

> I’m a blockquote.

I’m a blockquote.

[I'm a link] (https://www.google.com)

I'm a link

**I am bold** I am bold

*I am italicized* I am italicized

Community Code of Conduct