When I'm at home, I put my Lenovo notebook on a docking station with two external monitors attached. But I can't get the monitors to work the way I would like them to. Whenever I change the monitor settings, all the displays start to flicker (and continue to flicker until I restart). During the flickering I occasionally see fragments of the desktop but only very briefly.

Before this setup I had the same setup but with an HP 8460p (and dockingstation) running LM 17.3. There, everything worked like a charm and I could arrange the monitors over the 'Diplay' settings window.

One of the external monitors is attached to the docking station over HDMI, the other is attached over Display Port. I'm using the most recent NVIDIA drivers available in 'Driver Manager' after adding 'ppa:graphics-drivers/ppa' (nvidia-378, version 378.13).

When I dock the notebook and start it up, usually, one of two things happens (might change between reboots, never sure which one it will be):
* Either all three displays (two external and the internal) have 1080p resolution and show the same output (mirrored).
* Or, they are arranged as three separate monitors in the following order and resolution (left to right): [Internal, 4K] - [Ext1, 1080p] - [Ext2, 1080p]. In this case, there is panning, when I move the cursor on the 4K display.

However, if I open 'Display' settings, and change things accordingly, I run into the the flickering issue mentioned above. The same flickering problem happens when I use 'NVIDIA X Server Settings' to change things (note that for some reason the internal display is not listed in 'NVIDIA X Server Settings, only the two external monitors). I have had a bit of success by issuing xrandr commands directly that I put together after reading another thread (viewtopic.php?f=59&t=239368). When the monitors are recognized as separate monitors (second scenario described above), I can change the resolution of the internal display with the command

. Note that the resolution of the internal display is set to 1080p but it becomes inaccessible. I can still move the cursor between the two external monitors but not to the internal one. If I change the position of any display with 'xrandr' using the '--pos' or '--right-of' flag, the displays start to flicker.

studersi wrote:Before this setup I had the same setup but with an HP 8460p (and dockingstation) running LM 17.3. There, everything worked like a charm and I could arrange the monitors over the 'Diplay' settings window.

I'm seeing more monitor detection and configuration problems in Mint 18 and other users are saying the same thing: "everything worked fine in Mint 17.3". I would personally switch back to Mint 17.3.

studersi wrote:(note that for some reason the internal display is not listed in 'NVIDIA X Server Settings, only the two external monitors)

Only the monitors connected to the Nvidia GPU will be shown in Nvidia Settings.

From previous multi-monitor topics I was involved in, there were less problems when the laptop's display was on the left.

studersi wrote:Before this setup I had the same setup but with an HP 8460p (and dockingstation) running LM 17.3. There, everything worked like a charm and I could arrange the monitors over the 'Diplay' settings window.

I'm seeing more monitor detection and configuration problems in Mint 18 and other users are saying the same thing: "everything worked fine in Mint 17.3". I would personally switch back to Mint 17.3.

Unfortunatly, the flickering issue also happens with LM 17.3 on this notebook; I had already tried that. Additionally, there are also other components that are not supported yet under LM 17.3 (namely the WiFi card).

roblm wrote:

studersi wrote:(note that for some reason the internal display is not listed in 'NVIDIA X Server Settings, only the two external monitors)

Only the monitors connected to the Nvidia GPU will be shown in Nvidia Settings.

Ok, but my current PRIME Profile is 'NVIDIA (Performance Mode)'. Shouldn't it be using the NVIDIA graphics card?

roblm wrote:From previous multi-monitor topics I was involved in, there were less problems when the laptop's display was on the left.

I could move the notebook to the left, that's not too much of a problem. But there are still a few problem, notably that most of the times, my desktop is mirrored over the three displays. If it is not mirrored (which just randomly happens after booting), the internal display uses 4K resolution and as soon as I change it to 1080p I cant move the mouse cursor to that display anymore.

studersi wrote:Ok, but my current PRIME Profile is 'NVIDIA (Performance Mode)'. Shouldn't it be using the NVIDIA graphics card?

Yes, the Nvidia GPU is being used for rendering the graphics but I'm talking about the physical ouputs on the notebook being hard-wired to the Intel or Nvidia GPUs. On a portable device with hybrid graphics, the internal display and usually the VGA output are connected to the Intel GPU and the HDMI output is connected to the Nvidia GPU.

The current saved configuration in the monitors.xml file shows the 3 displays are cloned. Open the File Manager and go to /home/your-user-name/.config and remove that file. Then open Preferences > Display and move output eDP-1-1 to the left, followed by DP-3.1 and DP-3.2

Set the resolution of eDP-1-1 to 1920x1080. The checkbox next to Mirror Displays should not be marked. Then click the Apply button. If you can't move the cursor to eDP-1-1, then try using this command:

roblm wrote:
The current saved configuration in the monitors.xml file shows the 3 displays are cloned. Open the File Manager and go to /home/your-user-name/.config and remove that file. Then open Preferences > Display and move output eDP-1-1 to the left, followed by DP-3.1 and DP-3.2

Set the resolution of eDP-1-1 to 1920x1080. The checkbox next to Mirror Displays should not be marked. Then click the Apply button. If you can't move the cursor to eDP-1-1, then try using this command:

I had tried deleting ~/.config/monitors.xml and undoing the mirroring as well as arranging the displays from Preferences > Display. But anytime I do, I run into the flickering issue and have to reboot.
And when i open Preferences > Display first of all, the fans in the notebook start to spin up and I can barely change anything in there.

Same here: When I issue this command, the screens start flickering and I have to reboot.

However, I did make some progress since I wrote my last post. When the screens are mirrored, I can modify the file ~/.config/monitors.xml, log out, log back in. After this, the desktop is set up the way I specified it without any flickering issues.
Note that the order of the displays is: [DP-3.2] - [DP-3.1] - [eDP-1-1] (all 1080p).

The file monitors.xml is overwritten from time to time so I have to reconfigure it on a regular basis.

The internal display eDP-1-1 does not allow tiling (windows try to snap to the edges but then the window jumps to another screen DP-3.2). Nor can I add any panels to it.

I can remove the notebook from the docking station while it is running and the screen resolution and desktop adapts accordingly. But when I put the notebook onto the docking station while it is running or if I close and reopen the lid of the notebook, the flickering returns.

Log out and back in. If the 3 displays are not correct, then use the xrandr command again. If still not correct, then post the Xorg.0.log file.
If there is a problem getting back to the desktop, then press Ctrl+Alt+F1 to enter the virtual console tty1. Log in and then type this command to remove the 10-monitor.conf file:

If you can't enter tty1, then press Ctrl+Alt+Delete to reboot and select Recovery Mode at the GRUB boot menu. If no menu shows, then hold down the Shift key while starting. In the menu, select “root - drop to root shell prompt”. When asked for the root password, just type your user password. Then change the file permissions to read and write by typing:

Was there ever a resolution to this issue? I'm having the exact same issue with my new Thinkpad P51 in Mint 18, using a ThinkPad ultra dock and 2 Dell monitors (which I don't have in front of me right now to check the model on).

After that, the displays are set up almost as intended. The three displays have 1080p resolution and are aligned side by side. The mouse moves from display to display without problems.

I added a dock on the second monitor as well but I can't add one on the built in screen (to the right). Also, tiling doesn't work on the built in screen, when windows are dragged to the border of the screen they jump to one of the two Samsung monitors (where they do snap to the border like they were supposed to on the built in screen).

This setup is rather fragile. When the notebook is removed from the dock or a display is turned off while Linux Mint is logged in, the displays start acting up again and reboot will not fix it. In this case I just run the script again, log out, and log back in again.

Hope this helps, let me know how this works out for you or if you find a better solution

Wrote a short script similar to the OP's that copies a good, known-working monitors.xml file on startup to prevent my screens from being messed up.

The issue is that the system will randomly and periodically stop displaying and go to the flickering that the OP mentioned. Sometimes this is a result of the screen-saver satrting but other times it just happens if the system sits idle too long. I'll come back to a blank screen laptop fan running full speed. I can get to different TTY's to kill/restart cinnamon (pkill cinnamon).

Troubleshooting done:
-Saw that kernel 4.13 was available in MintUpdate. Pulled it down and still have the issue (Issue exists in 4.10, 4.11, 4.13 from the repo's).
-Tested the kernel parameter intel_idle.max_cstate=1 and this helped dramatically, could go several days without issues but it didn't completely fix the issue
-Checked .xsession-errors and nothing particularly useful as I can't tell when the events were generated. Some items about failing to connect to Mir and a WM error about failing to open X Display :0
-Ensured newest Nvidia updates were installed
-Ensured newest Intel microcode was installed

After some testing, it looks like anything that causes the monitors to power off (physically powering them off or software) recreates the issue. So disabling the 'Turn off the screen' option in Power Management prevents the issue entirely. Unfortunately this does mean the monitors stay on all the time (obviously). the machine has been running with out issue with 'Turn off the screen' option disabled in Cinnamon's Power Management menu.

At this point, I'm not sure where the problem exists (nvidia, kernel, power management, or cinnamon). If anyone has any ideas on where to keep looking, please let me know.

Hey all, having the same problem with a Lenovo P50 and dock. I started out connecting two monitors directly to the laptop, one HDMI and one DisplayPort. This was glitchy for several reasons. If I plugged the monitors in while the laptop was off or in sleep mode, they wouldn't work when I turned it on. I would have to unplug one of them and plug it back in, then they might work. I carry my laptop around at work a lot, and every time I get back to my desk and plug the monitors in it takes three tries, each time does something different until the third time all monitors work correctly.

Well I just got the dock and figured that might work better, but found I cannot get anything working with it. Sometimes, I can get one external monitor working but I have it oriented vertically so I need to rotate the screen. When I go into settings and try to set the rotation, the screen starts blinking on and off until I kill the desktop. Interestingly, at the login screen, one of the external monitors always works correctly. After logging in the screen starts blinking if either of the monitors are plugged in.

I am experienced with Linux from a server standpoint but have been using a Mac as my laptop for years. Just switched to Mint so I'm still learning how the desktop stuff is set up. I don't mind troubleshooting this but I'm not sure exactly where all to look.

I'll try some of the workarounds above, but it sounds like things are still a bit fragile.

hrturner wrote:The issue is that the system will randomly and periodically stop displaying and go to the flickering that the OP mentioned. Sometimes this is a result of the screen-saver satrting but other times it just happens if the system sits idle too long. I'll come back to a blank screen laptop fan running full speed.

hrturner wrote:After some testing, it looks like anything that causes the monitors to power off (physically powering them off or software) recreates the issue. So disabling the 'Turn off the screen' option in Power Management prevents the issue entirely.

I usually turn off these options on my laptops, so I never had this problem. But I can attest that I have the same issue if I manually turn off one of the displays.

supergreg wrote:I am experienced with Linux from a server standpoint but have been using a Mac as my laptop for years. Just switched to Mint so I'm still learning how the desktop stuff is set up. I don't mind troubleshooting this but I'm not sure exactly where all to look.

My guess would be that there is either a bug in the xrandr command or the Nvidia graphics driver, my money would be on the former. But it's only a guess.

supergreg wrote:I'll try some of the workarounds above, but it sounds like things are still a bit fragile.

The workaround I described above is working fairly well for me so you could give it a try. But be sure to log out before undocking and docking. Not sure how convenient that would be if you have to do it frequently though; I only need to undock/dock maybe once a day or twice at most and often the notebook is turned off anyway.

Now I can change the display settings using the standard Display menu, I can have panels and tiling on the 3rd monitor, dock and undock the notebook, and the screens don't flicker anymore whenever a setting changes.

The only problem that remains is when docking/undocking, some of the icons don't scale correctly but that was always a problem when changing from 4k to 1080p and back. The solution is simple: Alt+F2 > type 'r' > hit Enter to reload Cinnamon.

Note that this driver is not available for Linux on http://www.nvidia.com/Download/index.aspx but it is available for Windows. The most recent version of the driver for Linux that is available on the Nvidia Website is version 384.111. I'm not sure if this driver is in the official Linux Mint repository, it might be in this one that I think I added a while back when I tried to solve the problem: