Package: aptitude-robot

Version: 1.5.5-1.1



My dpkg is locked, like so:


root@tims-desktop-linux:/var/log# apt install reportbug
Waiting for cache lock: Could not get lock /var/lib/dpkg/lock-frontend. It is held by process 123388 (dpkg)... 11s



Investigating that process, shows that it was run by aptitude-robot under anacron:


tbrownaw@tims-desktop-linux:~$ pstree -asp -H123388 123388
systemd,1 --system --deserialize=82 splash
  └─anacron,122571 -d -q -s
      └─sh,122632 -c run-parts --report /etc/cron.daily
          └─run-parts,122633 --report /etc/cron.daily
              └─aptitude-robot,122672 /etc/cron.daily/aptitude-robot
                  └─aptitude-robot-,122817 /usr/sbin/aptitude-robot-session                       └─aptitude-robot,122991 /usr/sbin/aptitude-robot -y -q -o DPkg::Options::=--force-confdef -o DPkg::Options::=--force-confold                           └─aptitude,122998 -y -q -o DPkg::Options::=--force-confdef -o DPkg::Options::=--force-confold -o Aptitude::ProblemResolver::Remove-Level=maximum -o ...                               └─dpkg,123388 --force-confdef --force-confold --status-fd 115 --configure --pending                                   ├─anacron.postins,123401 /var/lib/dpkg/info/anacron.postinst configure 2.3-45                                   │   └─deb-systemd-inv,123557 /usr/bin/deb-systemd-invoke restart anacron.service anacron.timer                                   │       └─systemctl,123564 --quiet --system restart anacron.service anacron.timer
                                  │  └─systemd-tty-ask,123565 --watch
                                  └─sh,123392 -c -- (test -x /usr/lib/needrestart/dpkg-status && /usr/lib/needrestart/dpkg-status || cat > /dev/null)                                       └─sh,123393 -c -- (test -x /usr/lib/needrestart/dpkg-status && /usr/lib/needrestart/dpkg-status || cat > /dev/null)                                           └─dpkg-status,123394 /usr/lib/needrestart/dpkg-status



That aptitude-robot pid has a logfile, which ends with setting up anacron:


root@tims-desktop-linux:/var/log# tail aptitude-robot-session.log.122817
Unpacking libopenni2-0:amd64 (2.2.0.33+dfsg-19) over (2.2.0.33+dfsg-18+b2) ...
Preparing to unpack .../6-python3-pyqt5.sip_12.17.2-1_amd64.deb ...
Unpacking python3-pyqt5.sip (12.17.2-1) over (12.17.1-1+b1) ...
Preparing to unpack .../7-xterm_405-1_amd64.deb ...
Unpacking xterm (405-1) over (403-1) ...
Setting up libopenni2-0:amd64 (2.2.0.33+dfsg-19) ...
Removing 'diversion of /lib/udev/rules.d/60-libopenni2-0.rules to /lib/udev/rules.d/60-libopenni2-0.rules.usr-is-merged by usr-is-merged'
Setting up libgpg-error0:amd64 (1.58-1) ...
Setting up libgpg-error0:i386 (1.58-1) ...
Setting up anacron (2.3-46) ...



If I look at the service status for anacron, it's been stopping for a few weeks:



root@tims-desktop-linux:/var/log# systemctl status anacron.timer anacron.service
● anacron.timer - Trigger anacron every hour
     Loaded: loaded (/usr/lib/systemd/system/anacron.timer; enabled; preset: enabled)      Active: active (running) since Wed 2025-12-17 17:29:56 CST; 1 month 1 day ago
        Job: 65946
 Invocation: c6683de8ca1a4f5a93799029b23c7d4c
    Trigger: n/a
   Triggers: ● anacron.service

Dec 17 17:29:56 tims-desktop-linux systemd[1]: Started anacron.timer - Trigger anacron every hour.

● anacron.service - Run anacron jobs
     Loaded: loaded (/usr/lib/systemd/system/anacron.service; enabled; preset: enabled)      Active: deactivating (stop-sigterm) since Sun 2025-12-21 07:46:14 CST; 4 weeks 0 days ago
        Job: 65848
 Invocation: 24d78beab534416db6fe1d12bc78666e
TriggeredBy: ● anacron.timer
       Docs: man:anacron
             man:anacrontab
   Main PID: 122571 (anacron)
      Tasks: 16 (limit: 76716)
     Memory: 732.9M (peak: 1G)
        CPU: 12min 12.379s
     CGroup: /system.slice/anacron.service
             ├─122571 /usr/sbin/anacron -d -q -s
             ├─122632 /bin/sh -c "run-parts --report /etc/cron.daily"
             ├─122633 run-parts --report /etc/cron.daily
             ├─122672 /bin/sh /etc/cron.daily/aptitude-robot
             ├─122817 /bin/sh /usr/sbin/aptitude-robot-session
             ├─122991 /usr/bin/perl /usr/sbin/aptitude-robot -y -q -o DPkg::Options::=--force-confdef -o DPkg::Options::=--force-confold              ├─122998 aptitude -y -q -o DPkg::Options::=--force-confdef -o DPkg::Options::=--force-confold -o Aptitude::ProblemResolver::Remove-Level=maximum -o "Aptitude::ProblemResolver::Hints::=reject !~M :UNINST" full-upgra>              ├─123388 /usr/bin/dpkg --force-confdef --force-confold --status-fd 115 --configure --pending              ├─123392 sh -c -- "(test -x /usr/lib/needrestart/dpkg-status && /usr/lib/needrestart/dpkg-status || cat > /dev/null)"              ├─123393 sh -c -- "(test -x /usr/lib/needrestart/dpkg-status && /usr/lib/needrestart/dpkg-status || cat > /dev/null)"
             ├─123394 /bin/sh /usr/lib/needrestart/dpkg-status
             ├─123401 /bin/sh /var/lib/dpkg/info/anacron.postinst configure 2.3-45              ├─123557 /usr/bin/perl /usr/bin/deb-systemd-invoke restart anacron.service anacron.timer              ├─123564 systemctl --quiet --system restart anacron.service anacron.timer
             └─123565 /usr/bin/systemd-tty-ask-password-agent --watch

Dec 21 07:30:28 tims-desktop-linux systemd[1]: Started anacron.service - Run anacron jobs. Dec 21 07:30:28 tims-desktop-linux anacron[122571]: Anacron 2.3 started on 2025-12-21 Dec 21 07:30:28 tims-desktop-linux anacron[122571]: Will run job `cron.daily' in 5 min. Dec 21 07:30:28 tims-desktop-linux anacron[122571]: Will run job `cron.weekly' in 10 min. Dec 21 07:30:28 tims-desktop-linux anacron[122571]: Jobs will be executed sequentially Dec 21 07:35:28 tims-desktop-linux anacron[122571]: Job `cron.daily' started
Dec 21 07:46:14 tims-desktop-linux anacron[122571]: Received SIGUSR1
Dec 21 07:46:14 tims-desktop-linux systemd[1]: Stopping anacron.service - Run anacron jobs...



So, it appears to me that aptitude-robot's attempt to restart anacron (because it's updating anacron) from within an anacron job has caused itself to hang.



In case it's relevant, the old version of anacron (that's being replaced) is:


root@tims-desktop-linux:/var/log# grep 'Unpacking anacron' aptitude-robot-session.log.122817
Unpacking anacron (2.3-46) over (2.3-45) ...

Reply via email to