How to start more than 1 virtual server on any Linux distro?
Linux - NewbieThis Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place!
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
How to start more than 1 virtual server on any Linux distro?
hi,
I am newbie in Linux world. I have fedora 9. I have installed one virtual server and have default www directory. So when I start my virtual server(/www/bin/apachectl start), it start perfectly, on the same when i am going start my default server which is located at /var/www it won't start. I have to stop my previous virtual server and then I can start my default one.
So question is 1. In one pc we only start one virtual server or we can run several virtual servers on one pc at the same time ?
I am newbie in Linux world. I have fedora 9. I have installed one virtual server and have default www directory. So when I start my virtual server(/www/bin/apachectl start), it start perfectly, on the same when i am going start my default server which is located at /var/www it won't start. I have to stop my previous virtual server and then I can start my default one.
So question is 1. In one pc we only start one virtual server or we can run several virtual servers on one pc at the same time ?
Please help...
Regards,
Suraj Nayak
Sorry. This is not the place to ask the question. This thread was started by jeremy for specific purpose.
Start your own thread for your issue in a relevant forum.
Yes, that can be done using virtual hosts. And you will only have one 'instance' of apache running.
From my apache webserver
Code:
#
# Use name-based virtual hosting.
#
NameVirtualHost *:80
# catch-all
<VirtualHost *:80>
ServerAdmin me@mydomain
DocumentRoot /srv/httpd/htdocs
ServerName btd-techweb02
</VirtualHost>
# site 1
<VirtualHost *:80>
ServerAdmin me@mydomain
DocumentRoot /home/wim/www/site1/web
ServerName site1.btd-techweb02
ErrorLog /var/log/httpd/error_log
CustomLog /var/log/httpd/access_log common
#WimS
# this is required to prevent message 403 "Forbidden"
<Directory "/home/wim/www/site1/web">
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
# site2
<VirtualHost *:80>
ServerAdmin me@mydomain
DocumentRoot /home/wim/www/site2/web
ServerName site2.btd-techweb02
ErrorLog /var/log/httpd/error_log
CustomLog /var/log/httpd/access_log common
#WimS
# this is required to prevent message 403 "Forbidden"
<Directory "/home/wim/www/site2/web">
Order allow,deny
Allow from all
</Directory>
</VirtualHost>
Where you place this in Fedora, I don't know as I don't use Fedora. In Slackware it's in a separate file that is included in httpd.conf. You can also dump it in httpd.conf.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.