(SOLVED) [NVIDIA] I connected an external display to my laptop. Now I can't open windows on my laptop's display.

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
DudeGuy
Level 1
Level 1
Posts: 13
Joined: Tue May 15, 2018 12:43 am

(SOLVED) [NVIDIA] I connected an external display to my laptop. Now I can't open windows on my laptop's display.

Post by DudeGuy »

QUICK SOLUTION
The solution to my problem was deleting the file /etc/X11/xorg.conf. I must have made a mistake when fiddling with underscan/resolution settings in the NVIDIA X Server settings. Also, I probably need to update my kernel. Thanks SMG!

Quick system specs
My computer is an Acer Nitro 5 laptop. It has an NVIDIA graphics card and it is running Linux Mint 19.1 Tessa 64-bit (XFCE).
My X.Org X Server version is 1.19.6.
Output of inxi -Fxxxrz: https://pastebin.com/Bm2bjvrJ

The problem:
Today, I got a second monitor, and connected it to my laptop with an HDMI cable. After some fiddling around, I was able to get it to work just fine, and I had windows on both monitors.

I restarted my computer, used GRUB to select Linux Mint, saw the splash screen (The Linux Mint logo), but then my laptop's monitor faded to black. The only thing on my screen was an underscore in the top-left corner. I hit Ctrl+Alt+F1 to open the command line. Then I did startx and fortunately, that worked. But I only had windows on my external display. On my laptop's display, it was just the command-line.

For some reason, display settings and NVIDIA X server settings can't detect my laptop's monitor. Screenshot: https://i.imgur.com/PDZ5SjR.jpg

Picture of what my setup looks like:
https://i.imgur.com/vx5uLpO.jpg

Things I have tried (that have done nothing):
  • Unplugging the external monitor (my laptop screen stays black)
  • Unplugging the external monitor, then restarting my computer.
  • Clicked "Detect Displays" in the NVIDIA X Server Settings
  • Looked at "System Reports," which mentions 2 crashes related to light-locker. Specifically: _usr_bin_light-locker.1000.crash, and _usr_bin_nvidia-settings.1000.crash. Screenshot: https://i.imgur.com/R7mEnKk.png Stack trace of _usr_bin_light-locker.1000.crash: https://pastebin.com/tVgZhgnY Stack trace of _usr_bin_nvidia-settings.1000.crash: https://pastebin.com/VbGAWhQQ
Additional info: Thanks in advance!
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 3 times in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
SMG
Level 25
Level 25
Posts: 31966
Joined: Sun Jul 26, 2020 6:15 pm
Location: USA

Re: [NVIDIA] I connected an external display to my laptop. Now I can't open windows on my laptop's display.

Post by SMG »

DudeGuy wrote: Thu Feb 25, 2021 4:14 am After some fiddling around
This appears to be the problem. I'm not sure why you posted a graphics issue in the Xfce desktop section of the forum, but I'll do my best to help.

You have a dual-graphics laptop with Intel and Nvidia. The default install of Mint permits switching between the two, however, it appears you do not like updating your software. The latest kernel is 4.15.0-136. You should be using it or something close to it if you are going to be using the latest Nvidia driver and expecting everything to work properly.

System:
Host: SomeLaptop Kernel: 4.15.0-20-generic x86_64 bits: 64 compiler: gcc
v: 7.3.0 Desktop: Xfce 4.12.3 tk: Gtk 2.24.31 info: xfce4-panel wm: xfwm4
dm: LightDM 1.26.0 Distro: Linux Mint 19.1 Tessa base: Ubuntu 18.04 bionic

Many dual graphics laptops have Nvidia running the external ports and Intel running the laptop screen. It appears you set up your computer to only run Nvidia which is why your laptop screen is blank. The modesetting I added in red is missing from your inxi output because you set up your system to only run with Nvidia.

Graphics:
Device-1: Intel vendor: Acer Incorporated ALI driver: i915 v: kernel
bus ID: 00:02.0 chip ID: 8086:591b
Device-2: NVIDIA GP107M [GeForce GTX 1050 Mobile]
vendor: Acer Incorporated ALI driver: nvidia v: 450.102.04 bus ID: 01:00.0
chip ID: 10de:1c8d
Display: server: X.Org 1.19.6 driver: nvidia, modesetting resolution: 1920x1080~60Hz
OpenGL: renderer: GeForce GTX 1050/PCIe/SSE2 v: 4.6.0 NVIDIA 450.102.04
direct render: Yes
DudeGuy wrote: Thu Feb 25, 2021 4:14 am
Additional info:
I do not know why you created an Xorg.conf file, but removing it would probably help bring back your laptop screen. I'm not sure exactly what you did in addition to creating that file, so I'm not sure if removing it will be the only thing needed.

From your Xorg log

Code: Select all

[     6.299] (**) OutputClass "Nvidia Prime" setting /dev/dri/card1 as PrimaryGPU
which means any screens being driven by Intel will get no output.

If you took a Timeshift snapshot before making all these changes, I suggest you revert to the snapshot and then provide your inxi info and exactly what the issue is/was before you started "fiddling".
Image
A woman typing on a laptop with LM20.3 Cinnamon.
DudeGuy
Level 1
Level 1
Posts: 13
Joined: Tue May 15, 2018 12:43 am

Re: [NVIDIA] I connected an external display to my laptop. Now I can't open windows on my laptop's display.

Post by DudeGuy »

SMG wrote: Thu Feb 25, 2021 4:53 pmThis appears to be the problem. I'm not sure why you posted a graphics issue in the Xfce desktop section of the forum, but I'll do my best to help.

You have a dual-graphics laptop with Intel and Nvidia. The default install of Mint permits switching between the two, however, it appears you do not like updating your software. The latest kernel is 4.15.0-136. You should be using it or something close to it if you are going to be using the latest Nvidia driver and expecting everything to work properly.

I do not know why you created an Xorg.conf file, but removing it would probably help bring back your laptop screen. I'm not sure exactly what you did in addition to creating that file, so I'm not sure if removing it will be the only thing needed.
Thanks for the response. I thought this would be the right place to make this post because I assumed it was an issue with window managers - this is the forum for desktops & window managers, after all.
Deleting xorg.conf solved the problem. That was actually the first thing I should have tried! :D
Perhaps I should elaborate on what I mean by "fiddling around" - this means using NVIDIA X Server settings to adjust resolution/underscan of the second screen. I then saved said configs to xorg.conf because NVIDIA X server settings told me I should.
I usually do like updating my software, but I don't know anything about updating kernels so I guess I'll have to look into that. I consider myself a casual Linux user so I don't know all the ins and outs of things like that.
Thanks again for your wisdom!
User avatar
SMG
Level 25
Level 25
Posts: 31966
Joined: Sun Jul 26, 2020 6:15 pm
Location: USA

Re: [NVIDIA] I connected an external display to my laptop. Now I can't open windows on my laptop's display.

Post by SMG »

DudeGuy wrote: Thu Feb 25, 2021 5:42 pmPerhaps I should elaborate on what I mean by "fiddling around" - this means using NVIDIA X Server settings to adjust resolution/underscan of the second screen. I then saved said configs to xorg.conf because NVIDIA X server settings told me I should.
The way dual graphics (Intel-Nvidia) is handled has changed over the Mint versions and I do not know exactly how it was handled in LM19.1. I would have thought that Nvidia X Server should have known you had both Intel and Nvidia and saved the file properly, but maybe the files I'm used to working with were different with that version.

I know LM19.3 has the nvidia-prime-applet that permits switching between Intel and Nvidia, but I do not recall if it was out for LM19.1 and how it might have changed over time.
DudeGuy wrote: Thu Feb 25, 2021 5:42 pmI usually do like updating my software, but I don't know anything about updating kernels so I guess I'll have to look into that. I consider myself a casual Linux user so I don't know all the ins and outs of things like that.
Thanks again for your wisdom!
You're welcome. Glad both screens are working again. There should be a way to update the kernel in Update Manager. I do not recall the differences between current versions and the older ones, so I can not help with specifics.
Image
A woman typing on a laptop with LM20.3 Cinnamon.
Locked

Return to “Xfce”