Forked from rashkopetrov/fix-broken-apt-get-update.sh
Created
April 27, 2022 16:54
-
-
Save fxfactorial/9ef032d86e8f138225663153e5852f16 to your computer and use it in GitHub Desktop.
Fix `Error: Timeout was reached ` when doing `apt-get update`
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# source: https://www.linuxquestions.org/questions/debian-26/apt-get-update-gets-stuck-while-reading-package-list-on-my-slug-795324/ | |
mv /var/lib/dpkg/status /var/lib/dpkg/status.broken.bak | |
cp /var/lib/dpkg/status-old /var/lib/dpkg/status | |
rm -rf /var/lib/apt/lists/* | |
dpkg --configure -a | |
aptitude update | |
aptitude upgrade | |
aptitude install -f |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment