Hey there,
I'm currently evaluating VirtualMin GPL for production environment and ran into a problem. Some details about my installation:
- m1.small instance in EC2 Singapore region
- Amazon Linux AMI (2012.09)
- Installed using install.sh
A few things I did that were out of the ordinary:
- Edited install.sh line 597 to download the 2012.03 'virtualmin-release-latest.noarch.rpm' instead
- In Post-Installation Wizard, I specified my (resolvable) hostname as primary nameserver, not sure if I should have used 'ns1.he.net' instead. All hosted Virtual Servers will have their DNS records hosted with dns.he.net
- Updated default server IP address to my elastic IP
- Unsure of the WebMin interface, I stopped the webmin service, manually formatted my instance store volume and additional 5GB EBS volume with XFS and mounted them as /home and /var respectively.
After rebooting, local disk space appeared ok so I proceeded to create a Virtual Server. This is where I ran into some problems (my test domain is globalcauseways.com).
- Installed phpMyAdmin script, but got a 404 at http://globalcauseways.com/phpmyadmin/
- Visiting http://globalcauseways.com/, I got an empty directory listing
- Uploaded a simple 'Hello World' index.html to '~/public_html/' but http://globalcauseways.com/ still shows the same empty directory listing. Visiting http://globalcauseways.com/index.html generated a 404.
- Uploaded another 'Hello World' index.html to '/var/www' with no change to the situation. Visiting the hostname's '/' & '/index.html' gave the same results as http://globalcauseways.com/.
I've not altered the httpd.conf and its corresponding VirtualHost entries for port 80 and 443 appears to be normal. I've attached them here:
- VirtualHost:80
- VirtualHost:443
Thanks in advance for your help and let me know if I should provide more info!
Cheers,
James
Hey there,
Just terminated the last instance and tried with ami-503c4702, Virtualmin GPL's AMI for Singapore to pretty much the same results, except the Apache default page shows instead of an empty directory listing.
I'm sure it's some pretty obvious setting I've overlooked. Any ideas?
Cheers, James
Howdy,
You may be seeing some sort of IP address mismatch, which can cause Apache to show the wrong website.
There's details on how to solve that here:
https://www.virtualmin.com/documentation/web/troubleshooting
Hey Eric,
Thanks for the link! Corrected my misconfiguration in System Settings > Virtualmin Configuration > Network settings to:
Pleased to report that httpd.conf looks good and my simple 'Hello World' loads as expected now. Thanks!
Cheers, James
Hi all,
Had a chance to go through my logs and /etc/httpd/conf/httpd.conf and found the problem. Hope this helps anyone else facing the issue described above.
For Ubuntu instances, the .conf file might differ (try looking for /etc/apache2/apache2.conf & /etc/apache2/sites-enabled/*).
This relates specifically to EC2 deployments, where there is an internal IP address and an Elastic IP. After installing VirtualMin and completing the 'Post-Installation Wizard', I went to System Settings > Virtualmin Configuration > Networking settings and replaced 'Default virtual server IP address' to my Elastic IP, which I believe caused the VirtualHost entries in httpd.conf to be written as :80 and :443.
To resolve the problem, replace Elastic IP with internal IP. I'm still trying to figure out where the Elastic IP should go and where the internal IP should be, will post back when I have it figured out. An official note on this would also be much appreciated! :)
Cheers, James
Places to check...
For External IP address, select the 2nd radio button type ur ISP (external) IP Address
Virtualmin -> System Settings -> Virtualmin Configurations ->
Default IP address for DNS records Select: select Other Options radio button & type you ISP IP Address
Virtualmin -> Server Configuration DSN Options -> check in Allowed sender IP addresses, you should have your internal and external IP address in there.
Virtualmin -> Server Configuration DSN Records -> should have all your nameserver and IP address in there. Good luck
Here is something else u can use to check if you server configuration is good: http://www.intodns.com/blablabla.com Just replace your domain name
Hey Marc,
Thanks for your reply! I've already resolved this issue with Eric's link to the Website Troubleshooter.
Your recommendation is much more detailed and while differing slightly from the guide:
Network interface for virtual addresses - This is automatically detected by Virtualmin during the configuration check, but could be detected incorrectly, if you have multiple physical interfaces, or your system is some virtualized system like a vserver or Zone or OpenVZ instance. You would typically want this to be the primary IP address of your server -- in most cases that is "eth0".
Default virtual server IP address - We recommend leaving this as it's default of "From Network Interface".
Default IP address for DNS records - If your server is behind a NAT router, this option should be set to "Automatically detect external address". Otherwise, you should leave it at the default of "Same as virtual server IP".
I believe both achieve the same goal of:
Your link to intoDNS is also a valuable resource, which I will definitely bookmark and use often.
Thanks again for your input!
Cheers, James
No problem jamesfu and glad you got ur problem solved