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
Caddy uses quite a bit more RAM, and nginx handles more concurrent requests: https://community.centminmod.com/threads/caddy-http-2-server-benchmarks.5170/#post-34367
If you're dealing with very high traffic, nginx is the best choice. For anything else, I think Caddy has the better feature set while also being easier to configure.
The only thing I'm missing in caddy is decent support for openVZ. Running it as a systemd service under an old kernel version (like openvz uses) is a real pain in the ass.
Yup when i did those linked benchmarks Caddy used 3x time more cpu resources + 2.5x times more memory than Centmin Mod Nginx for HTTP/2 HTTPS based h2load load tests for only ~33% the performance of Centmin Mod Nginx.
1 thread h2load stress test with higher loads at 1,000 concurrent users and 50,0000 requests
For Caddy 0.9 HTTP/2 port 448 = 3,751.71 req/s average
CentminMod.com Nginx 1.11.3 HTTP/2 h2load stress test cpu load peaked at 0.60 and 548MB total memory used
2 thread h2load stress test with higher loads at 1,000 concurrent users and 50,0000 requests
For Caddy 0.9 HTTP/2 port 448 = 3,942.75 req/s average
CentminMod.com Nginx 1.11.3 HTTP/2 h2load stress test cpu load peaked at 0.62 and 551MB total memory used
>
I'm wondering if they've made any changes to increase performance recently.
Not according to the changelog. But for 99% of sites, Caddy is fine, I really wouldn't worry too much, it's still pretty darn fast.
If you're looking for low-mem, lighttpd is an alternative. I haven't run it hard, but it is easy to setup for static hosting and fine for Wordpress, etc.
From the greatest post in the entire history of the Internet and all time before it:
https://lowendbox.com/blog/yes-you-can-run-18-static-sites-on-a-64mb-link-1-vps/
Last time i asked Matt (Caddy), he said focus is on features and getting that right and not performance yet. He's welcome to user contributions to Caddy code for performance but I am not a Go programmer. So if you are a Go programmer that might be something you should look at for contributing to Caddy
So priority is features over performance for Caddy right now. So pick the right tool (web server) for the job (your needs) As mentioned for low traffic sites Caddy should be fine - just keep in mind as traffic grows with Caddy you'd probably end up needing more cpu and memory resources than you would with Nginx right now in Caddy development cycle. System resource monitoring is important
For my Centmin Mod LEMP development, I am always evaluating and benchmarking web server performance for my own needs to see what I can integrate into Centmin Mod that adds value. So I evaluated Caddy as well as H2O - both HTTP/2 based web servers which suffer similar performance regressions (ie. increasing performance regressions as you add more HTTP headers to pages served over HTTPS) compared to more established Nginx web server.
Also had a brief look at Hiawatha as one of my users mentioned it in relation to slowhttptest tests comparison Nginx vs OpenLiteSpeed vs Apache vs Lighttpd and fact that Nginx (Centmin Mod Nginx) can be tuned to match or out perform Hiawatha for slowhttptest tests anyway.
It's reason why currently Centmin Mod only plans to add OpenLiteSpeed/LiteSpeed integration with Nginx web server eventually so Centmin Mod sites can be served from either Nginx and/or OpenLiteSpeed/LiteSpeed web server as they are both best performing at scale (think 500,000+ unique ip visitors/day type loads).
Some earlier OpenLiteSpeed vs H2O vs Centmin Mod Nginx page speed tests https://community.centminmod.com/threads/http-2-h2o-vs-openlitespeed-vs-nginx-spdy-3-1.2564/
Though all these comparisons are bias to Nginx as it has a much longer mature stable history of development as an advantage over these newer web servers for traditional web server type loads/usage.
Though the future we will see more of just Nginx vs OpenLiteSpeed/LiteSpeed type of questions as they're the only 2 web servers I can see for folks running at 'Scale' with efficient server resource usage in mind
thttpd, athough older than dirt, still works perfectly well, and CGI passthrough isn't very difficult, either.. but low end tends to be a slightly different group of needs than the aforementioned..
I'm worrying a bit because it's low-end VPS with 512MB only, I like caddy's simplicity a lot but really don't know if it can run on such a low-end box.
only way to know is try it and learn from the experience
worse case you'd need to switch web servers or upgrade server
I've used Caddy in a 256MB container as a proxy for a couple low traffic sites, worked fine. The only way to find out what's best here is to try it. Mount a swap file to be safe, and if it's ever used, consider nginx.
But anyway, to get back on topic - where is this CPU that prints food? I'm hungry.
Get a slice at the Deli "HungryVM"
Yes, you can.
My mistake , unfortunately, we have to eat food instead of foot now
I don't know, the whooping 9 MB it's using on my end could really blow your vps's 512 MB...
what you think of rancher and have you used rancheros?
It's nice to use but not mature yet.
Yes.
So Caddy is using only 9MB on your VPS? What traffic does it handle?
HTTP, generally.
Still prefer for Hiawatha + Httpd 2.4 (aka hiawatha-proxy).
Very low traffic, it reverse-proxies a few internal sites.
Along Caddy, Traefik one to consider. Dynamic service discovery is very nice when using Kubernetes/Nomad etc.
Homepage tells more https://traefik.io/
Even some benchmarks against nginx (kinda old versions both) http://docs.traefik.io/benchmarks/
To OP: define your usage-pattern, memory usage varies. My guess is that you just need proxy with minimal memory footprint when idling, you won't be asking these if serving 1k+/s hits :P
For quick checks, just run docker-images for each and check memory consumption and even run some ab2/wrk-tests to find you cpu/memory usage.
Docker-images
https://hub.docker.com/r/abiosoft/caddy/
https://hub.docker.com/_/nginx/
https://hub.docker.com/_/traefik/