telegraf icon indicating copy to clipboard operation
telegraf copied to clipboard

APT repository "Size mismatch" error when updating Telegraf 1.40.4-1 on Ubuntu 24.04.05

Open jozefbarcin opened this issue 1 week ago • 8 comments

Installation / APT repository issue

System info

  • OS / Version: Ubuntu 24.04.5 LTS (Noble Numbat)
  • Architecture: amd64
  • Target Telegraf Version: 1.40.4-1
  • APT Source Entry:
$ cat /etc/apt/sources.list.d/influxdata.sources
Components: main
X-Repolib-Name: influxdata
Signed-By: /etc/apt/trusted.gpg.d/influxdata-archive.asc
Suites: stable
Types: deb
URIs: https://repos.influxdata.com/debian

Steps to reproduce

  1. Configure the official InfluxData APT repository (://influxdata.com) on Ubuntu 24.04.5 LTS (noble).
  2. Run sudo apt-get update & apt-get install telegraf
  3. Observe persistent E: Failed to fetch ... Size mismatch errors.
$ sudo apt-get update
Err:7 https://repos.influxdata.com/debian stable/main amd64 Packages
  File has unexpected size (33985 != 34093). Mirror sync in progress? [IP: 172.67.213.236 443]
  Hashes of expected file:
   - Filesize:34093 [weak]
   - SHA256:e1510bf1fe3cc819790ce9fa76fee346ef1403a7a7cd9bb5d918c54b488ec298
   - SHA1:5b5ae87ab79bf741eb28cded31db941f11f3a10c [weak]
   - MD5Sum:7e3b4af1bf87b2376abecb5c81dde26d [weak]
  Release file created at: Wed, 25 Nov 2026 16:35:43 +0000

Expected behavior

sudo apt-get update & apt-get install telegraf should download and update telegraf 1.40.4-1 cleanly without a checksum or file size mismatch.

Actual behavior

APT fails with a persistent Size mismatch error, even after clearing local APT lists (rm -rf /var/lib/apt/lists/*) and running apt-get clean.

Additional info

  • Proxy / Cache in use? No
  • Region: Central Europe (Slovakia)

jozefbarcin avatar Nov 26 '26 11:11 jozefbarcin

I see the same issue as well.

Err:10 https://repos.influxdata.com/debian stable/main amd
64 Packages
  File has unexpected size (33985 != 34093). Mirror sync i
n progress? [IP: 2606:4700:3031::ac43:d5ec 443]
  Hashes of expected file:
   - Filesize:34093 [weak]
   - SHA256:e1510bf1fe3cc819790ce9fa76fee346ef1403a7a7cd9b
b5d918c54b488ec298
   - SHA1:5b5ae87ab79bf741eb28cded31db941f11f3a10c [weak]
   - MD5Sum:7e3b4af1bf87b2376abecb5c81dde26d [weak]
  Release file created at: Wed, 25 Nov 2026 16:35:43 +0000

Still seen at 2026-11-26 14:38 ...

gerhard-tinned avatar Nov 26 '26 14:11 gerhard-tinned

The RPM repository has issues with its metadata as well, it's not possible to update a local mirror with dnf reposync when also downloading metadata:

[root@8ae737b7f52c /]# dnf reposync --download-metadata  --enablerepo=influxdata -n
InfluxData Repository - Stable                                                                  52 kB/s | 3.0 kB     00:00
InfluxData Repository - Stable                                                                 1.8 MB/s | 1.9 MB     00:01
Traceback (most recent call last):
  File "/usr/bin/dnf", line 62, in <module>
    main.user_main(sys.argv[1:], exit_code=True)
  File "/usr/lib/python3.12/site-packages/dnf/cli/main.py", line 222, in user_main
    errcode = main(args)
              ^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/dnf/cli/main.py", line 70, in main
    return _main(base, args, cli_class, option_parser_class)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/dnf/cli/main.py", line 109, in _main
    return cli_run(cli, base)
           ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/dnf/cli/main.py", line 136, in cli_run
    cli.run()
  File "/usr/lib/python3.12/site-packages/dnf/cli/cli.py", line 1137, in run
    return self.command.run()
           ^^^^^^^^^^^^^^^^^^
  File "/usr/lib/python3.12/site-packages/dnf-plugins/reposync.py", line 154, in run
    self.download_metadata(repo)
  File "/usr/lib/python3.12/site-packages/dnf-plugins/reposync.py", line 249, in download_metadata
    repo._repo.downloadMetadata(repo_target)
  File "/usr/lib64/python3.12/site-packages/libdnf/repo.py", line 473, in downloadMetadata
    return _repo.Repo_downloadMetadata(self, destdir)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
RuntimeError: Yum repo downloading error: Downloading error(s): repodata/3428802e2377216da8477d132858462e7af0bcfb6da45a4e75cf5d8ac02e7a30-primary.sqlite.bz2 - Cannot download, all mirrors were already tried without success; repodata/525d2addfec0f7e53e446454f709154182c3fb67ee25d6e0045c8d0d81c72648-filelists.sqlite.bz2 - Cannot download, all mirrors were already tried without success; repodata/11dfe37838477432cc90eb510f0e33494349d2559e620f966017be8cdb89fc6a-other.xml.gz - Cannot download, all mirrors were already tried without success; repodata/6184304f72f23feb9d5a69404c50e5b671e6ea6d83352283019aa0d7c6123947-other.sqlite.bz2 - Cannot download, all mirrors were already tried without success

This issue is only present when creating a local mirror.

For APT, the same issue has been reported in the community forums as well: Cloudflare servers serving inconsistent debian InRelease file?

stdietrich avatar Nov 27 '26 09:11 stdietrich

Same happening to me as of 11/28….

billyconte avatar Nov 28 '26 15:11 billyconte

I tried reporting this directly to the webmaster, but it appears InfluxData doesn't support the RFC standard webmaster@ email address. That might be a standard worth considering when addressing this ticket so these types of errors can be fixed more quickly in the future.

hax0rbana-adam avatar Nov 28 '26 19:11 hax0rbana-adam

Someone reported it here... https://community.influxdata.com/t/cloudflare-servers-serving-inconsistent-debian-inrelease-file/59096/4

loganmarchione avatar Nov 28 '26 21:11 loganmarchione

I see a multiple reports of this problem over the past couple days, but not any acknowledgements by those responsible for maintaining the apt repo...

Relatedly: Is anyone able to reproduce the issue of the PGP signature not being valid on the Release file?

$ curl https://repos.influxdata.com/debian/dists/stable/Release.gpg > /tmp/influx_Release.gpg
$ curl https://repos.influxdata.com/debian/dists/stable/Release > /tmp/influx_Release

$ gpg --show-keys --with-subkey-fingerprints /etc/apt/trusted.gpg.d/influxdata-archive_compat.gpg.asc
pub   rsa4096 2023-01-18 [SC]
      24C975CBA61A024EE1B631787C3D57159FC2F927
uid                      InfluxData Package Signing Key <[email protected]>
sub   rsa4096 2023-01-18 [S] [expired: 2026-01-17]
      9D539D90D3328DC7D6C8D3B9D8FF8E1F7DF8B07E
sub   rsa4096 2025-07-10 [S] [expires: 2029-01-17]
      AC10D7449F343ADCEFDDC2B6DA61C26A0585BD3B

$ gpg --import /etc/apt/trusted.gpg.d/influxdata-archive_compat.gpg.asc
gpg: key 7C3D57159FC2F927: "InfluxData Package Signing Key <[email protected]>" not changed
gpg: Total number processed: 1
gpg:              unchanged: 1

$ gpg --verify /tmp/influx_Release.gpg /tmp/influx_Release
gpg: Signature made Wed 25 Nov 2026 10:40:07 AM CST
gpg:                using RSA key AC10D7449F343ADCEFDDC2B6DA61C26A0585BD3B
gpg: BAD signature from "InfluxData Package Signing Key <[email protected]>" [unknown]

The signature file appears to be using the correct key, and the InRelease file can be verified, but the Release.gpg file is not. This breaks some clients as well as debmirror (which I'm trying to put in place so next time this apt repo breaks, it doesn't break apt update across my entire fleet).

This PGP verification error could be indicative of an attack, but I believe it is just that the update process failed after uploading Release.gpg and InRelease, but before updating Release. I noticed that Release file is 2 days older than the InRelease and has different checksums on their packages.

Here's some excerpts showing the differences between Release and InRelease:

-Date: Mon, 23 Nov 2026 20:58:27 UTC
+Date: Wed, 25 Nov 2026 16:35:43 UTC

- 908dcbb2d63b7c1ebc4042047d0356e8 11429 main/binary-i386/Packages.gz
+ c6a79e003adae12c3aa0030e1b851980 11429 main/binary-i386/Packages.gz
  133e680afc4f3ad873e1b8b484254f2b 109 main/binary-amd64/Release
- 49af76f028558a5082c6d956fba80d31 169065 main/binary-amd64/Packages
- 87af34cc18272f8d10672cef17234be8 33985 main/binary-amd64/Packages.gz
+ 393b8ce7bec87fa3828545416726c628 169648 main/binary-amd64/Packages
+ 7e3b4af1bf87b2376abecb5c81dde26d 34093 main/binary-amd64/Packages.gz

The HTTP response headers also support this theory.

$ curl -vv https://repos.influxdata.com/debian/dists/stable/Release |& grep modified
17:40:15.674560 [0-0] < last-modified: Mon, 23 Nov 2026 21:08:20 GMT
17:40:15.674568 [0-0] * [HTTP/2] [1] header: last-modified: Mon, 23 Nov 2026 21:08:20 GMT
$ curl -vv https://repos.influxdata.com/debian/dists/stable/Release.gpg |& grep modified
17:40:09.816938 [0-0] < last-modified: Wed, 25 Nov 2026 16:44:23 GMT
17:40:09.816951 [0-0] * [HTTP/2] [1] header: last-modified: Wed, 25 Nov 2026 16:44:23 GMT

Note 1: This is the PGP validation failure of the Release file is separate from the size mismatch on Packages.gz, but likely related, which is why I'm mentioning it in this thread instead of starting a separate ticket about it.

hax0rbana-adam avatar Nov 28 '26 23:11 hax0rbana-adam

I had some people from around the world test this and the reason it's working from some places is because some places are still getting the old Releases file (from the 23rd) instead of the new one (from the 25th). The outdated version works, the new one does not.

hax0rbana-adam avatar Nov 29 '26 01:11 hax0rbana-adam

solved: https://github.com/influxdata/telegraf/issues/20278

jozefbarcin avatar Dec 01 '26 09:12 jozefbarcin