Re: [newbie] Help requested getting Apache virtual servers going
On Tuesday 23 November 2004 01:10 pm, Todd Slater wrote: On Mon, Nov 22, 2004 at 11:17:32PM -0500, Bill Mudry wrote: Could someone help me find out why I cannot get some virtual hosts going on Apache. Bill, How about letting us know what happens when you try to access a virtual host (in the browser)? Any errors in /var/log/httpd/access_log or error_log? Todd Yes, also did you register the domain name in your local dns? Because you're using .com which is a real domain. Depends on your local dns, it will forward the query to the internet if it's not set as local. -- Fajar Priyanto | Reg'd Linux User #327841 | http://linux2.arinet.org 18:00:02 up 40 min, Mandrakelinux release 10.1 (Official) for i586 public key: https://www.arinet.org/fajar-pub.key Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com Join the Club : http://www.mandrakeclub.com
Re: [newbie] Help requested getting Apache virtual servers going
Bill Mudry wrote: Could someone help me find out why I cannot get some virtual hosts going on Apache. I know my Apache is running ok since I can access it via localhost. I am running Mandrake 10.0. It also responds with [ok] for apachectl start and stop. Could any of you give suggestions on how I can get some virtual hosts going. In particularly, I hope to be able to place virtual web hosts under a public_html directory within the home directories of accounts. I have followed instructions as I found in more than one manual or how-to but I cannot seem to bring up index.htm or index.html files I placed in public_html neither on the local machine or on another (win98) PC on my local net. Below is a copy of the Vhosts.conf file. It may be something in that file but since a lot of this was copied and adopted from working examples, I suspect it is some other problem. May permissions? Ownerships? If you are not interested in assisting, no use reading past this point. The Vhost.conf copy below is included just in case it helps debugging. With thanks in advance, Bill Mudry Mississauga, ON Bill, Please provide info about your server, internet connection and whether or not you want these Virtual Hosts to be publicly available from the Internet. Then we'll be able to help you. While you're at it, I strongly suggest that you install webmin from the site below. http://www.webmin.com/ In order to install it, you'll need to install 3 Perl components before downloading and installing webmin. I've noted the three components here; 1) perl-Authen-PAM 2) perl-CGI 3) perl-Net_SSLeay All three modules can be installed from the Mandrake Control Center, after which you can manually install webmin from the command line as your root user; rpm -ivh webmin-1.170-1.noarch.rpm (without the quotes) or, from Konqueror's file manager by clicking on it. I've found that it helps a lot to un-install any previously installed version of webmin before installing this new version, since it's gone through some major improvements. Use this command to uninstall your old version of webmin by opening a console/shell/terminal as root and typing (without the quotes); urpme webmin Enter and then delete the existing webmin configuration files for it; rm /usr/libexec/webmin Enter and answer Y to confirm. If you're willing to give this a shot, you'll be able to manage the web-server a lot easier from any other PC's web-browser, even if that PC is in another country or continent. Remember that you have to use an s in the URL - https://XXX.XXX.XXX.XXX:1;. Make a note of the fact that you have to use the IP Address of your server running webmin to access webmin, unless you're sitting in front of that server, in which case you can use; https://localhost:1; or you can use the domain name of the server if you've purchased a domain name from a registrar (dotcanuck.com, godaddy.com, etc.) https://domain-name-of-server.com:1; Once you've done that, you're ready to install VirtualMin which is an add-on component to Webmin from this link; http://www.webmin.com/index8.html This is where it gets a lot easier, by the way. VirtualMin will help you to quickly configure virtual hosts for as many sites as you want as well as provide easy FTP services for those web-sites, email services, etc. in one location. It will automatically detect the email server you're running (if you have one installed) and it will create the folders and user access permissions for those sites and the people who manage them. I had a quick look at your VHosts file and I can see where one of your problems is coming from. The type of Virtual host you're trying to configure isn't valid. Regardless of where the sites are located and/or which IP address their using, your server will see them as Fully Qualified Domain Names or actual live web-sites and that's where some of your problem is coming from. In order to use the domains you've specified, you're going to have to register them through a registrar and that's part of the problem. For example, the domain name of mikewalters.com is ALREADY REGISTERED BY SOMEONE ELSE! The domain name billmudry.com isn't registered at all. Those would be big problems! If you intend to refer to these sites in the way you've stated them in your VHosts file, and/or if you plan on making them public sites, you'll need to register them first. In case you've never done this before, here's where you need to start; 1) Contact your ISP and get a Static IP address for a DSL or ADSL Internet connection (nothing slower than this will work very well and the web-pages will take forever to load in a web-browser). 2) Ask your ISP to setup Reverse DNS for your primary email server so that other email servers and anti-spam systems won't reject authentic email coming from your server. 3) Once that's all done and working, contact a registrar and register the names you want, but remember that mikewalters.com has already
[newbie] Help requested getting Apache virtual servers going
Could someone help me find out why I cannot get some virtual hosts going on Apache. I know my Apache is running ok since I can access it via localhost. I am running Mandrake 10.0. It also responds with [ok] for apachectl start and stop. Could any of you give suggestions on how I can get some virtual hosts going. In particularly, I hope to be able to place virtual web hosts under a public_html directory within the home directories of accounts. I have followed instructions as I found in more than one manual or how-to but I cannot seem to bring up index.htm or index.html files I placed in public_html neither on the local machine or on another (win98) PC on my local net. Below is a copy of the Vhosts.conf file. It may be something in that file but since a lot of this was copied and adopted from working examples, I suspect it is some other problem. May permissions? Ownerships? If you are not interested in assisting, no use reading past this point. The Vhost.conf copy below is included just in case it helps debugging. With thanks in advance, Bill Mudry Mississauga, ON # Vhosts.conf #This is where we store the VirtualHosts configuration. # #Since Apache 1.3.19, we modified the setup to include some nice tricks: # #- We added the User and Group directives so VirtualHosts now work with # suexec directive. If set, Apache will run all cgi scripts under that # user and group (provided the uid and gid are 100 for security). The # directories and cgi files *must* belong to that user/group for the # feature to work #- We added the Setenv VLOG directive. This works in conjunction with # the CustomLog in common.conf. When Setenv VLOG is set, apache will # create a /var/log/httpd/VLOG--MM-ServerName.log instead of logging # to access_log. Use this instead of defining a special logfile for # each vhost, otherwise you eat up file descriptors. #- You can also specify a path for the VLOG for each Vhost, for example, # to place the logs in each user's directory. However, if you want to # use the file for accounting, place it in a directory owned by root, # otherwise the user will be able to erase it. #- I suggest only including the ErrorLog *only* if the vhost will use # cgi scripts. Again, it saves file descriptors! #- We added the Rewrite directives so vhosts will work with the # PERLPROXIED configuration # IP-based Virtual Hosts #VirtualHost 192.168.2.100 #User jmdault #Group jmdault #DocumentRoot /home/jmdault/public_html #ServerName test2.com #Setenv VLOG /home/jmdault/logs #ErrorLogs /home/jmdault/test2-error_log #RewriteEngine On #RewriteOptions inherit #/VirtualHost # Named VirtualHosts #NameVirtualHost 111.222.33.44 #VirtualHost 111.222.33.44 #ServerName www.domain.tld #ServerPath /domain #DocumentRoot /web/domain #/VirtualHost ## NameVirtualHost 192.168.2.200 VirtualHost 192.168.2.200 ServerName billmudry.com ServerPath /home/bill DocumentRoot /home/bill/public_html #ErrorLogs /home/bill/error_log.bill /VirtualHost ## NameVirtualHost 192.168.2.201 VirtualHost 192.168.2.201 ServerName mikewalters.com ServerPath /home/mike DocumentRoot /home/mike/public_html TransferLog logs/access.mike ErrorLog logs/error.mike /VirtualHost ## NameVirtualHost 192.168.2.200 VirtualHost * ServerName www.billmudry.com ServerPath /home/bill ServerAdmin [EMAIL PROTECTED] ServerAlias billmudry.com DocumentRoot/home/bill/public_html #ErrorLogs /home/bill/error_log.bill Directory / OptionsFollowSymLinks AllowOverride None /Directory Directory /home/bill/public_html OptionsIndexes FollowSymLinks AllowOverride None Order allow,deny Allow from all /Directory DirectoryIndex index.html AccessFileName .htaccess LogLevelwarn ScriptAlias /cgi-bin/ /home/bill/cgi-bin/ Directory /home/bill/cgi-bin/ AllowOverride None OptionsNone Order allow,deny Allow from all /Directory /VirtualHost Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com Join the Club : http://www.mandrakeclub.com
Re: [newbie] Help requested getting Apache virtual servers going
On Mon, Nov 22, 2004 at 11:17:32PM -0500, Bill Mudry wrote: Could someone help me find out why I cannot get some virtual hosts going on Apache. Bill, How about letting us know what happens when you try to access a virtual host (in the browser)? Any errors in /var/log/httpd/access_log or error_log? Todd Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com Join the Club : http://www.mandrakeclub.com