Score:1

There are some errors with avahi-daemon when I try to upgrade Xubuntu 21.04

af flag

I have Xubuntu 21.04 64-bit. Every time I do "apt upgrade" I have error messages:

Setting up avahi-daemon (0.8-5ubuntu3.1) ...
invoke-rc.d: syntax error: unknown option "--skip-systemd-native"
dpkg: error processing package avahi-daemon (--configure):
 installed avahi-daemon package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of avahi-utils:
 avahi-utils depends on avahi-daemon (= 0.8-5ubuntu3.1); however:
  Package avahi-daemon is not configured yet.

dpkg: error processing package avahi-utils (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
Errors were encountered while processing:
 avahi-daemon
 avahi-utils
E: Sub-process /usr/bin/dpkg returned an error code (1)

Could you help me? Thanks.

I've tried this command to get more info:

sudo apt-get update; sudo apt-get install -f; sudo dpkg --configure -a
Hit:1 http://dl.google.com/linux/chrome/deb stable InRelease
Hit:2 http://prerelease.keybase.io/deb stable InRelease                                                                                                                       
Hit:3 https://brave-browser-apt-release.s3.brave.com stable InRelease                                                                                                         
Hit:4 https://linux.teamviewer.com/deb stable InRelease                                                                                                                       
Hit:5 http://ru.archive.ubuntu.com/ubuntu hirsute InRelease                                                                                                                   
Hit:6 http://ru.archive.ubuntu.com/ubuntu hirsute-updates InRelease                                                                                                           
Hit:7 http://ru.archive.ubuntu.com/ubuntu hirsute-backports InRelease                                                                                                         
Hit:8 http://packages.microsoft.com/repos/code stable InRelease                                                                                                               
Get:9 http://security.ubuntu.com/ubuntu hirsute-security InRelease [110 kB]                                                                                                   
Hit:10 http://ppa.launchpad.net/shutter/ppa/ubuntu hirsute InRelease                                                                                                          
Ign:12 http://linux.dropbox.com/ubuntu disco InRelease                                                                                                                        
Hit:13 http://linux.dropbox.com/ubuntu disco Release                                                             
Hit:14 https://download.sublimetext.com apt/stable/ InRelease                              
Hit:11 https://apt.llvm.org/groovy llvm-toolchain-groovy-13 InRelease
Fetched 110 kB in 2s (58,5 kB/s)              
Reading package lists... Done
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
2 not fully installed or removed.
After this operation, 0 B of additional disk space will be used.
Setting up avahi-daemon (0.8-5ubuntu3.1) ...
invoke-rc.d: syntax error: unknown option "--skip-systemd-native"
dpkg: error processing package avahi-daemon (--configure):
 installed avahi-daemon package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of avahi-utils:
 avahi-utils depends on avahi-daemon (= 0.8-5ubuntu3.1); however:
  Package avahi-daemon is not configured yet.

dpkg: error processing package avahi-utils (--configure):
 dependency problems - leaving unconfigured
No apport report written because the error message indicates its a followup error from a previous failure.
                                                                                                          Errors were encountered while processing:
 avahi-daemon
 avahi-utils
E: Sub-process /usr/bin/dpkg returned an error code (1)
Setting up avahi-daemon (0.8-5ubuntu3.1) ...
invoke-rc.d: syntax error: unknown option "--skip-systemd-native"
dpkg: error processing package avahi-daemon (--configure):
 installed avahi-daemon package post-installation script subprocess returned error exit status 1
dpkg: dependency problems prevent configuration of avahi-utils:
 avahi-utils depends on avahi-daemon (= 0.8-5ubuntu3.1); however:
  Package avahi-daemon is not configured yet.

dpkg: error processing package avahi-utils (--configure):
 dependency problems - leaving unconfigured
Errors were encountered while processing:
 avahi-daemon
 avahi-utils
which invoke-rc.d, dpkg -S $(which invoke-rc.d), apt-cache policy $(dpkg -S $(which invoke-rc.d) | awk -F: '{print $1}')
/usr/bin/dpkg
/usr/bin/apt-cache
N0rbert avatar
zw flag
You have to try ask APT to help you. Run `sudo apt-get update; sudo apt-get install -f; sudo dpkg --configure -a` . Include all error messages into question, or upload full output to pastebin.
af flag
I've uploaded full output as you suggested.
Score:2
zw flag

You need to remove obsolete sysv-rc package and reinstall the corresponding package with invoke-rc.d inside it by

sudo dpkg -P --force-all sysv-rc
sudo apt-get install --reinstall init-system-helpers

and then retry running

sudo apt-get update
sudo apt-get install -f
sudo dpkg --configure -a
af flag
I can't reinstall init-system-helpers. https://paste.ubuntu.com/p/TNfcwx4MfM/
N0rbert avatar
zw flag
Then you have to remove problematic package by `sudo apt-get purge sysv-rc` .
af flag
does not work againg - https://paste.ubuntu.com/p/Qdjh85tF6D/
N0rbert avatar
zw flag
Then lets force it `sudo dpkg -P --force-all sysv-rc` and then `sudo apt-get install --reinstall init-system-helpers` .
af flag
Thank you very much. Problem solved.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.