Ask HN: How much traffic to expect if your project hits HN front page?
When other people have had their project show up on the front page, is there any pattern of how many concurrent users you topped out at, and how long most of them stuck around?
When other people have had their project show up on the front page, is there any pattern of how many concurrent users you topped out at, and how long most of them stuck around?
root@debian:/var/log/lighttpd/pdf.cryto.net# cat access.log | grep "GET / " | grep "news.ycombinator.com" | wc -l
19387
That said, the Hacker News post led to a bunch of other places writing about it a day or so later, the most notable of which was Gigazine: root@debian:/var/log/lighttpd/pdf.cryto.net# cat access.log | grep "GET / " | grep "gigazine.net" | wc -l
544
But most of their traffic came from the document viewer they embedded in their article: root@debian:/var/log/lighttpd/pdf.cryto.net# cat access.log | grep "GET /d/C8gHjDOxTLdunq1a/embed" | grep "gigazine.net" | wc -l
41609
And this is what the bandwidth usage looked like during those few days: root@debian:/var/log/lighttpd/pdf.cryto.net# vnstat -d
eth0 / daily
day rx | tx | total | avg. rate
------------------------+-------------+-------------+---------------
[...]
07/13/14 767.19 MiB | 949.01 MiB | 1.68 GiB | 162.72 kbit/s
07/14/14 1.27 GiB | 9.13 GiB | 10.40 GiB | 1.01 Mbit/s
07/15/14 7.05 GiB | 106.73 GiB | 113.79 GiB | 11.05 Mbit/s
07/16/14 2.89 GiB | 48.73 GiB | 51.62 GiB | 5.01 Mbit/s
07/17/14 2.22 GiB | 24.21 GiB | 26.43 GiB | 2.57 Mbit/s
07/18/14 1.23 GiB | 11.90 GiB | 13.13 GiB | 1.27 Mbit/s
07/19/14 1.31 GiB | 11.88 GiB | 13.19 GiB | 1.28 Mbit/s
07/20/14 1.38 GiB | 7.73 GiB | 9.11 GiB | 884.50 kbit/s
07/21/14 1.44 GiB | 9.55 GiB | 10.99 GiB | 1.07 Mbit/s
[...]
If I recall correctly, my HTTPd was hit with some 50-100 reqs/sec total (for static + dynamic). It didn't really have any issues with it, despite running on a cheap VPS with 512MB of RAM, on a non-optimal stack (lighttpd + PHP + MySQL).I've noticed a significant increase of recurring traffic since (it still hovers at about 5-15GB of traffic a day as opposed to the 2GB before, and there's a steady stream of uploads).
As long as you don't run something obscenely heavy like WordPress or Joomla, and you don't use Apache, you'll probably be fine.
I got a DDoS-mitigated VPS in Seattle. I believe the plan I have is normally $15, but I used a coupon code so I pay $9.30 recurring.
I can definitely recommend them - however, I should add that their DDoS mitigation appears to suffer from the same issues as all other cheap VPS DDoS mitigation proxies; speeds are not always reliable, and connections occasionally break halfway through. That's not a problem with RamNode though, but with the mitigation provider (CNServers in this case) and/or proxy setup - their own connectivity is rock solid.
Some other hosts I can recommend in a similar vein are RAM Host (http://ramhost.us/) and VPS-Forge (http://vps-forge.com/), in case you want to set up a redundant system of sorts. I've hosted with both for years, and they're both rock solid and very helpful as well. (Relatively) small operations like RamNode, but very reliable.
The only real 'optimization' was this classic one:
server.max-fds = 2048
If you forget that, you're going to have a very bad time when you get hit by a serious traffic surge :)The full configuration is here: https://gist.github.com/joepie91/e5bd63710b5910d2287a
It's really just a mostly standard config, some things pieced together. PHP is configured in on-demand mode, though - iirc, the default PHP configuration that ships with lighttpd on Debian is not.
I had 7500 unique visitors from HN including the traffic coming from linkbots that re-serve HN links.
With a single node.js (express) app on an EC2 medium instance and I was fine. I got about 10% conversion rate. It was a game with a signup page that required you to register first.
The single instance held up the static content and the app itself for a while. In hindsight I should have used an nginx reverse proxy for the homepage.
--EDIT-- here is the post: https://news.ycombinator.com/item?id=7364927
--EDIT2-- changed conversion rate typo from 1% to 10%
About 750 people signed up to play and there were about 500 games played (a game needs exactly 2 players).
The homepage stayed up the whole time. The stuff that got hurt was some actual gameplay due to an exception that was getting thrown, and I hotfixed.
I'm encouraged by your metrics of about 750 people and about 500 games - I think I could probably afford enough compute power to support that for a limited amount of time.
Never had any trouble serving it (my own code, LAMP, on Amazon micro instance). programmer.reddit.com is a little lighter. Ancillary traffic (other sites) from a front page post might add 10% or so over time.
Almost sure that it means at least one hit within the last 5 minutes.
From saturday to monday: 80,935 unique visits with peaks of 600 simultaneous people on site. Out of those 81K, 24,661 came from HN. The average time spent on site was 2:11. No real pattern, things started going viral as soon as the article hit the front page (which took a couple of hours). Things died off very quickly after 3 days of intense load.
Now I had never expected that type of load... In fact my blog is hosted on the cheapest shared hosting service NearlyFreeSpeech. I want to mention that they held the charge perfectly. I wrote a quick article about it with more numbers: http://www.nicolasbize.com/blog/and-the-best-shared-hosting-...
Most people just opened the page and closed it within ten seconds. The second largest group had the page opened for about one minute before closing. Please note the landing page for ngProgress[1] is very simple though and has almost no engagement except demo for the library.
link: https://www.machete.io/board/view/seed_db_funding_rounds/157...
If you want to track visits from HN, MAKE SURE YOU ENABLE HTTPS BY DEFAULT AND LINK TO AN HTTPS LINK. It is in the http spec that no referrer info is passes from an https site (like HN) to an http site.
One last bit - we are hosted on a small Azure instance, we used loader.io to test what kind of a load we could handle and it shit out pretty quickly. We implemented some output caching and it handled the HN flood just fine (200-300 concurrent users).
https://github.com/entaroadun/hnpickup/wiki/Hacker-News-Pick...
Here are multiple screen shots of the google web traffic analytics interface:
http://hnpickup.appspot.com/hnpickup_web_app_statistics_snap...
I got about 6000 hits in an hour the first time and 10,000 the second time.
WP-SuperCache coped admirably in both cases. The mod_rewrite caching was enough to cope with HN. (I sent the developer, Donncha O Caoimh, £10 with gratitude!)
But what really made the server cry: being on HN led directly to being on Reddit, where the second popular post got 80,000 hits in a day. In this case I had to put WP SuperCache into direct-cache mode. Then it was fine.
(And also, incidentally, 42 article comments and counting, without a single nasty/sarky/snarky one.)
The same article has since received 500 Facebook likes and was tweeted around 360 times.
https://news.ycombinator.com/item?id=7075537 | 334 points
http://statcounter.com/p9177631/summary/daily-rpu-labels-bar...
So for an app you could probably say 10 downloads per upvote.
Deleted comment