Hosting for huge traffic

3 million pageviews a month is only 100k a day, or close to 1 request a second. You don't need anything beefy, but it does go without saying to not use shared hosting. A weak VPS is fine.
 
Let's take a real life example. the porn tube site: xvideos.com
When I do a "dig a xvideos.com" in the terminal , they have multiple A records. There are 10 IP servers. This means that everytime a user visit xvideos.com, it prompts one of the 10 dedicated servers.
It is really simple. You build first a dedicated server and if it is not enough, you copy the content of your dedicated server on another server. and then if it is not enough another one and so one. Then, you just add a A record to your DNS zone. DNS will balance the load between your server automatically so that if you have 2 servers, they will take 50% of the load each. Then, your job would be to find how it works to mirror the wordpress installation over several servers if necessary.

Code:
; <<>> DiG 9.10.6 <<>> a xvideos.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 10310
;; flags: qr rd ra; QUERY: 1, ANSWER: 10, AUTHORITY: 0, ADDITIONAL: 1

;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags:; udp: 1460
;; QUESTION SECTION:
;xvideos.com.            IN    A

;; ANSWER SECTION:
xvideos.com.        39    IN    A    185.88.181.11
xvideos.com.        39    IN    A    185.88.181.4
xvideos.com.        39    IN    A    185.88.181.10
xvideos.com.        39    IN    A    185.88.181.9
xvideos.com.        39    IN    A    185.88.181.5
xvideos.com.        39    IN    A    185.88.181.2
xvideos.com.        39    IN    A    185.88.181.3
xvideos.com.        39    IN    A    185.88.181.6
xvideos.com.        39    IN    A    185.88.181.8
xvideos.com.        39    IN    A    185.88.181.7
 
Get a dedicated server with Litespeed on it (not apache) and you'll be able to handle everything easily. Litespeed makes a huge difference, I have peaks with 10k users online on my website and it does only load the cpu by 10%
 
I second the person who says you should use a load balancer. This would mean multiple servers. For my site what I plan on doing is running multiple VPS. The advantage with this over a single dedicated server is if the server goes down you have a second server located preferably in another location (another host) still running. With this configuration 1 has the load balencer (ngnix or haproxy) and the two other servers compliment each other so that one server does not get too much of a load at one time.

The only caveat is, if you are running a database, you will probably need to store your database on a separate server (perhaps the one running the load balencer or a fourth server).
 
Back
Top