Apache2 and ServerRoot directive in Ubuntu
I am a noob and I just installed Apache2 on Ubuntu 12.04 machine. When I read /etc/apache2/apache2-conf, I see that the ServerRoot directive is commented out. I did not understand this. Why one would comment out -- ServerRoot "/etc/apache2" -- directive? Is it not necessary or is it defined somewhere else?
In Ubuntu your install should be in /etc/apache2/. If everything is installed in /etc/apache2/ you could/should uncomment that line. It will run without you uncommenting, but should be grounded on the install directory as a reference.
There are many lines commented by default so that this works out of the box without much coaxing. You will need to go back through and adjust apache2.conf and possibly sites-enabled as well.
Your Docroot by default should be /var/www/
链接地址: http://www.djcxy.com/p/64210.html