Solution Update

The answer below was updated to include my solution to screen tearing, that is, vsync activation with PRIME Synchronization in a laptop with a dual GPU setting (intel integrated graphics and nvidia GPU).

The horizontal lines problem doesn't happen anymore in Ubuntu 18.04, probably due to the extinction of Unity and the comeback of GNOME.

I have a MSI GS60 2PC Ghost Pro equipped with integrated Intel Graphics and a NVIDIA GeForce GTX 860M and I have Windows 10 and Ubuntu 16.04 on dual boot. I have absolutely no problems with the graphics on Windows, but I have visible horizontal lines going down the screen and a very annoying screen tearing while playing HD videos or games on Ubuntu.

I am using NVIDIA driver version 381.09 and the same happened using the version 375.39. NVIDIA X Server doesn't seem to be helpful at all to me, since no changes can be done there. I also installed Bumblebee, but I'm not sure how to use it (should I uninstall X Server first?).

I have tried this, this, this, this and this one with no success, but I believe the last link is the one closest to be my answer.

My /etc/X11/xorg.conf is the following (after modifying it as people suggested):

Section "ServerLayout"
    Identifier "layout"
    Screen 0 "nvidia"
    Inactive "intel"

Section "Device"
    Identifier "intel"
    Driver "modesetting"
    BusID "PCI:0@0:2:0"
    Option "AccelMethod" "None"
    Option "TearFree" "True"

Section "Screen"
    Identifier "intel"
    Device "intel"

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "PCI:1@0:0:0"
    Option "ConstrainCursor" "off"
    Option "TripleBuffer" "True"

Section "Screen"
    Identifier "nvidia"
    Device "nvidia"
    Option "AllowEmptyInitialConfiguration" "on"
    Option "IgnoreDisplayDevices" "CRT"

But nothing changed after that. This is really annoying and it really strains my eyes, and I think it even got worse compared to when I first installed Ubuntu on this machine. I just didn't try formatting my whole system yet, but I might do so, since I am also having problems with the wifi and bluetooth drivers (or firmwares) between the OSes.

Any suggestions? If any other outputs are necessary, just tell me and I'll edit the question.

Update: I noticed that switching to the Intel GPU on NVIDIA X Server using the xorg.conf attached to the post solved the issue, but the problem persists when using the NVIDIA GPU. I also tried increasing the refresh rate on CompizConfig Settings Manager (under Composite), but it didn't get rid of the horizontal lines moving. When I put my screen brightness to the max, I couldn't really see the lines anymore although I'm pretty sure they're still there.

  • "I am using NVIDIA driver version 381.09 (open source)" - Errm... Nvidia doesn't open source its drivers... Apr 14, 2017 at 17:34
  • I would suggest disabling the Intel GPU in the BIOS so that you don't have to mess with the dual GPUs. Apr 14, 2017 at 17:35
  • @AndroidDev well, if you go to "Software & Updates" under "Additional Drivers" it says "Using NVIDIA binary driver - version 381.09 from nvidia-381 (open source)". This is a beta release.
    – vamcs
    Apr 14, 2017 at 17:35
  • @AndroidDev Indeed but to be fair that's how it shows in Additional drivers for each and every version from a PPA. This has been going on for years and nobody seems to care.
    – user589808
    Apr 14, 2017 at 17:37
  • I'm aware it's a beta release. Actually, I even wrote an answer detailing how to install it to fix a bug that occurred when resuming from suspend. Apr 14, 2017 at 17:38

2 Answers 2


UPDATE (July 2018):

Now using Ubuntu 18.04, I have the driver version 390 installed and kernel parameter nvidia-drm.modeset=1 added to the GRUB boot sequence.

I get no screen tearing and correct screen resolution while using the nvidia GPU.

It's possible to check that PRIME Synchronization is activated by running xrandr --verbose | grep "PRIME" and the output will show

PRIME Synchronization: 1

I haven't tested it yet, but apparently NVIDIA fixed the problem with the new "PRIME Sync" functionality, and it's described here.

So it's necessary to have the Linux kernel above v4.5 to use it, but all the requirements are outlined in the link above.

The NVIDIA developer also warned me that some problems popped up (which can be found here) and that maybe it's best to wait a bit until they're fixed.

And about the horizontal lines, I am still not sure. Maybe updating Ubuntu to 17.04 and fixing the GPU problems will help. I'll update the answer in regards to that if I find anything.


enter image description here

Change the settings to the NVIDIA On-Demand.I just changed it and issue resolved.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .