You need to enable JavaScript to run this app.
最新活动
大模型
产品
解决方案
定价
生态与合作
支持与服务
开发者
了解我们

Ubuntu系统Nvidia驱动异常,无法识别第二屏幕求助

Alright, let's tackle this Nvidia driver and dual-screen issue step by step—since everything works fine on Windows, we know the hardware is solid, so this is definitely an Ubuntu configuration problem. Here's a structured troubleshooting plan:

解决思路:Nvidia驱动失效+第二屏幕无法识别

1. 先确认Ubuntu能检测到你的Nvidia显卡

First, let's make sure the system actually sees your Nvidia GPU—if it's not detected, driver installs will do nothing. Open a terminal and run:

lspci | grep -E 'VGA|3D controller'

You should see two entries: one for Intel UHD 630, and another for your Nvidia card. If the Nvidia entry is missing:

  • Reboot into your BIOS/UEFI, check for settings like Optimus Mode, Hybrid Graphics, or Discrete GPU Enable—make sure the discrete Nvidia card isn't disabled.

2. 彻底清理残留的Nvidia驱动文件

Previous failed installs might have left conflicting packages. Let's wipe them clean:

  • Uninstall all Nvidia-related packages:
    sudo apt purge nvidia* nvidia-* libnvidia*
    
  • Remove unused dependencies and cached files:
    sudo apt autoremove && sudo apt autoclean
    
  • Reboot your system to ensure you're running on pure Intel integrated graphics.

3. Reinstall the correct Nvidia driver (manual, reliable method)

Skip the "Additional Drivers" auto-select and install the recommended driver directly:

  • Check which driver version is recommended for your GPU:
    ubuntu-drivers devices
    
    Look for the line marked recommended (e.g., nvidia-driver-535).
  • Install that specific driver:
    sudo apt install nvidia-driver-XXX  # Replace XXX with the recommended version number
    
  • After installation, install the dual-graphics management tool and switch to Nvidia:
    sudo apt install nvidia-prime
    sudo prime-select nvidia
    
  • Reboot again, then verify the driver works with:
    nvidia-smi
    
    If you see your Nvidia GPU's stats here, the driver is successfully installed.

4. Fix the second screen recognition issue

If the driver works but the second screen is still missing:

  • Double-check your monitor cable is plugged into the Nvidia card's port, not the motherboard's Intel port—Windows might auto-switch to discrete GPU output, but Ubuntu needs this physical connection.
  • Open Nvidia Settings via terminal:
    nvidia-settings
    
    Go to X Server Display Configuration, click "Detect Displays"—if the second screen shows up, set your preferred resolution/position, click "Apply", then "Save to X Configuration File".
  • If that fails, try updating your kernel (old kernels often have poor new GPU support on Ubuntu 18.04):
    sudo apt install linux-generic-hwe-20.04
    
    Reboot and check again.

5. Troubleshoot Xorg configuration (last resort)

If all else fails, reset your Xorg config:

  • Backup the current config:
    sudo cp /etc/X11/xorg.conf /etc/X11/xorg.conf.bak
    
  • Generate a fresh Nvidia Xorg config:
    sudo nvidia-xconfig
    
  • Reboot and test the displays again.

内容的提问来源于stack exchange,提问作者Shino

火山引擎 最新活动