Ubuntu Desktop 22.04 LTS最小化安装后卸载GNOME并保留LXDE的相关问题咨询
Ubuntu Desktop 22.04 LTS最小化安装后卸载GNOME并保留LXDE的相关问题咨询
问题背景与操作过程
我在通过apt install lxde安装LXDE桌面环境后,尝试卸载GNOME桌面环境,但遇到了一系列问题:
- 执行
apt purge -y gnome gnome-core时,系统提示:Package gnome is not installed, so not removed.
Package gnome-core is not installed, so not removed. - 尝试执行
apt purge ubuntu-desktop,同样得到:Package ubuntu-desktop is not installed, so not removed.
- 但重启后,登录界面仍显示“Ubuntu Default”选项,登录后还是原来的GNOME桌面环境
我查看了/usr/share/xsessions/目录,里面有LXDE.desktop、openbox.desktop、ubuntu-xorg.desktop、ubuntu.desktop这几个文件。删除openbox.desktop、ubuntu-xorg.desktop、ubuntu.desktop后,登录界面依然有“Ubuntu (default)”和“Ubuntu on Wayland”选项,选择前者还是会进入GNOME桌面。
关于我的情况
我使用的是Ubuntu Desktop 22.04 LTS最小化安装,系统是全新安装的。我知道直接安装Ubuntu Server再装LXDE可能更合适,但我的笔记本以太网接口损坏,Ubuntu Desktop的声音可以直接正常工作,不需要过多调试,而Ubuntu Server在我笔记本上的声音体验不好,所以希望解决方案仅基于Ubuntu Desktop环境。
我的问题
- 我的系统上到底有没有安装过
gnome-core?为什么能登录GNOME桌面环境,却显示这个包未安装? - 如何彻底卸载GNOME桌面环境?
- 如何移除登录界面上除LXDE外的所有桌面环境选项?
P.S. 请不要标记为重复问题。
备注:内容来源于stack exchange,提问作者John Smith




