
Ask HN: Did your website get the HN/Reddit hug? What did you do? - 0x00000000
Just curious, for the typical HN&#x2F;Reddit traffic spike what does it take to survive? Interested in both raw numbers or broader strategies. If you shrugged it off no problem, what does your architecture look like? If not, what did you do afterwards if anything?
======
dangrossman
I had some blog posts on the front page a couple years ago. My blog is an
unmodified WordPress install on the smallest Linode (at the time, that was
512MB RAM). No caching plugins or CDN, every page was served live from the
database. Got >20K visits over the course of a few hours, 800+ active
concurrent visits according to live web stats. It didn't cause any problems,
load wasn't even high. All you need is a sane nginx/apache configuration.

------
brogrammer2019
My site [http://goalkicker.com/](http://goalkicker.com/) (Free Programming
Books) was featured front page on Reddit and HN last month; 2TB used within 24
hours, 150,000 unique IP addresses. No issues with hosting/downtime nor any
noticeable effect on performance nginx + php

Source:
[https://news.ycombinator.com/item?id=16186329](https://news.ycombinator.com/item?id=16186329)
and
[https://www.reddit.com/r/programming/comments/7rgz78/a_lot_o...](https://www.reddit.com/r/programming/comments/7rgz78/a_lot_of_free_pdfs_about_programming_from_stack/)

~~~
schappim
Your eBooks look great, what framework do you use for generating them? I see
you use "3-Heights(TM) PDF Optimization Shell 4.8.25.2 ([http://www.pdf-
tools.com)"](http://www.pdf-tools.com\)"), but what do you use to generate the
layout?

------
technion
I've had several blogs trend very well.

I built the site with Jekyll and run a single EC2 instance and never saw
double digit load averages.

I also ran a Facebook advertising campaign for this site[2] which is sitting
on S3 with Cloudfront in front. I've load tested that to over 2,000
connections per second, which I expect would exceed the most popular blogs.

If I was worried about bandwidth costs, I would use a $10 Cloudflare plan.

Every one of these "hug of death" discussions ends up tracing back to some
bloated Wordpress theme. I continue to be shocked at the way it still occurs.

[0] [https://lolware.net/2017/07/04/amp-
bloat.html](https://lolware.net/2017/07/04/amp-bloat.html) [1]
[https://lolware.net/2016/11/17/requesting_bank_login.html](https://lolware.net/2016/11/17/requesting_bank_login.html)
[2] [https://getcryptolocker.com](https://getcryptolocker.com)

------
BjoernKW
This blog post on my website was on the Hacker News front page for a few hours
and there were no problems at all:
[https://bjoernkw.com/2016/04/03/accounting-
in-2016/](https://bjoernkw.com/2016/04/03/accounting-in-2016/)

My website runs on WordPress with WP Super Cache, Autoptimize and a few
server-side as well as client-side optimizations. Nothing special though but
pretty standard measures. Caching is particularly helpful to make sure the
database gets hit as little as possible.

------
mslate
I avoid this problem entirely by keeping static content static--and hosted via
CDN.

The same approach goes for dynamic (database-backed content)--cache the ever-
loving shit out of it.

------
jjoe
I've had exposure to these hugs for a variety of websites. I'm not sure how it
started but people I had helped with traffic isues started referring others to
me.

Anyway I got a glimpse of a pattern in a lot of these sites. So decided to
build a tool that would help in these situations with a few tweaks depending
on the stack.

That's when I came up with Cachoid[0] as a way to get some provisioning
automation.

[0] [https://www.cachoid.com](https://www.cachoid.com)

------
ecesena
Can you share your stack? The answer really depends: static blog/website, put
it on github pages and you're good. AWS, build everything with autoscaling
groups, set min=max=what is needed, but still you can easily scale up/down
when needed. Etc.

~~~
brogrammer2019
Hi Ecesena! Done, see above :)

~~~
ecesena
I don't see _your_ arch. Anyway, I remain of my ideas of the autoscaling
groups for non-static content. For static, there seems to be plenty of
examples.

