[Virtualmin AMI on EC2] FQDN Problem

7 posts / 0 new
Last post
#1 Fri, 01/14/2011 - 05:51
simp

[Virtualmin AMI on EC2] FQDN Problem

Hi:-

Just trying to set up the EC2 AMI and am having a problem with the FQDN.

The default is localhost.localdomain.

Leaving it at this, Apache falls over and cannot restart, with the error:- apr_sockaddr_info_get ... failed Could not reliably determine the server's fully qualified domain name...

Putting in a FQDN in Webmin > Networking > Network Configuration, I get the error: Could not reliably determine the server's fully qualified domain name...

For FQDN, I am trying the server name host.mydomain.com, as well as the amazon public DNS hostname...

I'm sure this is something simple, but I'm a bit stumped.

I have been running Virtualmin on a VPS for two years now, with no problems - so there appears to be something different here...

Hope you can help.

Thanks,

Simp

Fri, 01/14/2011 - 08:40
andreychek

Hrm, I'm surprised you're seeing problems with Apache starting up. However, one place you might start is to edit your Apache config, and add a "ServerName" entry. Then, if it can't determine your FQDN, it should fall back to whatever you set in ServerName.

You could also try setting an FQDN for your hostname on the command line, by running this command:

hostname your.fqdn.tld

You'd also want to make sure your server's hostname exists in /etc/hosts.

-Eric

Fri, 01/14/2011 - 08:45
andreychek

Hrm, I'm surprised you're seeing problems with Apache starting up. However, one place you might start is to edit your Apache config, and add a "ServerName" entry. Then, if it can't determine your FQDN, it should fall back to whatever you set in ServerName.

You could also try setting an FQDN for your hostname on the command line, by running this command:

hostname your.fqdn.tld

You'd also want to make sure your server's hostname exists in /etc/hosts.

-Eric

Fri, 01/14/2011 - 09:08
simp

Hi Eric:-

I ran the command line hostname directive - and I double checked /etc/hosts - this reads:-

127.0.0.1 localhost host.domain.com

Which is correct, no?

Entering hostname in the terminal returns the correct host name.

I edited the ServerName line httpd.conf to read host.domain.com:80 - but now I just get the error:- Starting httpd: [FAILED]

Any ideas? I'm stumped... Is this an EC2 thing, perhaps?

Thanks!

Fri, 01/14/2011 - 09:16
andreychek

Howdy,

Well, your /etc/hosts should be more like:

127.0.0.1 localhost
you.servers.ip your_servers_fqdn
Fri, 01/14/2011 - 09:18
andreychek

Oh, also, if Apache is just silently failing like that when you start it up, you may want to take a peek at the Apache error logs in /var/log... they may list the specific error that's causing it to not start.

-Eric

Fri, 01/14/2011 - 09:52
simp

Thanks Eric - have looked at everything there - still drawing a blank - will retrace my steps again...

That's the nice thing about ec2 - you can just respawn and try again...

Topic locked