You are not logged in.

#1 2018-03-20 13:41:55

bheadmaster
Member
Registered: 2017-10-27
Posts: 43

[SOLVED] How to reinstall all packages installed in the past day?

Last night my machine froze during the update and now kernel panic occurs when I try to boot. I've used a live disc to boot into the shell, mounted my drive, deleted the db lock file, and I want to reinstall all packages that were installed last night.

Is there a way to do this with pacman?

Last edited by bheadmaster (2018-03-20 14:36:16)


.............|
............/  GNU
........../
__---'''             o  LINUX

Offline

#2 2018-03-20 13:45:51

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,543
Website

Re: [SOLVED] How to reinstall all packages installed in the past day?

The direct answer:

sed -n 's/\[2018-03-19.*upgraded *\([^ ]*\).*/\1/p' /var/log/pacman.log  | pacman -S -

But really why do you think that is needed/worth doing?  Just do `pacman -Syu`.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2018-03-20 14:35:45

bheadmaster
Member
Registered: 2017-10-27
Posts: 43

Re: [SOLVED] How to reinstall all packages installed in the past day?

Trilby wrote:

But really why do you think that is needed/worth doing?  Just do `pacman -Syu`.

Because the packages that created the issues (apparently, intel-ucode and linux) were seen as properly installed by pacman, so `pacman -Syu` only updated some new packages.

The direct answer fixed my system smile It seems that the boot partition has been screwed up. Thanks a lot!


.............|
............/  GNU
........../
__---'''             o  LINUX

Offline

#4 2018-03-20 14:39:21

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,543
Website

Re: [SOLVED] How to reinstall all packages installed in the past day?

Note that I let sed do the heavy lifting, but the logic of the command is simply to check pacmans log file for which packages were updated last night, then just install them again with `pacman -S`.


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

Board footer

Powered by FluxBB