I am trying to set up a good web-development system on one of my home computers. I do not have home internet access. I almost exclusively use XAMPP for Linux as my server "stack", especially since it can all be installed from one file (Bitnami installers ROCK! :rock: ).
I want to try to simulate a server environment somewhat similar to a web-hosting server (which means multiple domains, website, etc. hosted on one machine).
I am very well versed in the Apache config files and howto's of them. I am also very familiar with the role of the local "hosts." file, and its role in being the first step in resolving domain names to IP address before any of the online DNS's are queried.
It seems that I can not access any of the created virtual domains on my machine, but instead see the web browser try to search for it online (which results in a "Not Found" error). I have concluded, by process of elimination, that it is not from the browser (FireFox), not from XAMPP (this works well on other distros without headache). This problem of not honoring my hosts file, and not locally resolving the virtual domains to their assigned IP addresses on my machine is common on SolydX versions 8 and 9. Most other other distros I have played with, seem to not have this problem (even with exactly the SAME settings in the hosts file - and - in Apache's config files).
If I can not get virtual domains to work, and be addressable with SolydX, this reduces the usability of the operating system for my web-design projects, AND learning about how web-servers work. (Projects like these, are how I teach myself these technical skills.)
My sample hosts file:
Code: Select all
#<ip-address> <hostname.domain.org> <hostname>
#127.0.0.1 localhost.localdomain.org localhost
# The following lines are desirable for IPv6 capable hosts
::1 localhost ip6-localhost ip6-loopback
and an example Apache "vhosts.conf" file:
Code: Select all
# Virtual Hosts
# Required modules: mod_log_config
# If you want to maintain multiple domains/hostnames on your
# machine you can setup VirtualHost containers for them. Most configurations
# use only name-based virtual hosts so the server doesn't need to worry about
# IP addresses. This is indicated by the asterisks in the directives below.
# Please see the documentation at
# for further details before you try to setup virtual hosts.
# You may use the command line option '-S' to verify your virtual host
# VirtualHost example:
# Almost any Apache directive may go into a VirtualHost container.
# The first VirtualHost section is used for all requests that do not
# match a ServerName or ServerAlias in any <VirtualHost> block.
CustomLog "logs/access.log" common
CustomLog "/home/web-host1/logs/access.log" common
CustomLog "/home/web-host2/logs/access.log" common
* * *
Though the IP addresses resolve to the pretended domain names (as evidenced by looking at the PHPINFO results when accessing these addresses by IP address), the domain names will simply not resolve to the IP addresses, and are not accessible.
I do not want to be reliant on accessing the other "virtual sites" by having to type in their IP addresses in the browser's address bar, instead of their assigned virtual domain names.
I have found this only to be a problem with SolydX, and not any of the other Debian Linux distros I have played with.
I have also not found anything online (via Google or otherwise) that addresses this problem with SolydX? ? ?
What system setting(s)/configuration(s) do I need to change, in order to get virtual domain names to work as it should, like it normally does on other distros (operating systems, and such)?