Thanks again for the earlier reply.
I have done a some more work on the server, but I still haven't got it right. So here is some more background:
I have a subdomain on an external dynamic DNS service of the form:
I do not own example.com, and the subdomain my-example is provided by the DNS service as part of my subscription. (I have several of them).
The my-example.example.com points to my WAN IP address and is directed to my web server by local IP address and port 80 redirection in my router.
This is for background only as all this is working on the existing server.
2. Default website (Working)
On the Apache2 web server I wish to use the root-data directory /var/www as the default website.
The web server is registered in my DNS Server in the form:
and is thus accessible from my LAN as:
As there in only one local domain on my LAN, I do not need to fully qualify the address.
2. First Virtual Host
The data for the my-example web site is in a subdirectory /var/www/my-example and thus at the moment can be accessed as:
This is working, but I need to set up access as:
I have tried several different arrangements for the entry in /etc/apache2/sites-available/my-example but none so far have worked properly.
My ports.conf file contains:
and some other lines relevant to SSL port 443.
In /etc/apache2/conf.d I have a file ServerName.conf which contains the line:
Also in /etc/apache2/conf.d I have a file VirtualHosts.conf which contains the line:
So far, Apache2 starts and stops with neither warning nor error, and the default website and my-example site are available as stated in 2. and 3. above.
In /etc/apache2/sites_available I have a file my-example which contains the following lines:
ServerAdmin [email address]
CustomLog /var/www/my-example/logs/access.log combined
When I link this file into /etc/apache2/sites-enabled and start Apache2 I receive the error:
"Starting web server Apache2 [date] [error] (EA1 2) Name or service not known: Could not resolve host name my-example -- ignoring!
Action 'start' failed."
There is no error.log in /var/www/my-example/log but there is an error in /var/log/apache2/error.log:
"[Date] [notice] caught SIGTERM, shutting down.
[Date] [notice] seg fault or similar nasty error detected in the parent process"
Perhaps I am missing an obvious error?
Sorry about the long post but I thought you'd appreciate as many details as possible.
Thanks in advance,