A second monitor won’t work on Displayport on Ubuntu.

Setup:

  • Thinkpad T430
  • Ubuntu 22.04
  • GNOME 42.5
  • Wayland
  • Graphics: NVC1/Mesa Intel HD Graphics 4000
  • 1st monitor with VGA/VGA cable
  • 2nd monitor with Displayport/HDMI cable

…and suddenly one day my 2nd monitor stopped working. No signal. Not recognized. I initially had an HDMI to Displayport adapter. After researching, I read that it could be the adapter. I changed the adapter with a Displayport to HDMI cable. Still nothing.

I have seen that others used xrandr to see if DP was listed. Mine didn’t list anything that said DP.

On a Lenovo forum, someone commented that they had Red Hat and they switched the BIOS display from Nvidia Optimus to Discrete. I did that and also disabled the auto detect/auto switch to Optimus. However, when I did that change and restarted, the display on the laptop went blank. I went back to the BIOS and switched the ‘auto detect Optimus’ to enable and restarted. Still nothing, blank screen. Changed the BIOS to the original setting. Restarted and the 2nd monitor was now recognized again.

Weird hack solution

  1. Go to the BIOS and change the Display to Discrete, reboot.
  2. The screen goes blank, hard restart.
  3. Go to the BIOS again and change back to Nvidia Optimus, reboot.
  4. Solved.