Update fails on local cache update

Please follow the below template, it will help us to help you!

Expected Behaviour:

pi-hole updated

Actual Behaviour:

  [✗] Update local cache of available packages
  Error: Unable to update package cache. Please try "apt-get update"
  Unable to complete update, please contact Pi-hole Support
pi@pihole:~ $ apt-get update
Reading package lists... Done
E: Could not open lock file /var/lib/apt/lists/lock - open (13: Permission denied)
E: Unable to lock directory /var/lib/apt/lists/
W: Problem unlinking the file /var/cache/apt/pkgcache.bin - RemoveCaches (13: Permission denied)
W: Problem unlinking the file /var/cache/apt/srcpkgcache.bin - RemoveCaches (13: Permission denied)
pi@pihole:~ $

Debug Token:


This seems like an OS / permission issue, not related to Pi-hole.

apt requires sudo to run, i.e. you should use sudo apt-get update.

1 Like

[I apologize for my novice understanding. Here is what happened next.]

pi@pihole:~ $ sudo apt-get update
Hit:1 http://archive.raspberrypi.org/debian buster InRelease
Get:2 http://raspbian.raspberrypi.org/raspbian buster InRelease [15.0 kB]
Reading package lists... Done
E: Repository 'http://raspbian.raspberrypi.org/raspbian buster InRelease' changed its 'Suite' value from 'stable' to 'oldstable'
N: This must be accepted explicitly before updates for this repository can be applied. See apt-secure(8) manpage for details.

You would be better served posting in the RaspberryPi forums as that is where your issue is. It’s not a PiHole issue.


Please consider to familiarise yourself with your OS's package manager apt: That's still an issue with updating your OS rather than Pi-hole.

Answering [y]es to that question or running sudo apt-get update --allow-releaseinfo-change should allow your OS to reflect that change and continue.


Until the apt update process (controlled by the OS) completes, the Pi-hole installer/updater will not continue.

After you get the apt update problem resolved at the OS level, re-run the Pi-hole updater.

Many thanks to all responders; following the advice provided allowed the OS to update successful and then the pi-hole update succeeded!

This is a great community.



This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.