![]() ![]() A random sample from my history.log: Preparing to replace gnupg 1.4.10-4 (using. In particular, it gives a list of newly installed packages, or of removed packages.Īdditionally, term.log shows what actually appeared on the terminal during the action, so that would show the old and new versions of packages. History.log gives a summary list of every action that apt takes in the following format: Start-Date: 16:05:05Ĭommandline: apt-get install rdiff-backup I suppose there could be some kind of script that could save the list of newly installed package and their previous version number The log files /var/log/apt/history.log and /var/log/apt/term.log are the closest things available to your description: For example with: apt-mark hold zfsutils libzfs2. To prevent this rollback to be overwritten by the next upgrade, the packages will need to be pinned, until the original issue is resolved. $ apt-get install $(cat rollback.txt | tr '\n' ' ')Īpt will warn about the downgrades which is expected. Trim this list as needed in a text editor and then run (with -s for dry-run first): $ apt-get -s install $(cat rollback.txt | tr '\n' ' ') This provides a nicely formatted list of versioned packages to roll-back to by feeding it into apt-get install. I installed the tiny script apt-history from here into ~/.bashrc and ran $ apt-history rollback > rollback.txt I temporarily trimmed my /var/log/dpkg.log to leave just today's upgrade Here are the steps I took to get this working properly: ![]() If it does what you want remove the -s and run it again. The short answer - you could use the following command: $ apt-get -s install $(apt-history rollback | tr '\n' ' ') At least an older kernel could still boot, but was incompatible with other software. I just now had to figure out an answer to this, because the last apt-get upgrade on a Debian server made it impossible to boot the most recent kernel beyond a busybox, failing to mount the zfs root partition. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |