Ubuntu – How to force Ubuntu to detect external display

display

My laptop recognises external display devices if I connect them before booting the system, but many times it doesn't if I connect while the system is running. In this case, rebooting naturally solves the problem.

Is there a way to force Ubuntu to detect external displays? Opening up the display menu and pressing "Detect displays" does nothing.

Best Answer

Actually, you don't need to log out. Simply going to a VC with ctrl-alt-F1, restarting x with sudo service sddm restart and and going back to your graphical interface with ctrl-alt-F7 (or F2) should do it.

This way, you don't lose all your windows...