Kirk Fraser
Posts: 50
Joined: Thu Feb 13, 2014 6:52 am

How to serve multiple websites?

Wed May 27, 2015 1:32 pm

A Pi website www.freetom.info works but how do I set it to serve 3 others too? Do I need LAMP instead of Apache 2? I was able to serve all 4 plus sub-sites on an old WinXP running WAMP. Enabling the sites individually didn't work so I replaced /etc/apache2/sites-available default file with one that addresses all four virtual hosts like WAMP uses and ran a2ensite on it but only the first two entries for ServerAlias www.freetom.info and freetom.info work. The others don't. I'll try using the same ServerName for the others and see if that helps.

FYI the Pi does .html (text) and .jpg (photo) ok but does not do well serving .pdf and other larger files during work hours but seems ok during early morning hours like 6:00AM. I wonder why?

Here's a tip I learned that should help beginners. On the Pi Desktop keep a file of "sudo code". Saves lots of time when human memory fails after looking up code on tutor sites.

Thanks.

Return to “Troubleshooting”