[10:21:49] does anyone know whether using nginx would still provide any benefits if I were already to use Varnish? [10:27:55] taylan: varnish is simply for caching [10:28:05] I'm pretty sure you still need a webserver [10:28:14] Or at least the WMF don't only use varnish [10:29:28] taylan: see https://wikitech.wikimedia.org/wiki/CDN#Caching [10:29:48] RhinosF1: what I mean is, would varnish -> nginx offer any performance benefits over varnish -> apache ? [10:30:46] oh, WM also uses HAProxy... I would have thought Varnish makes that unnecessary. [10:31:33] taylan: that's not what you asked but the WMF use apache at the moment [10:32:15] And https://upload.wikimedia.org/wikipedia/commons/4/4d/Wikipedia_webrequest_2022.png is a good diagram by Krinkle of how that all fits together [10:32:37] I guess nginx vs. apache probably doesn't make much of a difference after the front-end cache already took the heavy burden... [10:33:12] dang, that's some complex architecture lol. thankfully my website isn't gonna get nearly as much traffic :D [10:33:48] do you happen to know why haproxy is needed? can't varnish do TLS? [10:33:57] Personally, no [10:34:02] Someone from traffic would [10:34:38] That might be more suited to #wikimedia-sre as that's specific to the crazy setup WMF has [10:34:45] As opposed to what's good for anyone [10:39:34] yeah don't think I need to bother them, as my site is gonna be much smaller, even though it's probably gonna get some respectable traffic. (fan wiki for upcoming video game Baldur's Gate 3, which already sold millions of early access copies and is projected to sell many millions more on release...) [10:40:25] I have a feeling that varnish is all I need [12:04:55] taylan: https://www.mediawiki.org/wiki/Manual:Performance_tuning [12:05:17] I've gone through that... gonna set up varnish for sure. [12:05:48] taylan: indeed, I wouldn't worry about each layer we have. Varnish, php-apcu, and Memcached will get you most of the way there [12:05:53] on one hand I actually want to try out nginx anyway, even if it wouldn't make a big difference, and see how it works; on the other hand, it's so much work changing all the config [12:06:41] apache has been annoying me a lot, taking forever to restart, because it tries to wait for clients (that probably use keep-alive) to close the connections, then systemd stops waiting and just sends SIGKILL anyway... [12:06:42] We only used nginx as a better TLS encrypted on top of Apache and on top of varnish. We no longer use it [12:07:13] It's a minor optimisation in the grand scheme of things [12:08:05] Krinkle: do you have a recommendation re. mpm_event.conf values? I've a little problem with thread limits on my cheap VPS and apache spawning tons of threads, posted about it here: https://serverfault.com/questions/1137660/apache-creates-3x-as-many-threads-as-maxrequestworkers [12:08:20] I guess after setting up varnish, I shouldn't need many apache workers? [12:09:08] same question applies to php fpm's pool config. I guess with varnish, I can get away with about equal number of apache workers and php processes, since apache won't be serving static content much? [14:46:40] anyone know off-hand how I could detect in LocalSettings.php whether it was Apache or Nginx that handled the HTTP request? I want to run Nginx in parallel on a different port for testing, and wanna set $wgServer accordingly with or without a port number [14:47:33] $_SERVER['SERVER_SOFTWARE'] [14:47:45] Apparently may not work on newer PHP.. [14:47:46] * Reedy looks [14:48:36] >string(22) "Apache/2.4.54 (Ubuntu)" [14:48:37] nope, works fine [14:53:57] I think I can use SERVER_PORT [15:12:26] huh, this seems to work automatically, the port number is there in all the links when I access the site with a port number, even though I didn't change anything in LocalSettings [15:13:34] did redirect me to the standard port when I logged in though, but that's ok [15:13:58] some other things also redirect, interesting [16:31:15] can the colors of the Citizen skin be modified easily? [17:59:42] Hi! [18:00:00] I have an issue with uploading a large SVG image (6087x61569). [18:03:00] Got an error message “…convert-im6.q16: width or height exceeds limit…” in place of the thumbnail. [18:03:35] I tried manually adding thumbnail files https://www.mediawiki.org/wiki/Manual:Common_errors_and_symptoms#Manually_adding_thumbnail_files [18:04:10] But it didn’t change anything. Any clue where to look in? [19:33:22] @yvanzo that is an error by the thumbnailer ImageMagick because the file it is trying to use/produce is bigger than it can support. [19:50:39] I know but I’m looking for workarounds. [20:32:51] yvanzo: this is on your own wiki, i assume? [20:33:20] duesen: yes, I’m admin and can change settings. [20:33:43] yvanzo: can you just declare the svg to be smaller? SVGs don't have a "real" pixel size, the size it declares is really just a default for rendering... [20:35:16] Not really, it has a lot of text, so it is expected to be that big, even though it takes only 1.2M. [20:35:52] yea, but mediawiki will render svg to png. And the renderer chokes on the large dimensions. [20:36:07] From a quick google search, the error message seems to come from ImageMagic. [20:36:08] How would I do that? [20:36:22] ImageMagic is pretty bad at rendering svg. Maybe try configuring a different renderer? [20:36:34] Yes, I have the same error message when I try "convert" with the same image on the same host. [20:37:07] I'd try rsvg for rendering instead. Let me look up the setting... [20:37:24] However the "convert" on my laptop works just fine, so I’m trying to update it on the host. [20:38:09] yvanzo: if you have rsvg installed, fixing this should be as simple as $wgSVGConverter = 'rsvg' ; [20:38:31] see https://www.mediawiki.org/wiki/Manual:$wgSVGConverters for more info [20:40:02] Thank you, I’m trying to install it. [20:40:10] does anyone happen to know off-hand whether this page is up to date and the sample config safe to use? https://www.mediawiki.org/wiki/Manual:Short_URL/Nginx [20:40:41] it certainly functions, I've tested it, but asking just in case. maybe there's some new .htaccess files added recently that should would need an update to this config, since nginx doesn't read .htaccess files... [20:41:36] by the way I've fixed it to use the correct "=404" syntax instead of just "404" for the try_files commands. I guess the "404" would work too but only because it will fail to find a file called "404" and default to returning 404 anyway... [20:42:32] duesen: It’s working just fine now, thanks a lot. [20:45:45] yvanzo: excellent! [20:46:35] taylan: i don't know, sorry... [20:58:43] successfully made the switch to nginx with just a few seconds of downtime, PHEW! [21:00:07] the thorny part was that the same server hosts a ton of other sites, including a wordpress installation, a nextcloud installation, and another mediawiki with a much more complex apache config, and to keep those running fine for now I've just made nginx reverse-proxy those to apache... things appear to be working fine :D