P
P
PlatinumArcade2012-08-21 15:07:18
Habraeffect
PlatinumArcade, 2012-08-21 15:07:18

Habraeffect: How to set up a VPS so that it can withstand?

I would like to know the approximate figures of the “habraeffect” and what are the general recommendations for preparing the server for peak loads? Maybe there are ready-made articles / figures somewhere?
System: Cent OS + Nginx (php-fpm) + MySQL + PHP.

Answer the question

In order to leave comments, you need to log in

8 answer(s)
V
VBart, 2012-08-21
@VBart

Habraeffect is a myth. About a couple of years ago I wrote an article and for the sake of interest I inserted into it a picture that I have on my own VDS for 500 rubles per month with freebsd and nginx. The article, along with the picture in the introduction, got on the main page and hung there for almost the entire weekday, until it went to the second page.
The peak request rate was approximately, if memory serves, just over a dozen requests per second. And these are not users following the link, but simply people who opened the main page of the habr. My VDS-ka is able to give this picture at a speed of 500-1000 req / sec.
IMHO, if this is not some really resource-intensive application, then only clumsy shit on some monstrous php-engine can die from such a load (which, by the way, is probably more than 90% of the Runet). So don't write clumsy monster shit in php and you won't have to configure anything.

A
Anton, 2012-08-21
@venticello

I recommend running the site through loadimpact.com first , you will immediately see how the site behaves with 1-50 competing requests, how much the response suffers because of this.

A
Alexey Akulovich, 2012-08-21
@AterCattus

On Habré there is a bunch of articles in the style of "How we survived the habraeffect" with graphs and numbers, plus there was a post on references to the picture in the post when it got to the main one. In general, everything is searched for on the same site.

M
Mikhail Osher, 2012-08-21
@miraage

Please note that it all depends on what kind of hardware you have.
And then how to set incorrect, relative to the system, settings of some innodb ... and without habraeffect you will cry :)

J
Jacob, 2012-08-21
@ksenobayt

My basic VPS on a hetzner for six euros withstood an announcement effect of 18k uniques in less than 12 hours.
For the exact number of requests, you need to go into the log archive, which is frankly too lazy to do, but about 45 gigabytes of traffic has been generated.
Most of the visitors came to Wordpress 3.1x with a custom skin and jQuery wagon in it, plus a forum on the third phpBB.
Nothing collapsed, nothing sank - about four hundred megabytes of memory were consumed, the stone was kept in the region of 40-45%.
Used a bunch of nginx+php5-fpm+percona (prebuilt packages from dotdeb) without particularly fine tuning.

R
redbutcold, 2012-08-21
@redbutcold

everything is very simple. caching.
under wordpress and drupal there are nginx configs using fastcgi_cache.
a bunch of caching modules.
and varnish is generally lovely. server will sleep...

V
Vlad Zhivotnev, 2012-08-22
@inkvizitor68sl

You just now asked something in the spirit of "how to earn a million a day without doing anything."
The correct answer in your case is to pick, tune, look for degradation and bottlenecks in your particular project, rewrite the code.
In general, there is absolutely nothing terrible in the habraeffect. Usually, it is experienced by any project configured according to any manual, if there is no bydlocode in it and the disk subsystem does not slow down the VDS. At least my different clients experienced it 20 times, I paid attention to this only by monitoring warnings about a slightly jumped statistics of food consumption on carcasses.

D
Dan, 2014-05-04
@golotyuk

1. Check the Mysql settings for optimal ones, in more detail: Optimal Mysql settings with ... there will be a web server in the queue (it is better to use nginx), make sure you configure it: Configuring nginx under load 4. For basic load checking, you can use ab from Apache On the topic, I recommend reading the growth stories of different projects : highscalability.com habrahabr.ru/hub/hi

Similar questions

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question