I'm on Ubuntu 22.04.1 LTS and a sudo apt install php-pear
returns :
E: Failed to fetch http://security.ubuntu.com/ubuntu/pool/main/p/php8.1/php8.1-xml_8.1.2-1ubuntu2.10_amd64.deb 404 Not Found [IP: x.x.x.x 80]
This is a 404 - http://security.ubuntu.com/ubuntu/pool/main/p/php8.1/php8.1-xml_8.1.2-1ubuntu2.10_amd64.deb
According to packages.ubuntu.com, the current version is not
8.1.2-1ubuntu2.10
. It's...2.11
The most common cause (by far!) is that the local package database is stale.
Run
sudo apt update
to update your local package database.