首页
学习
活动
专区
圈层
工具
发布
首页
学习
活动
专区
圈层
工具
MCP广场
社区首页 >问答首页 >当我试图升级Xubuntu 21.04时,avahi-daemon出现了一些错误。

当我试图升级Xubuntu 21.04时,avahi-daemon出现了一些错误。
EN

Ask Ubuntu用户
提问于 2021-10-10 15:24:43
回答 1查看 1.4K关注 0票数 1

我有Xubuntu 21.04 64位。每次我进行“适当升级”时都会收到错误消息:

代码语言:javascript
运行
复制
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)

你能帮我一下吗?谢谢。

我试过这个命令来获取更多信息:

代码语言:javascript
运行
复制
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
代码语言:javascript
运行
复制
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
EN

回答 1

Ask Ubuntu用户

回答已采纳

发布于 2021-10-10 17:58:55

您需要删除过时的sysv-rc包并通过以下方式重新安装相应包装invoke-rc.d里面

代码语言:javascript
运行
复制
sudo dpkg -P --force-all sysv-rc
sudo apt-get install --reinstall init-system-helpers

然后重试运行

代码语言:javascript
运行
复制
sudo apt-get update
sudo apt-get install -f
sudo dpkg --configure -a
票数 2
EN
页面原文内容由Ask Ubuntu提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://askubuntu.com/questions/1368464

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档