Setting up multiple apache servers
Does anyone know how to setup/configure multiple servers (running apache) to handle a single page. Like I don't know how many servers webdeveloper.com use, but could anyone tell me:
- How to setup them to handle a single url (how request could be distributed)?
- How to transfer data between those servers?
- Is it important to ensure that all data stored in each server are exactly the same? Like session, data?
Thank you so much for help.
Splitting the workload evenly between the two would be extremely difficult unless you have multiple static IPs and either a DNS server or DNS on one of your two web servers. However, if you have session data, I'm assuming you're using php/mysql. What you can do fairly easily, is to make one machine a web server and the other a mysql server. Then simply change your db-connect or mysql-connect or whatever your include is, from
mysql_connect(localhost, root, password)
You'll need to make a few changes in your firewall and security settings, but this way one machine will handle the site and web requests, while the other handles queries. The effectiveness of this depends on your site to a point. It'll come down to overall traffic vs. queries/db traffic. But it will help to split up the workload with minimal difficulty.
mysql_connect('local ip of sql server', root, password
Check for round robbin dns and set a remote server monitoring system to verify uptime if you set up such a system. It's a good idea to experiment on non production servers before going live. I presume data redundancy is what you're after/
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)