New on LowEndTalk? Please Register and read our Community Rules.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.
All new Registrations are manually reviewed and approved, so a short delay after registration may occur before your account becomes active.

Comments
I'm a dinosaur iptables guy:
Or something like this (not tested this one):
Allow port's access from inside, block to everywhere else (aka outside).
Yes, speedtest mini was giving me approx ~900kb/sec from my server (kimsufi canada) and it was not stable (lags between 400-1200 kb/sec), so plex was slow even with lower bitrates. Changing domain, forcing ssl and using CDN in front of it (I use cloudflare full ssl) helped me max out my local speed, so I get better speeds thanks to routing I guess.
It actually does work with LG Smart TVs and PS3/4 over port 80. That's why you need both http and https custom URLs. Those clients don't handle https correctly, so if you have the http URL (you HAVE to specify port 80) they will use that instead. I've tested this extensively with every Plex client.
Make sure you have caching disabled. That can cause the type of bursts you're talking about.
Surely it's better to have it blast out into the cache then play back to the client from there.
Plex doesn't work well with caching due to how the transcoder works. You would think that caching would be a benefit but it's really not. It's caused nothing but headaches when I was trying to get it working.
This is so LowEnd that I love it.
For any normal non-cloudflare-free-plan CDN, you wouldn't want to put your personal videos on it because you'd be paying a ton to store and deliver.
But Cloudflare is free, and apparently has no storage limit for free users...so this is kind of a nice hack to get premium video delivery from your remote Plex.
No TOS is being violated...just a clever hack.
I did bypass cache on CloudFlare for the domain
plex.example.com/*, but I see the bursts again. I’ll see how it goes or if anything changes.Wouldn't that depend on if the clients actually require transcoding or not?
There doesn't appear to be any limit on traffic as far as I can tell. Time will tell.
http://imgur.com/a/GVVVS
Even if it does a direct play/stream caching still causes issues. As far as I know, Plex still utilizes a buffer and sends the files in chunks regardless if it's transcoding or not.
Did you disable proxy redirect and buffering in Nginx too?
proxy_redirect off; proxy_buffering off;Yes, I did. Playback is smooth for now, even with those bursts. Which apps/platforms had problems when you had caching enabled?
Web, Roku, FireTV, AppleTV, SmartTV, iOS, PS3/4, Xbox.
Could this just be due to not having an SSL that they trust? Seems like it wouldn't be so far out there that they wouldn't have updated their CA to include whatever Cloudflare uses.
I know that the PS4 has certificate trust issues, but the older Vizio TVs just don't support it and it crashes the app.
Here is my question, why?
Fully encrypted traffic, and thanks to CDNs increased speed.
It improves peering and streaming performance significantly for people that have poor peering or slower internet between Cloudflare and using Nginx.
But in reality it really won't..... As that isn't how Plex works. Plex will go around the CDN to the backend server for the files. That is unless you specifically setup Plex to use a domain name and setup nginx as a reverse proxy on the Plex host. Further, you would also at that point lose some functionality mostly in regards to how Plex knows how to stream to your device. This functionality determines how good the encoding needs to be for your device.
If you are having issues with Plex as it is the much better option is by going and changing direct play to off. You can do this by going to settings and turning off Allow Direct Streaming/Allow Direct Play. This will force all files to be converted, and generally save bandwidth. You can also tinker and bring down the quality level.
I tried using plex over a CDN a year ago and had to use Incapsula since Cloudflare at the time didn't offer websocket support. Then soon after Cloudflare added support.
Your CDN must support websockets (unless it has changed with what Plex requires).
I had contacted some people on the plex forums and eventually was able to get one of the methods to work. At the time, I was using Hetzner with Cloudflare and it didn't really add much to the speed differences and was a kind of intrusive method just to get the CDN working.
https://gist.github.com/Doonga/dc91f2c52f17c9931e269966dfcb956d
Now that I think of it, it might've never gone through the CDN but this is your only option sadly since the older ones were for making non-ssl Plex into SSL plex.
Traffic between CF and upstream plex is also encrypted. And It increased the speed for me. What's the issue here ? CF's CDN servers fetch faster than me, and copy to a location where I can stream faster.
I block 32400 plex port to outside from my plex server, and use this way. Works nicely on desktop app (Windows and macOS), web ui, and Android app. I can't say much about Samsung TV apps etc. since I don't own them.
And no, I don't have issues with Plex. My server is strong enough to transcode ~2 1080p movies simultaneously. As I've mentioned earlier, I'd suggest everyone to try speedtest mini client or a similar tool first to test their download speed between their server and their end. If it's slow, and you think it shouldn't and it's a result of bad peering, this CF/whateverCDN trick will help you out.
You don't lose ANY functionality using it this way. Honestly, there isn't a single downside to this configuration other than the time it takes you to set it up. It improves peering, which in turn can help people with crappy internet, and it also speeds up overall performance since Nginx is doing a lot of the work.
I mean... I have. I get far less performance out of Cloudflare. In my many previous tests, going directly to my servers were better. Though, I don't buy these super cheap servers with hosts that have terrible networks.
Just curious, which hosts do you use? I mean if you use them specifically for Plex and streaming.
I have used tons of hosts, and commonly the issue was CF was slower. The advantage always was free bandwidth, and the ability to scale if you had dozens of people downloading the same file.
It's also about far away locations. E.g: in my case, I live in eastern EU region, and my server is in Canada.
Yeah, in my case CloudFlare helps when streaming from Hetzner to EU and Canada, otherwise Hetzner to EU only is completely fine without CF.
Hey guys, thanks for all replies.
I just want say thank you for @arda by help me with the tutorial step by step for getting plex working behind cloudflare and another cdn solutions and for their patience with me.
I love this forum. You guys are great.
Thanks a lot.
I'm working on a project to deploy a multi-user docker based seedbox script. I use Traefik as the front end to a docker based plex and other scripts on the backend. Setting up this CDN was a snap..literally one line needed to be added to my docker run script and then the CloudFlare setup side of it.
I'm interested.