First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
waffeln

First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by waffeln »

Hello LM forums,

this is my first time posting and after years of working with Windows since my childhood and only using Linux occasionally the time has come for me to give Linux a serious try.

Unfortunately however, i'm struggling to get my graphics setup properly running. My laptop has an iGPU (Intel HD 630 afaik) and a dedicated GPU (GTX 1050) that's also outputs to the HDMI port.

On first boot of LM Cinnamon it was able to detect both my internal display and external monitor that i permanently use but after switching to the nvidia-driver-390 for better performance it wasn't able to detect my external display any more. Upon that i installed the NVIDIA 410 driver from their website with a lot of hassle (signed driver not working because of missing keys, then disabling secure boot to install it unsigned etc.).

And now i'm sitting here with *only* my external monitor working and not my internal one. That only display a non-blinking terminal line that you commonly see on computer boot-ups. When LM boots or shuts down it's logo is display on the internal screen.
Also for some reason i can't do Ctrl + Alt + F1 any more to switch to that headless terminal that i used to install the NVIDIA driver outside an X server.
Finally, in the driver manager (see attachment) i can't select another driver any more and i got no clue why (greyed out).

I'll provide any requested information as fast as i can!

Regards, waffeln =)
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
trytip
Level 14
Level 14
Posts: 5366
Joined: Tue Jul 05, 2016 1:20 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by trytip »

well first off all you should uninstall the driver you installed from their website
Image
waffeln

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by waffeln »

trytip wrote: Mon Dec 17, 2018 1:06 pm well first off all you should uninstall the driver you installed from their website
How do i do that? I didn't install with apt-get which is the only way i know how to uninstall linux apps right now...

I used the NVIDIA .run file for installation.
User avatar
trytip
Level 14
Level 14
Posts: 5366
Joined: Tue Jul 05, 2016 1:20 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by trytip »

i don't know i never installed nvidia like that. go back to where you installed it and learn how to remove it, there should be some instructions how to run the uninstaller
Image
User avatar
roblm
Level 15
Level 15
Posts: 5939
Joined: Sun Feb 24, 2013 2:41 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by roblm »

waffeln wrote: On first boot of LM Cinnamon it was able to detect both my internal display and external monitor that i permanently use but after switching to the nvidia-driver-390 for better performance it wasn't able to detect my external display any more.
Did you install nvidia-prime (apt install nvidia-prime), which is needed for your Optimus system to use the Nvidia driver?

waffeln wrote: Also for some reason i can't do Ctrl + Alt + F1 any more to switch to that headless terminal that i used to install the NVIDIA driver outside an X server.
First use these commands to remove a configuration file created during the installation and update the initial ramdisk:

Code: Select all

sudo rm /etc/modprobe.d/nvidia-installer-disable-nouveau.conf
sudo update-initramfs -u
Try pressing Ctrl+Alt+F2. If that doesn’t work, try F3 through F6. If one of those works, then change to the folder that has the Nvidia driver, usually Downloads: cd /home/your-user-name/Downloads

Stop the Display Manager: sudo service lightdm stop

To uninstall the driver, add --uninstall to the .run file. For example:
sudo sh NVIDIA-Linux-x86_64-384.130.run --uninstall

Answer Yes at any screen and ignore any error messages. After the uninstallation, type reboot


If none of those tty screens work, then you will need to boot into Recovery Mode. At the GRUB boot menu, select Recovery Mode. If no menu shows, then hold down the Shift key while starting. In the menu, select “root - drop to root shell prompt”.
Press ENTER. Then change the file permissions to read and write: mount -o remount,rw /

Change to the folder that has the Nvidia driver, usually Downloads:
cd /home/your-user-name/Downloads

To uninstall the driver, add --uninstall to the .run file. For example:
sh NVIDIA-Linux-x86_64-384.130.run --uninstall

Answer Yes at any screen and ignore any error messages. After the uninstallation, type reboot


On an Optimus laptop (integrated Intel+Nvidia card), there are additional steps involved if you want to install a driver downloaded from Nvidia’s website, because the nvidia-installer will overwrite two OpenGL modules used by the Intel GPU. This was not possible before Mint 19. I have just finished a guide on how to do that. A special script must be created to switch GPUs.

If you’re curious, go down to my second post on page 2 in this topic, under the section:
How to install the Nvidia driver on an Optimus laptop (integrated Intel + Nvidia card)

viewtopic.php?f=59&t=154932

However, most new Mint users should use the distro’s package manager to install the Nvidia driver. Switching GPUs will be quicker and troubleshooting problems will be easier.
waffeln

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by waffeln »

Thanks for the extremely elaborate answer,
i was able to uninstall a* driver by running sudo nvidia-uninstall and now both of my screens are working, but now i get screen tearing, generally bad performance and some graphics bugs - just like when i freshly installed LM.
The graphics bug renders a ~10px black border for a few frames around any normal system window (like settings) when i hover between different items.

Also i still can't change the driver i wanna use just as in the attachment of the original post. It still says i'm using a custom driver and i can't select the other two.

Ctrl + Alt + F1 also works now (only on my internal screen but i think that's how it's supposed to be).

Edit: The graphics bug only occurs on the integrated display and it's most apparent when you drag around windows (drags a black shadow behind it, similar to classic Windows window graphics bugs)
User avatar
roblm
Level 15
Level 15
Posts: 5939
Joined: Sun Feb 24, 2013 2:41 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by roblm »

waffeln wrote: Also i still can't change the driver i wanna use just as in the attachment of the original post. It still says i'm using a custom driver and i can't select the other two.
Use this command and reboot: apt autoremove; reboot

After doing that, install nvidia-prime and the Nvidia driver.

waffeln wrote: now i get screen tearing, generally bad performance and some graphics bugs - just like when i freshly installed LM.
The graphics bug renders a ~10px black border for a few frames around any normal system window (like settings) when i hover between different items.
Check this topic: viewtopic.php?f=208&t=272536

Is the screen tearing on the laptop’s screen or the external monitor?
If it’s on the external monitor, then you first need to know if the HDMI port is internally connected to the Nvidia GPU or Intel GPU. Open the NVIDIA X Server Settings utilty on the X Server Display Configuration page. If the words PRIME Display appears on the external monitor screen, then the HDMI port is connected to the Intel GPU.
waffeln

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by waffeln »

roblm wrote: Tue Dec 18, 2018 9:30 am Is the screen tearing on the laptop’s screen or the external monitor?
If it’s on the external monitor, then you first need to know if the HDMI port is internally connected to the Nvidia GPU or Intel GPU. Open the NVIDIA X Server Settings utilty on the X Server Display Configuration page. If the words PRIME Display appears on the external monitor screen, then the HDMI port is connected to the Intel GPU.
Okay so following your advice the black border smearing issues and the driver selection issue are now fixed and i switched to the distro-recommended NVIDIA drivers 390 from the Driver Manager. Both of my displays are working.

What's left is the aforementioned tearing and also frame dropping / bad performance (for instance very janky movement when dragging windows around).
I already knew but confirmed again that my monitor is connected to my GPU and that the internal display is driven by the CPU.
NVIDIA X Server Settings_005.jpg
The tearing is a lot worse on the internal display than the external one, but they both have the stuttering / frame dropping / jankyness.
The tearing on the internal display seems constant between two frames near the start of the lower third of the display, while the external display only occasionally has tearing at the very top or sometimes when stuttering (tested using this video on both screens with Firefox)
User avatar
roblm
Level 15
Level 15
Posts: 5939
Joined: Sun Feb 24, 2013 2:41 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by roblm »

waffeln wrote: I already knew but confirmed again that my monitor is connected to my GPU and that the internal display is driven by the CPU.
The laptop’s screen is connected to the Intel GPU and is driven by the modesetting driver (previously by the Intel driver), not the CPU.

waffeln wrote: What's left is the aforementioned tearing and also frame dropping / bad performance (for instance very janky movement when dragging windows around).
To correct the screen tearing on the laptop’s screen, add the kernel parameter nvidia-drm.modeset=1 to the grub file.

Use this command to open the file for editing: xed admin:///etc/default/grub
Change this line:

Code: Select all

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash"

To this:

Code: Select all

GRUB_CMDLINE_LINUX_DEFAULT="quiet splash nvidia-drm.modeset=1"
Then update grub and reboot: sudo update-grub; reboot

To correct tearing on the external monitor, open NVIDIA X Server Settings to the X Server Display Configuration page. Click the Advanced button. There are two options you can try, the Force Composition Pipeline and Force Full Composition Pipeline. Select one and then click the Save to X Configuration File button. If there is an existing /etc/X11/xorg.conf file, then it will be listed, so just click Save. If there is no file, then type /etc/X11/xorg.conf. One effect of using these options is a slight performance drop.


If there is a problem getting back to the desktop, then enter tty1 and use this command:
sudo nano -t /etc/default/grub
Use the Arrow keys to move the cursor. Remove the added parameter. Press Ctrl+X to save and exit.
Use this command to update grub and reboot: sudo update-grub; reboot
waffeln

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by waffeln »

Well... great.
After doing both changes the tearing on my external monitor seems to be fixed (but not the immense frame dropping and stuttering) and my internal display isn't working any more despite reversing both settings (and updating grub and rebooting) and making sure they endure after reboot and all.

I checked back in my Windows installation and made sure none of these are hardware issues: not even the shitty internal display has stutters or frame tearing there so it has to be my LM installation.
User avatar
roblm
Level 15
Level 15
Posts: 5939
Joined: Sun Feb 24, 2013 2:41 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by roblm »

Remove the xorg.conf file: sudo rm /etc/X11/xorg.conf
Log out and back in.

Post the output of inxi -Fxz
waffeln

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by waffeln »

My internal display works now.

Output of the command:

Code: Select all

System:    Host: Notebook Kernel: 4.15.0-42-generic x86_64
           bits: 64 gcc: 7.3.0
           Desktop: Cinnamon 3.8.9 (Gtk 3.22.30-1ubuntu1)
           Distro: Linux Mint 19 Tara
Machine:   Device: laptop System: Dell product: Inspiron 15 7000 Gaming serial: N/A
           Mobo: Dell model: 0TXG2N v: X02 serial: N/A
           UEFI: Dell v: 1.6.0 date: 03/27/2018
Battery    BAT0: charge: 69.3 Wh 100.0% condition: 69.3/74.0 Wh (94%)
           model: SMP DELL 71JF452 status: Full
CPU:       Quad core Intel Core i5-7300HQ (-MCP-) 
           arch: Skylake rev.9 cache: 6144 KB
           flags: (lm nx sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx) bmips: 19968
           clock speeds: max: 3500 MHz 1: 900 MHz 2: 900 MHz 3: 900 MHz
           4: 900 MHz
Graphics:  Card-1: Intel Device 591b bus-ID: 00:02.0
           Card-2: NVIDIA GP107M [GeForce GTX 1050 Mobile] bus-ID: 01:00.0
           Display Server: x11 (X.Org 1.19.6 )
           drivers: modesetting,nvidia (unloaded: fbdev,vesa,nouveau)
           Resolution: 1920x1080@60.00hz, 1920x1080@60.05hz
           OpenGL: renderer: GeForce GTX 1050/PCIe/SSE2
           version: 4.6.0 NVIDIA 390.77 Direct Render: Yes
Audio:     Card-1 Intel CM238 HD Audio Controller
           driver: snd_hda_intel bus-ID: 00:1f.3
           Card-2 NVIDIA GP107GL High Def. Audio Controller
           driver: snd_hda_intel bus-ID: 01:00.1
           Card-3 Logitech G430 Surround Sound Gaming Headset
           driver: USB Audio usb-ID: 001-007
           Card-4 C-Media driver: USB Audio usb-ID: 001-005
           Sound: Advanced Linux Sound Architecture v: k4.15.0-42-generic
Network:   Card-1: Realtek RTL8111/8168/8411 PCIE Gigabit Ethernet Controller
           driver: r8169 v: 2.3LK-NAPI port: d000 bus-ID: 02:00.0
           IF: enp2s0 state: up speed: 1000 Mbps duplex: full mac: <filter>
           Card-2: Intel Wireless 3165 driver: iwlwifi bus-ID: 03:00.0
           IF: wlp3s0 state: down mac: <filter>
Drives:    HDD Total Size: 2256.5GB (0.5% used)
           ID-1: /dev/sda model: INTEL_SSDSCKKF25 size: 256.1GB
           ID-2: /dev/sdb model: ST2000LM015 size: 2000.4GB
Partition: ID-1: / size: 20G used: 11G (58%) fs: ext4 dev: /dev/sda5
RAID:      No RAID devices: /proc/mdstat, md_mod kernel module present
Sensors:   System Temperatures: cpu: 46.0C mobo: N/A gpu: 0.0:42C
           Fan Speeds (in rpm): cpu: N/A
Info:      Processes: 211 Uptime: 5 min Memory: 1566.5/15907.4MB
           Init: systemd runlevel: 5 Gcc sys: 7.3.0
           Client: Shell (bash 4.4.191) inxi: 2.3.56 
User avatar
roblm
Level 15
Level 15
Posts: 5939
Joined: Sun Feb 24, 2013 2:41 pm

Re: First exDisplay not working, now inDisplay not working on Intel/NVIDIA Laptop, can't change Driver

Post by roblm »

After doing some checking, there already is an options nvidia-drm modeset=1 line in /lib/modprobe.d/nvidia-kms.conf, which has the same function as the kernel parameter nvidia-drm.modeset=1 added to the grub file, to eliminate tearing on the laptop’s screen.

To get better performance, I suggest you test newer Nvidia drivers. Remove the existing driver, reboot, use the apt autoremove command, and reboot again.

Use these commands to add the graphics-drivers PPA to get newer drivers:

Code: Select all

sudo apt-add-repository ppa:graphics-drivers/ppa
apt update
Then open Driver Manager. The previous Nvidia-390.77 driver will no longer be listed. You will probably see the 390.87, 396.54, 410.78 and 415.23 drivers.

You can test each driver. After installing the first one, you can install a different one without removing the existing one.

In System Settings > General, try enabling Disable compositing for full screen windows.
Under Effects, turn off all effects.
Under Window Tiling, turn it off.
Under Workspaces, turn it off.
Locked

Return to “Graphics Cards & Monitors”