nixCraft Linux Forum

nixCraft

Linux / UNIX Tech Support Forum

Suggestion for High Traffic WebServer Setup

This is a discussion on Suggestion for High Traffic WebServer Setup within the CentOS / RHEL / Fedora forums, part of the Linux Distribution category; Hello all, I need a suggestion for setup a server I have a php page of 40KB, that has to ...


Go Back   nixCraft Linux Forum > Linux Distribution > CentOS / RHEL / Fedora

Linux answers from nixCraft.


CentOS / RHEL / Fedora Discussion about Redhat Enterprise Linux or CentOS or Fedora Linux related problems.

Reply

 

LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 30-06-2009, 12:42 PM
kasimani's Avatar
Senior Member
User
 
Join Date: Jul 2006
Location: India, Delhi
OS: CentOS, RedHat, Fedora, Ubuntu
Posts: 151
Thanks: 3
Thanked 1 Time in 1 Post
Rep Power: 4
kasimani is on a distinguished road
Send a message via Yahoo to kasimani
Default [Solved] Suggestion for High Traffic WebServer Setup

Hello all,

I need a suggestion for setup a server

I have a php page of 40KB, that has to provide 1 Lakhs users simultaneously.
That is a online exam page.

So my question is, what configuration of server should be ?
I have 2 choices either can go for IBM server or SUN server... which one is better

What should be Bandwith for this task.

If i am missing here some other considerations that i should take care of that, pl. let me..


Thanks
Regards

Last edited by kasimani; 13-07-2009 at 01:56 PM.
Reply With Quote
  #2 (permalink)  
Old 30-06-2009, 10:11 PM
amitabh's Avatar
Contributors
User
 
Join Date: Jul 2008
Location: New Delhi
OS: FreeBSD
Posts: 99
Thanks: 0
Thanked 4 Times in 3 Posts
Rep Power: 4
amitabh has a spectacular aura about amitabh has a spectacular aura about amitabh has a spectacular aura about
Send a message via MSN to amitabh Send a message via Yahoo to amitabh Send a message via Skype™ to amitabh
Default

You need to be more descriptive in what exactly your setup is: i.e. your database server, number of queries per page etc... Also, it make more sense to have multiple server setup like one for DB, one for dynamic contents and the third for any static images, all connected internally through a second Gigabit NIC.
Reply With Quote
  #3 (permalink)  
Old 30-06-2009, 10:33 PM
nixcraft's Avatar
Never say die
User
 
Join Date: Jan 2005
Location: BIOS
OS: RHEL
Scripting language: Bash and Python
Posts: 2,710
Thanks: 11
Thanked 244 Times in 183 Posts
Rep Power: 10
nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute
Default

For 1 lacks user connection per sec you need cluster not a single IBM or Sun server will work. If I were you I will consider something as follows:

1) Load balancer in front of webserver nodes. It can be hardware based or software based using nginx or LVS or redhat cluster suite.

2) Dedicated database server with RAID-10 array with 8 or more disks.

3) Nodes - multiple nodes.

4) CDN if you use lots of JS, images etc.

As amitabh said provide more info.
__________________
Vivek Gite
Linux Evangelist
Be proud RHEL user, and let the world know about your enterprise choices! Join RedHat user group.
Always use CODE tags for posting system output and commands!
Do you run a Linux? Let's face it, you need help
Reply With Quote
The Following User Says Thank You to nixcraft For This Useful Post:
kasimani (13-07-2009)
  #4 (permalink)  
Old 02-07-2009, 11:01 AM
kasimani's Avatar
Senior Member
User
 
Join Date: Jul 2006
Location: India, Delhi
OS: CentOS, RedHat, Fedora, Ubuntu
Posts: 151
Thanks: 3
Thanked 1 Time in 1 Post
Rep Power: 4
kasimani is on a distinguished road
Send a message via Yahoo to kasimani
Default

Here are the details:

I have a website for registered users, This website is intended for Objective exams.
Now i want, let 1-1.5 Lakh users can login simultaneously and give exams, in sort, request to webserver will be about 2 Lakh per day.


I am going to use Mysql, but still hopping for good suggestion from ur side
OS would me CentOS


Now suggest me what sort of Hardware/Servers they needed and what should be bandwidth for all that.

That setup also require HA and Loadbalancing, firewall (All should be Hardware)
Reply With Quote
  #5 (permalink)  
Old 02-07-2009, 11:58 AM
nixcraft's Avatar
Never say die
User
 
Join Date: Jan 2005
Location: BIOS
OS: RHEL
Scripting language: Bash and Python
Posts: 2,710
Thanks: 11
Thanked 244 Times in 183 Posts
Rep Power: 10
nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute nixcraft has a reputation beyond repute
Default

Since we not seen your source code and have no idea about code size. You need to perform a few test on your own. Usually, you need
  1. Hardware or software based load balancer to spread load among the web server node.
  2. Do not use Apache with PHP, it will kill performance. Use lighttpd or nginx with FastCGI. You need 3-4 web server nodes, each with 4-8GB RAM, RAID-1 SAS, Xeon CPU etc.
  3. Get master / slave MySQL server setup with RAID10x15k SAS disks. Get lots of RAM 12-16GB. Cache mysql queries using memcached.
  4. Install xcache on all php boxes.
  5. Tune Linux TCP/IP stack.
Bandwidth usage depends upon various factors such as
  1. Does web site uses lots of java script, images and css code?
  2. Does web site uses flash?
__________________
Vivek Gite
Linux Evangelist
Be proud RHEL user, and let the world know about your enterprise choices! Join RedHat user group.
Always use CODE tags for posting system output and commands!
Do you run a Linux? Let's face it, you need help
Reply With Quote
  #6 (permalink)  
Old 06-07-2009, 11:44 AM
kasimani's Avatar
Senior Member
User
 
Join Date: Jul 2006
Location: India, Delhi
OS: CentOS, RedHat, Fedora, Ubuntu
Posts: 151
Thanks: 3
Thanked 1 Time in 1 Post
Rep Power: 4
kasimani is on a distinguished road
Send a message via Yahoo to kasimani
Default

hi

My site is gzipped, using memcache, using css, js, images

images comes from other server.

My question, how do i calculate the memory for Apache connections (for 1 lakh connection)

suppose my webpage without compression is 144 KB, and after gzipped, it goes 30KB.

Pl. tell me any formula to calculate the required RAM, CPU

Thanks in Adv.

Regards

Last edited by kasimani; 13-07-2009 at 01:56 PM.
Reply With Quote
  #7 (permalink)  
Old 06-07-2009, 12:17 PM
amitabh's Avatar
Contributors
User
 
Join Date: Jul 2008
Location: New Delhi
OS: FreeBSD
Posts: 99
Thanks: 0
Thanked 4 Times in 3 Posts
Rep Power: 4
amitabh has a spectacular aura about amitabh has a spectacular aura about amitabh has a spectacular aura about
Send a message via MSN to amitabh Send a message via Yahoo to amitabh Send a message via Skype™ to amitabh
Default

There is not set formula to calculate the required RAM CPU etc. It is based on more on experience with handling server administration. What you can do though is use Apache Bench to simulate multiple connections to see how your server behaves under heavy load.
Reply With Quote
Reply

Tags
apache , cisco load balance , cluster , internet load balancer , lvs , nginx , web servers


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)

 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads

Thread Thread Starter Forum Replies Last Post
How can I setup/configure DNS, Sendmail, and Apache webserver using DHCP to allow out ibolah Computer Networking and Internet/broadband 0 20-02-2009 12:35 PM
Need suggestion for installing Solaris in my system vaibhav.kanchan Solaris/OpenSolaris 1 26-07-2008 11:03 AM
iptables for webserver asim.mcp Networking, Firewalls and Security 7 12-08-2007 12:05 PM
need suggestion!!! jayesh Computer Networking and Internet/broadband 3 27-06-2006 01:08 AM
Hacker high school documentation monk The Hangout 1 26-04-2005 12:19 PM


All times are GMT +5.5. The time now is 03:35 PM.


Powered by vBulletin® Version 3.8.5 - Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.3.2
©2005-2010 nixCraft. All rights reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38