You need to enable JavaScript to run this app.
优惠活动
大模型
产品
解决方案
定价
更多

Ubuntu系统中修复多依赖损坏问题并安装/启动gnome-control-center的求助

Ubuntu系统中修复多依赖损坏问题并安装/启动gnome-control-center的求助

我最近在Ubuntu系统里遇到了大麻烦——不管是从桌面右键还是直接调用,都打不开设置面板。一开始我意识到是缺了gnome-control-center,但装的时候才发现这背后是一堆连锁的依赖问题,简直是多米诺骨牌效应。

我先跑了sudo apt-get update和sudo apt-get upgrade,结果系统说没有可安装的包,这就很奇怪。

当我直接输入gnome-control-center时,系统提示:

Command 'gnome-control-center' not found, but can be installed with:
sudo apt install gnome-control-center

但执行sudo apt install gnome-control-center时,直接报依赖损坏:

Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 gnome-control-center : Depends: gnome-control-center-data (< 1:3.37) but 1:3.38.5-1ubuntu2 is to be installed
 Recommends: gnome-online-accounts (>= 3.25.3) but it is not going to be installed
 Recommends: network-manager-gnome (>= 0.9.8) but it is not going to be installed
 Recommends: gnome-control-center-faces but it is not going to be installed
 Recommends: rygel but it is not going to be installed or
 rygel-tracker but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

查看gnome-control-center的版本策略:

$ apt policy gnome-control-center
gnome-control-center:
 Installed: (none)
 Candidate: 1:3.36.5-0ubuntu4
 Version table:
    1:3.36.5-0ubuntu4 500
       500 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
    1:3.36.1-1ubuntu5 500
       500 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages

我尝试单独装gnome-control-center-data,结果系统说已经是最新版了:

$ sudo apt install gnome-control-center-data
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
gnome-control-center-data is already the newest version (1:3.38.5-1ubuntu2).
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.

查看它的版本策略:

$ apt policy gnome-control-center-data
gnome-control-center-data:
 Installed: 1:3.38.5-1ubuntu2
 Candidate: 1:3.38.5-1ubuntu2
 Version table:
 *** 1:3.38.5-1ubuntu2 100
       100 /var/lib/dpkg/status
    1:3.36.5-0ubuntu4 500
       500 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
       500 http://archive.ubuntu.com/ubuntu focal-updates/main i386 Packages
    1:3.36.1-1ubuntu5 500
       500 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages
       500 http://archive.ubuntu.com/ubuntu focal/main i386 Packages

类似的情况也发生在gnome-online-accounts上,装的时候同样报依赖不匹配:

$ sudo apt install gnome-online-accounts
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 gnome-online-accounts : Depends: libgoa-1.0-0b (= 3.36.1-0ubuntu1) but 3.38.1-1ubuntu1.1 is to be installed
 Depends: libgoa-backend-1.0-1 (= 3.36.1-0ubuntu1) but 3.38.1-1ubuntu1.1 is to be installed
 Depends: python3-macaroonbakery but it is not going to be installed
 Recommends: gnome-control-center (>= 3.6.1) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.

查看它的版本策略:

$ apt policy gnome-online-accounts
gnome-online-accounts:
 Installed: (none)
 Candidate: 3.36.1-0ubuntu1
 Version table:
    3.36.1-0ubuntu1 500
       500 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
    3.36.0-1ubuntu1 500
       500 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages

我的系统信息如下:

$ uname -a
Linux <username> 5.14.0-1054-oem #61-Ubuntu SMP Fri Oct 14 13:05:50 UTC 2022 x86_64 x86_64 x86_64 GNU/Linux

我查了好几个相关的问题帖子,尝试了里面的方法,结果不仅没用,有些autoremove操作反而让更多依赖坏掉了。

后来终于找到一个帖子,按照方法成功装上了gnome-control-center,但装上之后根本打不开——鼠标转几分钟加载圈就变回普通指针,完全没反应。

现在查看gnome-control-center的状态:

apt policy gnome-control-center
gnome-control-center:
 Installed: 1:3.36.5-0ubuntu4
 Candidate: 1:3.36.5-0ubuntu4
 Version table:
 *** 1:3.36.5-0ubuntu4 500
       500 http://archive.ubuntu.com/ubuntu focal-updates/main amd64 Packages
       100 /var/lib/dpkg/status
    1:3.36.1-1ubuntu5 500
       500 http://archive.ubuntu.com/ubuntu focal/main amd64 Packages

从终端启动的话,会报符号查找错误:

gnome-control-center: symbol lookup error: /usr/lib/x86_64-linux-gnu/samba/libsamdb-common.so.0: undefined symbol: ldb_msg_element_add_value, version LDB_2.2.3

我尝试查找相关的包,但系统找不到:

apt-cache policy libsamdb-common.so.0
N: Unable to locate package libsamdb-common.so.0
N: Couldn't find any package by glob 'libsamdb-common.so.0'
N: Couldn't find any package by regex 'libsamdb-common.so.0'

apt-cache policy samba/libsamdb-common.so.0
N: Unable to locate package samba/libsamdb-common.so.0
N: Couldn't find any package by glob 'samba/libsamdb-common.so.0'
N: Couldn't find any package by regex 'samba/libsamdb-common.so.0'

用ldd查看这个库的依赖:

ldd /usr/lib/x86_64-linux-gnu/samba/libsamdb-common.so.0
linux-vdso.so.1 (0x00007ffdfcfcb000)
libsamba-hostconfig.so.0 => /lib/x86_64-linux-gnu/libsamba-hostconfig.so.0 (0x00007f787c5ba000)
libreplace.so.0 => /usr/lib/x86_64-linux-gnu/samba/libreplace.so.0 (0x00007f787c5b5000)
libndr-samba.so.0 => /usr/lib/x86_64-linux-gnu/samba/libndr-samba.so.0 (0x00007f787c45e000)
libcli-ldap-common.so.0 => /usr/lib/x86_64-linux-gnu/samba/libcli-ldap-common.so.0 (0x00007f787c454000)
libsamba-sockets.so.0 => /usr/lib/x86_64-linux-gnu/samba/libsamba-sockets.so.0 (0x00007f787c439000)
libflag-mapping.so.0 => /usr/lib/x86_64-linux-gnu/samba/libflag-mapping.so.0 (0x00007f787c432000)
libsamba-errors.so.1 => /lib/x86_64-linux-gnu/libsamba-errors.so.1 (0x00007f787c2e7000)
libsamba-util.so.0 => /lib/x86_64-linux-gnu/libsamba-util.so.0 (0x00007f787c274000)
libsamba-security.so.0 => /usr/lib/x86_64-linux-gnu/samba/libsamba-security.so.0 (0x00007f787c252000)
libndr.so.1 => /lib/x86_64-linux-gnu/libndr.so.1 (0x00007f787c235000)
libsocket-blocking.so.0 => /usr/lib/x86_64-linux-gnu/samba/libsocket-blocking.so.0 (0x00007f787c230000)
libtevent-util.so.0 => /lib/x86_64-linux-gnu/libtevent-util.so.0 (0x00007f787c227000)
libsamba-debug.so.0 => /usr/lib/x86_64-linux-gnu/samba/libsamba-debug.so.0 (0x00007f787c21c000)
libsys-rw.so.0 => /usr/lib/x86_64-linux-gnu/samba/libsys-rw.so.0 (0x00007f787c217000)
libpthread.so.0 => /lib/x86_64-linux-gnu/libpthread.so.0 (0x00007f787c1f5000)
libtalloc.so.2 => /lib/x86_64-linux-gnu/libtalloc.so.2 (0x00007f787c1e6000)
libldb.so.2 => /lib/x86_64-linux-gnu/libldb.so.2 (0x00007f787c1b2000)
libtevent.so.0 => /lib/x86_64-linux-gnu/libtevent.so.0 (0x00007f787c19b000)
libc.so.6 => /lib/x86_64-linux-gnu/libc.so.6 (0x00007f787bfaf000)
libserver-role.so.0 => /usr/lib/x86_64-linux-gnu/samba/libserver-role.so.0 (0x00007f787bfaa000)
libgnutls.so.30 => /lib/x86_64-linux-gnu/libgnutls.so.30 (0x00007f787bdad000)
libtdb.so.1 => /lib/x86_64-linux-gnu/libtdb.so.1 (0x00007f787bd93000)
libbsd.so.0 => /lib/x86_64-linux-gnu/libbsd.so.0 (0x00007f787bd7b000)
libndr-nbt.so.0 => /lib/x86_64-linux-gnu/libndr-nbt.so.0 (0x00007f787bd4f000)
libasn1util.so.0 => /usr/lib/x86_64-linux-gnu/samba/libasn1util.so.0 (0x00007f787bd46000)
libndr-standard.so.0 => /lib/x86_64-linux-gnu/libndr-standard.so.0 (0x00007f787b9e3000)
libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007f787b9c7000)
libiov-buf.so.0 => /usr/lib/x86_64-linux-gnu/samba/libiov-buf.so.0 (0x00007f787b9c2000)
libinterfaces.so.0 => /usr/lib/x86_64-linux-gnu/samba/libinterfaces.so.0 (0x00007f787b9bb000)
libnsl.so.1 => /lib/x86_64-linux-gnu/libnsl.so.1 (0x00007f787b99f000)
libtime-basic.so.0 => /usr/lib/x86_64-linux-gnu/samba/libtime-basic.so.0 (0x00007f787b99a000)
libgenrand.so.0 => /usr/lib/x86_64-linux-gnu/samba/libgenrand.so.0 (0x00007f787b995000)
libicuuc.so.66 => /lib/x86_64-linux-gnu/libicuuc.so.66 (0x00007f787b7af000)
libsystemd.so.0 => /lib/x86_64-linux-gnu/libsystemd.so.0 (0x00007f787b6f7000)
libicui18n.so.66 => /lib/x86_64-linux-gnu/libicui18n.so.66 (0x00007f787b3f8000)
libdl.so.2 => /lib/x86_64-linux-gnu/libdl.so.2 (0x00007f787b3f1000)
/lib64/ld-linux-x86-64.so.2 (0x00007f787c62f000)
libp11-kit.so.0 => /lib/x86_64-linux-gnu/libp11-kit.so.0 (0x00007f787b2b8000)
libidn2.so.0 => /lib/x86_64-linux-gnu/libidn2.so.0 (0x00007f787b296000)
libunistring.so.2 => /lib/x86_64-linux-gnu/libunistring.so.2 (0x00007f787b112000)
libtasn1.so.6 => /lib/x86_64-linux-gnu/libtasn1.so.6 (0x00007f787b0fc000)
libnettle.so.8 => /lib/x86_64-linux-gnu/libnettle.so.8 (0x00007f787b0b6000)
libhogweed.so.6 => /lib/x86_64-linux-gnu/libhogweed.so.6 (0x00007f787b06e000)
libgmp.so.10 => /lib/x86_64-linux-gnu/libgmp.so.10 (0x00007f787afeb000)
libmd.so.0 => /lib/x86_64-linux-gnu/libmd.so.0 (0x00007f787afde000)
libicudata.so.66 => /lib/x86_64-linux-gnu/libicudata.so.66 (0x00007f787951b000)
libstdc++.so.6 => /lib/x86_64-linux-gnu/libstdc++.so.6 (0x00007f7879302000)
libm.so.6 => /lib/x86_64-linux-g
相关产品推荐
方舟 Agent Plan

超全模态模型 × Harness 升级,最新支持 Deepseek-V4.1-Flash、GLM-5.3 系列、Doubao-Seedream-5.0-pro、Kimi-K3 (部分), 限时 9.9 元起

最近更新时间:2026.04.23 08:57:40