View previous topic :: View next topic |
Author |
Message |
dchoi2464 n00b
Joined: 08 Oct 2021 Posts: 11
|
Posted: Sun Oct 10, 2021 12:23 pm Post subject: [SOLVED] Problems starting X server as non root user |
|
|
For context, I have just installed Gentoo successfully a couple of days ago and it is my first ever distro. Please be patient with me as I am the literal embodiment of Linux noob.
I have installed Xorg according to the wiki and configured my system according to "Non root Xorg" page in the wiki, but I still cannot get the X server to start on a non root user.
Here is the error log the X server provided me with when I attempted to start in as a non root user:
https://dpaste.com/AT6FYAUAG
I have also followed the 'Troubleshooting' section on the "Non root Xorg" wiki and checked everything that is stated there:
I checked elogind is running properly by running loginctl user-status, and the output looks the same as the wiki
Running dispatch-conf comes back as empty, and etc-update says there is nothing to do
Both dbus and elogind services are running (I have added elogind to boot)
However, the one thing that seems wrong to me is that there is no line regarding pam_elogind.so in /etc/pam.d/system-auth. I found a forum post that suggested I should rebuild pambase with the elogind flag enabled, but nothing changed after I rebuilt pambase (to be honest, I had already enabled the elogind flag globally and updated the system with emerge -ND @world, so I didn't expect this to work) I don't really know if this is the issue, as another forum post I read said that they could get X server to start as non root user without pam_elogind.so being in /etc/pam.d/system-auth.
From looking through the error log, I noticed that NVIDIA couldn't run /var/run/nvidia-xdriver-cab1240a as permission was denied. Could this be the issue?
Just for comparison, I ran the X server as the root user; the link below is the log for the root user:
Xorg root user log: https://dpaste.com/HXQAXLHAN
The following links are my make.conf and system-auth files, as I thought they might be useful in diagnosing the problem:
[list]
make.conf: https://dpaste.com/GDLKEVQRM
system-auth: https://dpaste.com/3KZFXFN8R
I would appreciate any help. Thank you in advance.
Last edited by dchoi2464 on Mon Oct 11, 2021 6:08 am; edited 2 times in total |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Oct 10, 2021 12:39 pm Post subject: |
|
|
dchoi2464,
Welcome to Gentoo.
Code: | [ 26.974] (II) Server terminated successfully (0). Closing log file. |
That tells that Xorg started, found nothing to do then quit.
What were you expecting Xorg to do and why?
You will have several Xorg.0.log files.
One will be in /var/log/. Thats always a result of Xorg running as root as users cannot write there.
The will be another in ~/ somewhere, as a result of runnnig Xorg as that user.
That's the log we need to see.
Lastly, Code: |
[ 26.527] (II) NVIDIA(G0): Virtual screen size determined to be 640 x 480
[ 26.527] (WW) NVIDIA(G0): Unable to get display device for DPI computation. | tells that you have an Optimus graphics system.
There is a special guide for Optimus users' as the nvidia GPU cannot transfer the image in the pixel buffer to the display.
The nvidia GPU can render the image but the Inter GPU always updates the display surface.
When you get that wrong, the display is always blank. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
dchoi2464 n00b
Joined: 08 Oct 2021 Posts: 11
|
Posted: Sun Oct 10, 2021 1:07 pm Post subject: |
|
|
Thank you for your reply.
I was trying to test X server as a non root user. I have twm and xterm installed on my system and since a terminal interface comes up automatically when I run Xorg as root, I expected the same for when I run Xorg as non root user.
Furthermore, the first link I provided above was the Xorg.0.log files from running Xorg as a non root user. Here is that link again:
https://dpaste.com/AT6FYAUAG
Just for clarification, I have installed twm and xterm on my system for testing. I am able to start Xorg as a root user and get a terminal/command line interface. However, when I run startx as a non root user, the screen flashes to black for a fraction of a second before it automatically exits.
By the way, should I provide any other files? |
|
Back to top |
|
|
NeddySeagoon Administrator
Joined: 05 Jul 2003 Posts: 54237 Location: 56N 3W
|
Posted: Sun Oct 10, 2021 1:59 pm Post subject: |
|
|
dchoi2464,
I wanted to check that it wasn't roots log you posted.
As it works for root, it should do the same for non-root.
It looks like the non root user is not finding the default xinitrc file that starts twn and friends or you have a ~/.xinitrc that is overriding the default.
The default xinitrc does the following.
Code: | # start some nice programs
twm &
xclock -geometry 50x50-1+1 &
xterm -geometry 80x50+494+51 &
xterm -geometry 80x20+494-0 &
exec xterm -geometry 80x66+0+0 -name login |
If you have a ~/.xinitrc because you have the Optimus set up commands there, add that to the end of it.
That's just the default Xinitrc settnigs. _________________ Regards,
NeddySeagoon
Computer users fall into two groups:-
those that do backups
those that have never had a hard drive fail. |
|
Back to top |
|
|
dchoi2464 n00b
Joined: 08 Oct 2021 Posts: 11
|
Posted: Mon Oct 11, 2021 6:08 am Post subject: |
|
|
For some reason I had an empty .xinitrc file; everything worked perfectly, after removing it.
Thank you for all you help! I will mark this question solved. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|