It looks as though the apt list file has an issue since the latest Consul release was added. This is causing any
apt command to fail because the list file cannot be parsed.
$ apt-cache policy E: Encountered a section with no Package: header E: Problem with MergeList /var/lib/apt/lists/apt.releases.hashicorp.com_dists_buster_main_binary-amd64_Packages E: The package lists or status file could not be parsed or opened.
Looking at the file, it looks like an errant line break is the cause:
$ tail -22 /var/lib/apt/lists/apt.releases.hashicorp.com_dists_buster_main_binary-amd64_Packages Package: consul Version: 1.10.3 License: MPL-2.0 Vendor: HashiCorp Architecture: amd64 Maintainer: HashiCorp <firstname.lastname@example.org> Installed-Size: 102484 Depends: openssl, passwd Section: default Priority: extra Homepage: https://www.consul.io/ Description: Consul is a distributed, highly available, and data center aware solution to connect and configure applications across dynamic, distributed infrastructure. Please submit issues to https://github.com/hashicorp/consul/issues Filename: pool/amd64/main/consul_1.10.3_amd64.deb SHA1: a84aa60aa64dc735f45c1d286f9b71590a96f6b3 SHA256: 3946041cc3e585a3977b7821690d2d996c45738e90502ddb1d7e15e320006908 Size: 38132392 Filename: pool/amd64/main/consul-enterprise_1.10.3+ent_amd64.deb SHA1: bc998171471b95e01a6a637c75e6de832d37439e SHA256: 81f3a1673227f546de0afde63899f815ce12bac325da8434e7725faf48341c28 Size: 41854160
Removing that line break fixes the issue.
This has also been reported on Consul’s github issues Problem with MergeList /var/lib/apt/lists/apt.releases.hashicorp.com_dists_buster_main_binary-amd64_Packages · Issue #11162 · hashicorp/consul · GitHub.
Please let me know if you need any more info!