CDN question – factor bandwidth

I am new to cdn but want an idea of bandwidth use so i can plan budgeting. I am starting a social network and want to use a CDN for static content and user photos. Let’s say in total i have 15 javascript files and 10 css files for my site. I assume these will be hosted on the cdn and downloaded on each user’s visit. Also user’s have photos, so let’s take each user uploads 200 photos at 100 KB each. There are 500,000 users. So 50,000,000 photos.

How much bandwidth will be used? The plans i see are like $30ish for 1 TB. Is that enough? Is there a chance i will need like 5 TB, 10 TB, etc?

Answer

Presumably your javascript files are static and run on the client right? CDNs typically won’t run active code on their boxes, purely static.

Anyway let’s do the maths;

500,000 x 100KB is 50GB of data – they won’t host that much but will happily cache it, so you need to host it on your origin server anyway.

As for bandwidth – well not everybody will download every image of course, so if you imaging that your 500k users will each download say no more than 100 images a day that gives us;

500,000 x 100 x 100KB – which is 5TB or 50Tb per day or 1.5Pb per month

Now users will cache images on their machines but things will become uncached and need redistributing, plus it should be quite bursty at the beginning so count on some large spikes every so often.

Hope this helps, quite curious what’s your social network’s unique selling point that you think will draw in 500k users by the way.

Attribution
Source : Link , Question Author : Mani , Answer Author : Chopper3

Leave a Comment