多年来,我一直在计算机上运行带有 kde(kubuntu_desktop)的 ubuntu(18.04)。最近(在升级到 bionic 之后的某个时间点),每当我尝试发出 apt-get update / apt-get dist-upgrade 时,它都会删除 kubuntu_desktop 以及许多其他软件包,其中大部分与 kde 相关。我将在底部发布输出。
我的问题是 i) apt 如何决定要删除什么?我的印象是,这主要影响那些作为其他软件包的依赖而安装的软件包,这些软件包由于依赖软件包被删除而变得过时。当然还有旧内核。就我而言,我明确安装了 kubuntu_desktop。ii) 如何防止 kubuntu_desktop 被删除?
我运行了一次该过程,发现 kde/plasma 桌面不见了,于是手动重新安装了它(apt-get install kubuntu-desktop),但这并没有改变任何东西。在下一次 dist-upgrade 中,kubuntu_desktop 仍然在要删除的软件包列表中。
以下是完整输出:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer required:
cryfs fonts-hack fonts-hack-ttf libaribb24-0 libbasicusageenvironment1 libcolorcorrect5 libcrypto++6 libdvbpsi10 libebml4v5 libgps23 libgroupsock8 libkate1 libkwinglutils11
libkwinxrenderutils11 liblivemedia62 libmatroska6v5 libmicrodns0 libopenmpt-modplug1 libplacebo4 libqalculate6 libqalculate6-data libresid-builder0c2a libsdl-image1.2 libsidplay2
libtaskmanager6 libusageenvironment3 libva-wayland2 libvulkan1 libxcb-xv0 plasma-integration pulseaudio-module-gconf qml-module-org-kde-kconfig qml-module-org-kde-kholidays
qml-module-org-kde-qqc2desktopstyle qml-module-qtwebengine vlc-bin vlc-data vlc-l10n vlc-plugin-base vlc-plugin-notify vlc-plugin-qt vlc-plugin-samba vlc-plugin-skins2
vlc-plugin-video-splitter vlc-plugin-visualization
Use 'sudo apt autoremove' to remove them.
The following packages will be REMOVED:
bluedevil kate kde-config-screenlocker kinfocenter kscreen kubuntu-desktop kwin kwin-addons kwin-common kwin-x11 libkf5waylandserver5 libkscreenlocker5 libkwin4-effect-builtins1
libkwineffects11 milou plasma-dataengines-addons plasma-desktop plasma-framework plasma-nm plasma-pa plasma-vault plasma-wallpapers-addons plasma-widgets-addons plasma-workspace
print-manager sddm-theme-breeze vlc vlc-plugin-video-output
The following packages have been kept back:
libegl1-mesa libgbm1 libwayland-egl1-mesa
0 upgraded, 0 newly installed, 28 to remove and 3 not upgraded.
After this operation, 95.4 MB disk space will be freed.
Do you want to continue? [Y/n] n
根据要求,这是我的“sudo apt-cache policy apt”的输出
apt:
Installed: 1.6.3ubuntu0.1
Candidate: 1.6.3ubuntu0.1
Version table:
*** 1.6.3ubuntu0.1 500
500 http://de.archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages
500 http://security.ubuntu.com/ubuntu bionic-security/main amd64 Packages
100 /var/lib/dpkg/status
1.6.1 500
500 http://de.archive.ubuntu.com/ubuntu bionic/main amd64 Packages
“ls /usr/share/xsessions”的输出是
plasma.desktop