Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

On a fresh install of ubuntu 12.10, I installed the lamp stack via: sudo apt-get install lamp-server^, and phpmyadmin. Then I sudo chmod 777 /var/www to be able to openly copy and change files in the www folder. I have two issues:

The first is, when I restart the Apache server I get:

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

The second when I goto localhost in my browser I get the "It Works!", but when I go to localhost/newsite I get a 403 error.

How can I resolve this?

share|improve this question
    
You need to configure apache to serve your newsite. Read any apache howto that explains /etc/apache2/sites-available and /etc/apache2/sites-enabled. –  terdon Mar 29 '13 at 21:01
    
Is newsite a subdirectory of /var/www? If so, does www-data have read access to newsite and its contents? –  Dennis Mar 29 '13 at 21:29
add comment

2 Answers

In your httpd.conf add:

ServerName localhost

Then restart Apache.

share|improve this answer
add comment

You may wish to configure you host name as well. This would be done via the hostname command and altering /etc/hosts and /etc/hostname (for ubuntu, other distros are different). For more details see: http://askubuntu.com/questions/87665/how-do-i-change-the-hostname-without-a-restart

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.