Can't setup a basic site on Ubuntu 10.04(LTS)

I am trying to setup a site where i can simply test it by getting it up and running with no contest at all but i am getting Unable to connect: from Firefox.

I have Linode on Ubuntu 10.04(LTS) setup, booted and running fine. After logging to Putty i managed to setup my hostname and FQDN by commands

echo "plato" > /etc/hostname

hostname -F /etc/hostname

127.0.0.1 localhost.localdomain localhost

12.34.56.78 plato.example.com plato

I replaced plato with the name of my host and i replaced example.com with the name of domain added in dns manager as my domain zone

After this i moved on to

Set up a LAMP Server on Ubuntu 10.04 (Lucid) guide and followed instructions from there

After typing 2 test commands it seems hostname and fqdn are set properly

I created /etc/apache2/sites-available/example.com and edited it to reflect the domain(Site) i am trying to enable, according to the details provided

ServerAdmin webmaster@example.com

ServerName example.com

ServerAlias www.example.com

DocumentRoot /srv/www/example.com/public_html/

ErrorLog /srv/www/example.com/logs/error.log

CustomLog /srv/www/example.com/logs/access.log combined

After that i followed the rest of the guide and tried to launch my site in Firefox(Firefox can't establish a connection to the server at….)

I also tried to create empty index.html in /srv/www/example.com/public_html/ dir that i created during the guide… Still cant connect.

Also after testing DNS servers with http://www.dnswatch.info/ my site normally returns all 5 name servers that i added in my domain provider cpanel yesterday.

So i really have no idea what am i doing wrong here?

2 Replies

1. Is Apache running?

/etc/init.d/apache2 restart

(While you're at it, also make sure to enable the newly created site using the a2ensite command.)

2. Did you add A records in your DNS, pointing both your domain and the "www" subdomain to your Linode's IP address?

thank you!

/etc/init.d/apache2 restart did the trick.

At first i realized i made error while setting up data in but after i corrected it, it still didnt work …

i just repeated lamp tutorial and since it only mentioned /etc/init.d/apache2 RELOAD that didnt fix it.

But after trying with RESTART everything seems to function perfect, thanks again

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