You are not logged in.

#1 2018-02-11 07:07:12

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

[Solved] Can't switch TTYs when Xorg is started

When I press Ctrl+Alt+F2, the mouse disappears and the screen freezes. Nothing else. No TTY is showing.

Related: https://ubuntu-mate.community/t/17-04-c … -f-x/13043

(I did try raw copy-pasting their solution but that just made Xorg crash on startup. Otherwise I don't know what to replace those values with.)

The TTYs work perfectly like normal, but as soon as I start X I can't go back.
Using

sudo chvt 2

turns my screen pitch black, and is only restored once I go Ctrl+Alt+F7 again.

[Relevant section in /var/log/Xorg.0.log] [Whole Xorg.0.log]

Every single time I do this,

ACPI: \_SB_.PCI0.RP05.PEGP: failed to evaluate _DSM
nouveau 0000:04:00.0: bus: MMIO write of 8000001f FAULT at 6013d4 [ IBUS ]

appear in dmesg.

I'm starting X using LightDM by the way.
I'm using the xf86-video-nouveau and mesa drivers since default nvidia ones are broken on my system.

This all worked earlier. I've gotten a different TTY issue earlier, but that was fixed by switching to the LTS kernel.

I have not tried nomodeset. I am going to go do that right after I post this.
EDIT: nomodeset made the X server fail to launch for some reason.

Last edited by jD91mZM2 (2018-02-12 17:18:37)

Offline

#2 2018-02-11 08:49:46

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [Solved] Can't switch TTYs when Xorg is started

Xorg doesn't work w/o modesetting.
Get lightdm out of the equation  and elaborate on "default nvidia ones are broken on my system"

Offline

#3 2018-02-11 09:14:11

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

elaborate on "default nvidia ones are broken on my system"

When using the propietary nvidia drivers (nvidia, nvidia-lts) they always fail in different ways.

On Ubuntu, I was stuck in the login screen and could've go back.
On Linux Mint, it started but said the drivers didn't work.
On Linux Mint KDE, it didn't even get to the login screen.

And on Arch... Well... to be honest I don't remember what happened when I tried.

Last edited by jD91mZM2 (2018-02-11 13:21:08)

Offline

#4 2018-02-11 13:27:01

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,427

Re: [Solved] Can't switch TTYs when Xorg is started

_DSM is usually found on optimus laptops, do you have an optimus system? That would explain the "failed in different ways" without you doing anything to configure it, read https://wiki.archlinux.org/index.php/NVIDIA_Optimus

The problem at hand could really simply be a bug in nouveau, and following one of the mentioned methods to properly set up an optimus system would try to rule that out.

Offline

#5 2018-02-11 19:56:22

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

Sorry for the extremely late reply, I got carried away with xmonad. I do have Intel GPU + Nvidia GPU, which sounds like optimus according to the wiki description. I'll try configuring optimus tomorrow smile

Last edited by jD91mZM2 (2018-02-11 19:57:45)

Offline

#6 2018-02-12 05:20:52

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

Alright, I didn't find where in BIOS, but I tried using the Xorg config and installed nvidia-lts (I have an lts kernel) and nvidia-utils, as well as uninstalled xf86-video-nouveau and xf86-video-vesa (couldn't uninstall mesa because of a dependency failure). I could boot, but it was a black screen with only a mouse cursor on both monitors. And then the fans became louder and louder.

Offline

#7 2018-02-12 06:17:40

seth
Member
Registered: 2012-09-03
Posts: 49,992

Offline

#8 2018-02-12 07:02:31

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

Yeah, and I couldn't disable the graphics card using bios, so I followed the steps in https://wiki.archlinux.org/index.php/NV … ing_nvidia.

Offline

#9 2018-02-12 10:56:52

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,427

Re: [Solved] Can't switch TTYs when Xorg is started

The important part of these steps are the xrandr lines in the correct position, if these are missing it won't work.

Offline

#10 2018-02-12 14:29:52

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

I put those lines in both my .xprofile (sorry, I didn't read it carefully enough) and LightDM's display-setup-script.
I doubt not having the .xprofile would've made a difference though since I think it's only loaded on login, and it failed already at the login manager.

I might try again, but first I want to know if I uninstalled/installed the correct packages. Should I remove both nouveau and vesa (but not mesa because that breaks dependencies), and install nvidia-lts and nvidia-utils?
Or should I force remove mesa as well?

By the way, thanks for the help! I've gotten further than before thanks to it big_smile

Offline

#11 2018-02-12 14:32:18

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [Solved] Can't switch TTYs when Xorg is started

Offline

#12 2018-02-12 14:43:10

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

I really want to have *a* DM because it feels hacky to put stuff in the bash/zsh/fish profile (especially annoying since I want to maintain all three at the same time for some reason).
But yes, I can disable it temporarily in order to diagnose this issue.

Offline

#13 2018-02-12 14:45:02

seth
Member
Registered: 2012-09-03
Posts: 49,992

Re: [Solved] Can't switch TTYs when Xorg is started

jD91mZM2 wrote:

But yes, I can disable it temporarily in order to diagnose this issue.

That'd be the idea.

Offline

#14 2018-02-12 15:07:34

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

seth wrote:
jD91mZM2 wrote:

But yes, I can disable it temporarily in order to diagnose this issue.

That'd be the idea.

Oh, my bad.

Okay so I tried it an this time it was just pitch black.
Just in case I'm missing something, lspci says

00:02.0 VGA compatible controller: Intel Corporation Haswell-ULT Integrated Graphics Controller (rev 0b)
04:00.0 3D controller: NVIDIA Corporation GF117M [GeForce 610M/710M/810M/820M / GT 620M/625M/630M/720M] (rev a1)

so I create /etc/X11/xorg.conf.d/99-drivers.conf

Section "Module"
    Load "modesetting"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "4:0:0"
    Option "AllowEmptyInitialConfiguration"
EndSection

and the .xinitrc

xrandr --setprovideroutputsource modesetting NVIDIA-0
xrandr --auto

Also, I repeat: I never uninstalled mesa. This is because a lot of programs depend on it for some reason. Should I try skipping the dependency check?

EDIT: WHOOPS, I just realized I forgot to actually start anything from the .xinitrc. I'll retry.

Last edited by jD91mZM2 (2018-02-12 15:24:09)

Offline

#15 2018-02-12 15:32:49

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

Okay, it turns out it does work, I just forgot to start my WM.

EDIT: It feels laggier for some reason. Weird.

Last edited by jD91mZM2 (2018-02-12 16:02:02)

Offline

#16 2018-02-12 16:22:54

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,427

Re: [Solved] Can't switch TTYs when Xorg is started

Make sure you load nvidia-drm modeset=1 with e.g. an entry in modprobe.d or on your kernel command line with nvidia-drm.modeset=1 otherwise the cross GPU VSync won't work. If you like the behaviour of the integrated card better and only want to use the nvidia card on an as needed basis,  as supposed to as the primary renderer (which is what you are doing now), you should look into the bumblebee setup instead.

Also don't think about removing mesa or anything, you do need the intel card in some form or another. Whether as a simple output relay (your current setup) or as the primary renderer (your other setup or the bumblebee method) you need to keep the libraries that allow the intel driver to do it's job. The thing about Optimus laptops is that they don't have the nvidia card connected to a physical output, it has to go over the intel gpu in some form.

Offline

#17 2018-02-12 16:52:09

jD91mZM2
Member
Registered: 2017-10-19
Posts: 21
Website

Re: [Solved] Can't switch TTYs when Xorg is started

Ah, thank you. I'll mark this as solved smile

Offline

Board footer

Powered by FluxBB