I am really new to servers and apache however I’ve been struggling for a while now and maybe somebody can help me.
So I have set up an apache server that works (if I use the IP address I can reach the website and it works properly). I have linked the url with the nameservers and my virtual host file looks like (located in /etc/apache2/sites-available/mysite)
<VirtualHost 12.34.56.78:80>
ServerAdmin admin@mysite1.com
ServerName mysite1.com
ServerAlias www.mysite1.com
DocumentRoot /srv/www/mysite1.com/public_html/
ErrorLog /srv/www/mysite1.com/logs/error.log
CustomLog /srv/www/mysite1.com/logs/access.log combined
</VirtualHost>
The weirdest thing is it worked yesterday and in the meantime I only installed an FTP server … Any ideas of what I might have done wrong?
Thank you
If this is on Debian, you also need to link your config file in
/etc/apache2/sites-availableto/etc/apache2/sites-enabled, to let the config scripts know that the file is not only available, but also enabled.Another thing might want to check is
NameVirtualHost 12.34.56.78:80directive somewhere in Apache config (or, optionallyNameVirtualHost *:80).