2021-09-28 09:35:23 |
Thomas Cuthbert |
description |
The current refresh_patterns for ubuntu-repository-cache don't allow for squid to fetch large upstream debs while still serving from cache.
# refresh pattern for debs and udebs
refresh_pattern deb$ 129600 100% 129600
refresh_pattern udeb$ 129600 100% 129600
refresh_pattern tar.gz$ 129600 100% 129600
# refresh stats: https://pastebin.ubuntu.com/p/N9NdgWfrGk/
HTTP histogram:
Count %Total Category
6571 0.18 Stale: expires time reached
0 0.00 Fresh: refresh_pattern last-mod factor percentage
Cache Digests histogram:
Count %Total Category
8293 1.65 Stale: expires time reached
3672 0.73 Fresh: refresh_pattern last-mod factor percentage
On Store histogram:
Count %Total Category
2352 11.26 Fresh: expires time not reached
0 0.00 Fresh: refresh_pattern last-mod factor percentage
For example archive.ubuntu.com/ubuntu/pool/restricted/n/nvidia-graphics-drivers-470/libnvidia-gl-470_470.63.01-0ubuntu0.18.04.2_amd64.deb, is 128MB, it's a popular deb and once the refresh timer of 24 hours expires squid's LM-factor is not able to serve semi-stale content while it fetches upstream.
I think:
refresh_pattern deb$ 129600 100% 129600
refresh_pattern udeb$ 129600 100% 129600
refresh_pattern tar.gz$ 129600 100% 129600
Should be:
refresh_pattern deb$ 129600 98% 129600
refresh_pattern udeb$ 129600 98% 129600
refresh_pattern tar.gz$ 129600 98% 129600
So squid has time to fetch larger debs upstream before the Cache-Control: max-age=$secs is reached. |
The current refresh_patterns for ubuntu-repository-cache don't allow for squid to fetch large upstream debs while still serving from cache.
# refresh pattern for debs and udebs
refresh_pattern deb$ 129600 100% 129600
refresh_pattern udeb$ 129600 100% 129600
refresh_pattern tar.gz$ 129600 100% 129600
# refresh stats: https://pastebin.ubuntu.com/p/N9NdgWfrGk/
HTTP histogram:
Count %Total Category
6571 0.18 Stale: expires time reached
0 0.00 Fresh: refresh_pattern last-mod factor percentage
Cache Digests histogram:
Count %Total Category
8293 1.65 Stale: expires time reached
3672 0.73 Fresh: refresh_pattern last-mod factor percentage
On Store histogram:
Count %Total Category
2352 11.26 Fresh: expires time not reached
0 0.00 Fresh: refresh_pattern last-mod factor percentage
For example archive.ubuntu.com/ubuntu/pool/restricted/n/nvidia-graphics-drivers-470/libnvidia-gl-470_470.63.01-0ubuntu0.18.04.2_amd64.deb, is 138MB, it's a popular deb and once the refresh timer of 24 hours expires squid's LM-factor is not able to serve semi-stale content while it fetches upstream. https://pastebin.ubuntu.com/p/tNNXDf8c25/
I think:
refresh_pattern deb$ 129600 100% 129600
refresh_pattern udeb$ 129600 100% 129600
refresh_pattern tar.gz$ 129600 100% 129600
Should be:
refresh_pattern deb$ 129600 98% 129600
refresh_pattern udeb$ 129600 98% 129600
refresh_pattern tar.gz$ 129600 98% 129600
So squid has time to fetch larger debs upstream before the Cache-Control: max-age=$secs is reached. |
|