You are not logged in.

#1 2024-02-13 16:33:40

quayasil
Member
Registered: 2008-11-09
Posts: 102

How to force post upgrade hooks?

I've run upgrade in an XFCE terminal (yes I know it's safer to run from a tty or from a screen, my mistake). When running post-upgrade hooks it restarted my XFCE session (something related to systemd I guess - than you systemd). As a result some hooks haven't been called - even those critical to system boot up :-( How can I force them running? I'm afraid I cannot see such an option for pacman :-(

The only solution I can think of is:
- set repos to archive in /etc/pacman.conf
- downgrade
- set repos to current again
- upgrade again.

but it's is a bit inefficient solution

Offline

#2 2024-02-13 17:46:41

loqs
Member
Registered: 2014-03-06
Posts: 17,416

Re: How to force post upgrade hooks?

Check /var/log/pacman.log for the list of packages that were part of the update which missed the hooks then reinstall them with `pacman -S`?

Offline

#3 2024-02-13 18:13:00

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,754

Re: How to force post upgrade hooks?

As for the session crash, systemd is only quite indirectly responsible for that. Check for stale and unused xorg config files that try to make use of evdev devices that shouldn't be used anymore, and potentially to disable the relevant interaction create the file /etc/do-not-udevadm-trigger-on-update

see https://bugs.archlinux.org/task/77789 for context.

Offline

#4 2024-02-13 18:42:23

quayasil
Member
Registered: 2008-11-09
Posts: 102

Re: How to force post upgrade hooks?

loqs wrote:

Check /var/log/pacman.log for the list of packages that were part of the update which missed the hooks then reinstall them with `pacman -S`?

Go to a tty (Ctl-Alt-F2). In /etc/pacman.conf replace the lines:

Include = /etc/pacman.d/mirrorlist

with

Server = https://archive.archlinux.org/repos/202 … o/os/$arch

or with the other date, then run:

# pacman -Suuyy

then revert the changes in /etc/pacman.conf

then upgrade again:

# pacman -Suy

It works but it doesn't seem to be the easiest solution.

Offline

#5 2024-02-14 01:18:44

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,754

Re: How to force post upgrade hooks?

There's no reason for the intermediate steps, you just need to explicitly reinstall the affected set of packages as part of a normal pacman -Syu  $packageshere$ without having to switch to archive mirrors or downgrading prior at all.

Offline

#6 2024-02-20 23:34:34

mountaintrek
Member
Registered: 2024-02-01
Posts: 18

Re: How to force post upgrade hooks?

quayasil wrote:

I've run upgrade in an XFCE terminal ....  hooks it restarted my XFCE session.... As a result some hooks haven't been called ... How can I force them running?

Just wanted to say "thank you" OP for asking this question and to those that answered. I experienced the same thing and was left figuring out how to run the post-transaction hooks.  I recovered in a different way, but if it ever happens again, I'll do it this way.  I am thinking of adding a step before an update, like:

checkupdates | cut -d' ' -f1 | sed -e '1i #!/bin/bash\npacman -S \\' -e '$! s/$/ \\/' > pacman-updated-packages

For me, the last line on the terminal was, "( 4/25) Reloading user manager configuration...".

In the journal I saw, "dbus-daemon .... pid=... Reloaded configuration", over and over and over again, when finally I saw, "systemd-udevd.service: Reload operation timed out. Killing reload process", "dbus.service: Reload operation timed out. Killing reload process."

Last edited by mountaintrek (2024-02-20 23:38:29)

Offline

Board footer

Powered by FluxBB