Jump to content

Webmin Virtual Host Setup Issue


Recommended Posts

Hey all.

 

I am running Ubuntu 10.04 and the newest version of Wemin.

 

Per the tutorials I have found, I have created the Virtual Host via Webmin and it created a file in the following location :: /etc/apache2/sites-available/maskedarmory.com.conf

 

The directives inside read as follows:

 

DocumentRoot "/home/maskedarmory"

ServerName maskedarmory.com

<Directory "/home/maskedarmory">

allow from all

Options +Indexes

</Directory>

ServerAlias *.maskedarmory.com

 

Now, whenever I hit http://www.maskedarmory.com, it is pulling up my blank index.html page that is located in my var/www folder.

 

I cannot figure out why it is not pulling from the directory that I have specified above in the new Virtual Host.

 

If anyone can shed some light on the issue, it would be greatly appreciated.

 

Thanks.

 

 

Link to comment
https://forums.phpfreaks.com/topic/209067-webmin-virtual-host-setup-issue/
Share on other sites

Hello thorpe.

 

Yes there is.  There is one in the sites-enabled and then the sites-available as well.  The sites-enabled maskedarmory.com.conf has a little link icon on the top of it within Zend Studio.

 

Obviously, I have restarted apache since I made the virtual host changes.  It just still wants to pull from the var/www document root.

 

Thanks.

Then I would say that Webmin has broken Debian's Apache configuration.

 

Take a look in your main httpd.conf file and make sure that somewhere within it (it should be near the bottom) is a line that includes your vhosts.

 

It should look something like....

 

Include /etc/apache2/sites-enabled/*

Well, the etc/apache2/httpd.conf has nothing in it.  Could that be an issue?

 

When you set up a virtual server, it gives you the option between creating a virtual host file or putting it in your httpd file.

 

The etc/apache2/apache2.conf has "Include /etc/apache2/sites-enabled/" at the very end of it.

Any recommendations as to another web administration platform for Ubuntu 10.04 LTS that is free that you have success with?

 

I don't bother with any of these admin panels. They play around with the configurations too much for me.

 

I find it allot easier to use a terminal and the tools provided, and if I need to, I script certain parts.

I'm not sure where there's any tutorial specific to Debian/Ubuntu but the process is simple. Create your vhost file and place it within /etc/apache2/sites-available.

 

Then execute the a2ensite command, or simply make a link from /etc/apache2/sites-available/<vhost>.conf to /etc/apache2/sites-enabled/<vhost>.conf

 

Make sure all directories defined within your vhost file exist (including any log file directories), then restart Apache...

 

sudo /etc/init.d/apache2 restart

 

As you can see its much the same setup as what you have now.

 

You should take a look at the Apache error logs for a hint on what the trouble might be.

It is simply looking for everything in the var/www folder:

 

[Wed Jul 28 07:05:02 2010] [error] [client 61.69.168.46] File does not exist: /var/www/wow-armory-profile-611.html, referer: http://vbforums.mmobay.net/wow-usa-accounts-auctions-buy-sell/393025-80-warrior-fury-arms-pvp-5-6k-6k-gs-spectral-tiger-500-obo.html

[Wed Jul 28 07:05:59 2010] [error] [client 61.69.168.46] File does not exist: /var/www/wow-armory-profile-611.html, referer: http://vbforums.mmobay.net/wow-usa-accounts-auctions-buy-sell/393025-80-warrior-fury-arms-pvp-5-6k-6k-gs-spectral-tiger-500-obo.html

[Wed Jul 28 07:13:49 2010] [error] [client 64.83.202.180] File does not exist: /var/www/wow-armory-profile-388.html, referer: http://vbforums.mmobay.net/wow-usa-accounts-auctions-buy-sell/390694-80-shaman-7k-achieves-realm-first-title-%24175-great-vanity.html

 

That is my Apache2 error log is showing.

Well, good God almighty.  I figured it out.  I went ahead and picked my own location for the virtual host file and made it the httpd.conf file in the Apache2 directory.  Once I did that, I restarted the server.  Got a Internal 500 Error.  Then went to my error log to find that I had an invalid command 'RewriteEngine', which was there because I did not have mod_rewrite installed.

 

It all works now :)

 

Thanks for your guidance thorpe.

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.