-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA256 On Fri, 28 May 2021, Christian Hesse wrote:
Well, out-of-date is a term that does barely match here... pacman does known about the date of its current database files only. So yes, more recent database files are used as long as they are newer than the local ones - even if out-of-date compared with a mirror.
That's why the pacredir documentation tells you to run `pacman -Sy` twice to be sure: First run fetches the newest database from local network, second run (where pacredir returns 404) fetches from mirror if a newer version is available.
Just some side-idea: why not consider all databases which are older than x minutes (where x is configurable) "out of date"? This would rely on having systemtimes in sync, but otherwise would get rid of the cumbersome double-`pacman -Syu`. regards, Erich P.S.: I'm running something similar as you - but by far not as elaborate: two (for redundancy) nginx servers which cache packages and download databases directly. -----BEGIN PGP SIGNATURE----- iQIzBAEBCAAdFiEE3p92iMrPBP64GmxZCu7JB1Xae1oFAmCw4XYACgkQCu7JB1Xa e1oxlA/9Gw07gaaSs14YXaScYg6bxUZtPLxU308uXzBXnPGWxbPaHdyMTzoKbUcK WK/khLbrU8akJtzcvhS6JUwgWGLhgZ9rKign2oqsHd/Vehzq0AMs4t6E0uBo+t4q IXsNfWE/R7X0KIBfrvSvZBrgZRbAqZ3C2Om0YbtxJIyQHZYzb+zxMix9GH0TvJdU hvZU/nSedSl3tL/5TloFTU7giMmUr4endXwCQkZemGvBtav45CwZNLlTy121WcRI F5qQfr8nAIj46zn4xH3xBVZa5aPBDg4S5Xp0Ey0rPlBWEDqx5rDTdo268hIMX7Fy Wq5ki7+Uaf+AVz7LD95dIExfgwajqUPpO6dctb91IPAAuxTM5afLcff84U3KtprC ugHqArk76m65HKW/ETOQxLGw+2/aexXXGFNoueh3IEXMShyX7reNNlCAA2rTRkuP 6RHXOS/BODNaJCuHzo3g2V3xcTwDztmkGJK6oVEyOZJczeBd3CwW82d0AqOY5+KF kUNvNGHa//QyQsjCRTFcp2Az5trPRmnYI+/uYyGbpll19nW2jnXZuaQbNMwg+GG9 GtA9qBdCuubMdkcW+zIIYv9AHbyiYjxO7b4eVsLSJAgluPaEzc1GVP+lTqmQP/v7 HpMTGB/53rxDHIhnPQJSZMd68RG8eSrsppDHoh+M9dJ2mdberZs= =7LPG -----END PGP SIGNATURE-----