apt update blocked/locked, processes hung for days due to avahi-browse
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
apt (Ubuntu) |
New
|
Undecided
|
Unassigned |
Bug Description
Using 18.04 I hit a problem:
$ sudo apt -o=Debug:
WARNING: apt does not have a stable CLI interface. Use with caution in scripts.
Reading package lists...
E: Could not get lock /var/lib/
E: Unable to lock directory /var/lib/apt/lists/
Investigating further I discovered a 3 day old cron job is hung:
$ date
Tue 6 Nov 08:50:20 GMT 2018
$ ps -efly | grep apt
S tj 31068 8492 0 80 0 1016 5384 pipe_w 08:48 pts/4 00:00:00 grep --color=auto apt
S root 31280 1 0 80 0 860 1157 - Nov03 ? 00:00:00 /bin/sh /usr/lib/
S root 31285 31280 0 80 0 1748 1157 - Nov03 ? 00:00:00 /bin/sh /usr/lib/
S root 31331 31285 0 80 0 8080 15493 - Nov03 ? 00:00:00 apt-get -qq -y update
S root 31336 31331 0 80 0 5556 19025 - Nov03 ? 00:00:00 /usr/lib/
S root 32312 31331 0 80 0 5636 19025 - Nov03 ? 00:00:00 /usr/lib/
S _apt 32314 31331 0 80 0 9548 10752 - Nov03 ? 00:00:00 /usr/bin/python /usr/share/
S _apt 32315 32314 0 80 0 1536 10458 - Nov03 ? 00:00:00 avahi-browse -kprtf _apt_proxy._tcp
I've successfully installed packages using "apt install" since the date these update processes started.
Checking the mDNS proxy command manually it returns with no result:
$ avahi-browse -kprtf _apt_proxy._tcp
$