Bandwidth Spike on Origin Server

Hello! We just moved a lot of our sites to Cloudflare (~80% of our traffic). We were looking at our origin server stats, and noticed that we went from an average of 2TBs per month of bandwidth (for the entire server) to now almost 40TBs in just a couple of weeks (less than 100GBs per day on average, to around 300GBs per day), while the number of visits has remained the same on average.

Here are some things I think could be causing it (one site is on the business plan, the rest are on the free plan):

  • Each site has Always Online enabled
  • Each site has a Page Rule to Cache Everything

Since the Cache Everything rule is also causing Cloudflare to cache the HTML for the page (which is what we want to do), whenever a page is updated on a site (they use our CMS), a request is made to Cloudflare via the API to purge that page’s cache (by submitting a few variations of that page’s url). Sometimes a change is made that would effect other pages as well, and so a Purge Everything is submitted so that the changes are seen.

Separately, I’d love to not cache mp4/mp3, etc (per the ToS) but I’m not sure how to accomplish that within Cloudflare. Or would that have to be a setting in Apache?

To not violate ToS for media files, they would have to be on a subdomain that’s set to :grey:.

A Purge Everything, if your site has as much data as you’re saying, will certainly reset everything and drive up local bandwidth.

If there’s a way to feed a bunch of URLs to the API, that should certainly be better than Purge Everything.

1 Like

Understood, and thank you for responding, I’m just wondering:

1: Why bandwidth on the origin server would increase after moving to Cloudflare, rather than decrease
2: If I can’t move media files to a subdomain, is there a way to serve them so that we’re not violating ToS

Thanks!

Ah, I see. The spike was when you moved to Cloudflare. No idea why the difference. Were you using a different CDN before? Worst case is you were serving direct before Cloudflare, and now nothing is cached, so traffic should be the same. You’d have to check your analytics to see where that traffic is coming from.

If traffic is going through an :orange: hostname, then ToS applies.

This topic was automatically closed after 30 days. New replies are no longer allowed.