Altering the page running on the server IP

wdeboer

Verified User
Joined
Jul 16, 2005
Messages
40
Hello!

Anyone know how I can change the default pages of Apache through DirectAdmin? Because when I access the server by ID I am getting the default "Test Page for SSL/TLS-aware Apache"

See:
http://193.138.230.25

Because I think it looks stupid I just want it to show some default page, i.e. the pages available in /domains/default/ of the Administrator user admin.

Anyone know if this is possible?

Yours!
 
Yes it's possible. There are two ways to do it.
1. Modify the httpd.conf file chaning the DocumentRoot directive to the location you want to load the website from.

2. Modify the files in the existing DocumentRoot directory, which is usualy always /var/www/html
 
Well, when I alter the httpd.conf file wouldn't be altered each time I add a new user/website?

Would it be possible to make a symbolic link to the admins default directory?
 
Well, when I alter the httpd.conf file wouldn't be altered each time I add a new user/website?
The main httpd.conf (usually /etc/httpd/conf/httpd.conf) is never rewritten by DirectAdmin. Only the users httpd.conf files (/usr/local/directadmin/data/users/*/httpd.conf) are rewritten.

Would it be possible to make a symbolic link to the admins default directory?
You could make /var/www/html point to the admin's directory however you would have to move webmail and phpmyadmin from /var/www/html to the directory you pointed it to aswell. ;)
 
Well, now something odds is happening :) My server has five different IPs assigned to it, only the file I posted at /var/www/html/ only works for some IPs but now all.

Check it out:

http://193.138.230.25/ (not working)
http://193.138.230.26/ (upto *.*.*.29)

Same problems occurs at a different IP addres only the other way around, only works at one IPs and not on the other four.

Any idea why this could happen?
 
Last edited:
Most likely virtualhost misconfiguration. Comb through those in the main httpd.conf file and see what you find.
Or attach it and hopefully someone will have time to take a look first hand at it.
If you do that, please attach it don't paste it. Just makes things neater and easier to keep track of.
 
Aha, well I will have a look at it later today. Because I am bit scared to totally f----k up this brand new webserver of mine :)
 
Thankfully the risk of permanently ruining your entire installation/server by modifying the httpd.conf file is so remote I can't even think of it.
Make a backup of it, if the changes don't work troubleshoot it and if worse comes to worse, restore from the backup. Easy as eating lemon pie. Mmmm. :p
 
wdeboer said:
Well, now something odds is happening :) My server has five different IPs assigned to it, only the file I posted at /var/www/html/ only works for some IPs but now all.
With a properly configured DA server, files posted at /var/www/html should only work for the main server IP#.

Did you change something in the httpd.conf file?

If so, what?

Jeff
 
Back
Top