[SOLVED] apache server setup

Can anyone point me at relevant apache server setup instructions for jetson. I would like to setup a recursive html directory, eg public_html. I would also like cgi/php support.

I can find information but it does not match with the installation that I get on jetson.

You should be able to follow any Apache installation instructions for Ubuntu 14.04. It’s not depending at all on the HW platform you are running it on.

E.g. this looks decent:


This looks good. I have not got onto the later steps yet, I will try these. The bit that is not working is just basic sub folders. I have the server running and I see the startup html page from /var/www/html/. I tried to add a sub directory in that location, but it did not seem to work. I also looked up adding custom locations or enabling public_html folders but I canot find a match between the config file names and the apache on the jetson. (I don’t think its an issue with jetson, its the fact that I think its using the latest apache and the documentation is all out of date. I was hoping someone had worked through this and could help.) It could also be a noob issue with permissions, ownership or groups.

This page, for example, is confusing me as it does not match the file layout I have found. The first comment by “Pit” echos the issues I am having but offers no solution.

A normal user can’t write to /var/www, but this should work:

sudo mkdir /var/www/html

Apache reads the files as a user “www-data”, so you need to make sure it has read access to the files.

Give Read and eXecute rights (for directories x is need to “cd” to them) to All:

sudo chmod a+rx /var/www/html

And Read access to all to all files in that directory:

sudo chmod a+r /var/www/html/*

Many thanks, this was an insufficient user IQ error. Setting up the correct directories with the correct permissions worked. Also followed the instructions on the linked page above, sql is installed (not tested) and PHP shows the info page when accessed from a browser on another computer. The URL was to a sub directory of /var/www/html.

This is enough for what I need, I will abandon setup of the public_html for now. I am the only user so using /var/www/html/* will be fine.