Laptop screen blank after login when external monitor is not connected

To issue X commands from vt1, you need to specify the display. E.g.:

DISPLAY=:0 xrandr --auto

The monitors.xml config file is what GNOME uses to set up your multihead layout, however it's unlikely to be the source of your trouble. Theoretically deleting it and rebooting would force GNOME to go back to its defaults, if it was a bug in the GNOME config tool.

/etc/X11/xorg.conf is what X uses to configure itself. With your Intel HD graphics system you shouldn't need an xorg.conf at all; if there is one present, you can try deleting it and rebooting. But I don't think that's the source of your trouble either.

I don't think your .dmrc is relevant. You could test going into a guest session and see if you can reproduce it there; if you can then it's not going to be any of your user config files.

Beyond that, there's a variety of things that can cause this, but without seeing some logs or more test results it's hard to guess what it could be.

With Intel video cards, only two of your outputs can be live at one time. Especially with these newer systems they have a lot more than two possible outputs (HDMI, DVI, VGA, LVDS, ...) and there are various ways the linux kernel can get confused and hook up to the wrong thing. Sometimes it's a bit of a race condition what outputs get enabled. Some of the outputs that the video card is capable of aren't even hooked up to a physical port on your computer.

If the system were in front of me, the things I'd start looking at would be xrandr to see what possible outputs were present and what ones X thinks are connected. Next I'd enable graphics debugging (sudo xdiagnose, first option), and then reboot and study dmesg from with and without the problem to see how the kernel was picking which outputs to turn on.

Hopefully that gets you on a productive path. Blank screen bugs can be caused by a lot of different things and it's hard to diagnose it merely based on symptoms, but the above steps should get you far enough into the problem that it'll become diagnosable.


on Xubuntu 13.10 the file you want to delete is ~/.config/xfce/xfconf/xfce-perchannel-xml/displays.xml have a look for a similar file on your distribution. maybe it is named monitors.xml


Refresh your monitor config using the xrandr command line tool:

xrandr --auto

According to xrandr manpage, this will enable all screens that are connected but not displayed; and it will disable all screens that are 'enabled' but not actually connected.

For me, my laptop screen didn't wake up after sleep. My dual monitor was literally half awake. When I tried to open settings manager, it opened on my sleeping laptop screen, so was not visible. Fortunately, I was able to open terminal using a keyboard shortcut, and this displayed where I could see it, on the half-awake dual monitor. xrandr --auto restored the screens to their prior state.