升级至Ubuntu 17.10后启动时窗口管理器崩溃,仅OpenBox可用
Hey there, let's work through this post-upgrade crash issue together—major Ubuntu version jumps can definitely throw these kinds of curveballs. Here's a structured approach to get your full desktop environments back up:
1. Resolve Display Manager Conflicts
You mentioned using sudo lightdm to get into a session, which suggests a clash between GDM3 and LightDM is causing the boot-time crashes. Let's set a default manager to eliminate this:
- Switch to a TTY (Ctrl+Alt+F4) and run:
sudo dpkg-reconfigure lightdm - When prompted, select LightDM as your default display manager. This prevents the system from switching between managers on boot, a common source of window manager crashes.
2. Fix Broken Dependencies & Reinstall Desktop Components
Even if you reinstalled core packages, the upgrade might have left broken dependencies or mismatched versions. Run these commands to clean up and refresh your system:
sudo apt update sudo apt upgrade -f sudo apt autoremove sudo apt clean
Then reinstall the full Ubuntu 17.10 desktop stack to ensure all components are properly aligned:
sudo apt install --reinstall ubuntu-desktop gnome-shell ubuntu-gnome-desktop
3. Reset Corrupted Desktop Configurations
User-specific config files often get corrupted during upgrades. Let's reset your GNOME settings to default (we'll back up the old ones first just in case):
- Back up existing configs:
mv ~/.config/gnome-shell ~/.config/gnome-shell.bak mv ~/.config/dconf ~/.config/dconf.bak - Reset the dconf database:
dconf reset -f /org/gnome/
Log out, then try selecting the Ubuntu desktop session from the login screen again.
4. Verify Graphics Driver Compatibility
Ubuntu 17.10 uses a newer Xorg stack, and outdated graphics drivers are a frequent cause of window manager crashes:
- For NVIDIA users: Reinstall your proprietary driver (replace
<version>with your installed driver number, e.g.,384):sudo apt install --reinstall nvidia-driver-<version> - For AMD users: Reinstall the open-source AMDGPU driver:
sudo apt install --reinstall xserver-xorg-video-amdgpu - For Intel users: Refresh the Intel graphics driver:
sudo apt install --reinstall xserver-xorg-video-intel
Reboot after reinstalling, then test the desktop sessions.
5. Test with a New User Account
If the above steps don't work, the issue might be isolated to your user profile. Create a test account to check:
sudo adduser testuser sudo usermod -aG sudo testuser
Log out and sign in as testuser. If the desktop environments work here, your original user's config files are the problem—you can migrate your data to the new account or continue debugging the old profile.
内容的提问来源于stack exchange,提问作者chad

