LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian
User Name
Password
Debian This forum is for the discussion of Debian Linux.

Notices


Reply
  Search this Thread
Old 06-08-2021, 03:13 PM   #1
mqrris
LQ Newbie
 
Registered: Jun 2021
Posts: 14

Rep: Reputation: Disabled
Can't launch Xorg as a regular user


startx outputs this:

Code:
xf86Enable IOPorts: failed to set IOPL for I/O (Operation not permitted)
I tried this:
1.
Code:
sudo chmod u+s /usr/bin/xinit
2. I changed settings in Xwrapper.config to
Code:
allowed_users=anybody
needs_root_rights=yes
3. Reinstalled xorg and drivers for it a couple times.

Here is my logs:
Xorg.0.log: https://pastebin.com/JT7EJidA
lspci -k output: https://pastebin.com/tyFvWBq7

Last edited by mqrris; 06-18-2021 at 12:38 AM.
 
Old 06-08-2021, 07:52 PM   #2
frankbell
LQ Guru
 
Registered: Jan 2006
Location: Virginia, USA
Distribution: Slackware, Ubuntu MATE, Mageia, and whatever VMs I happen to be playing with
Posts: 19,310
Blog Entries: 28

Rep: Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136Reputation: 6136
Do you have an xinitrc file? If so, what's it look like?

This may help: https://wiki.debian.org/Xorg
 
Old 06-08-2021, 11:46 PM   #3
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
Quote:
Originally Posted by mqrris View Post
I tried this:
1.
Code:
sudo chmod u+s /usr/bin/xinit
2. I changed settings in Xwrapper.config to
Code:
allowed_users=anybody
needs_root_rights=yes
Why did you think that this was going to help?
What and where is the latter file?
I wouldn't mess around (esp. in system directories) unless I knew 100% why.
Are you able to undo these changes, now that they didn't help?

FWIW, your Xorg log shows that Xorg starts and imnmediately ends again. I only glanced, but nothing jumped out at me. This could be because it doesn't know what window manager (or DE session) to start.
Have a look at your distro's wiki, chapter Xorg.
 
Old 06-09-2021, 03:50 AM   #4
igadoter
Senior Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: many, primary Slackware
Posts: 2,717
Blog Entries: 1

Rep: Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625
try to use direct command xinit -e xterm - it opens root window with one instance of xterm. There is no wm running - there will be no window borders.
 
Old 06-09-2021, 10:10 AM   #5
mqrris
LQ Newbie
 
Registered: Jun 2021
Posts: 14

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by igadoter View Post
try to use direct command xinit -e xterm - it opens root window with one instance of xterm. There is no wm running - there will be no window borders.
I executed
Code:
xinit -e xterm
And a new error appears, maybe it is the core of the problem. I remember how easy it was to solve such thing on gentoo, I'd just put in suid USE flag, and then recompile xorg, and it worked like a charm.
 
Old 06-09-2021, 10:23 AM   #6
igadoter
Senior Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: many, primary Slackware
Posts: 2,717
Blog Entries: 1

Rep: Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625
I am guessing /dev/tty0 is just console you are working now on. I think tty command can tell you - maybe try to open another virtual console - switch to that opened console and issue the same comman xinit -e xterm. Maybe Xserver by default is set to run on /dev/tty0. I am guessing of course. Switch to /dev/tty1.
 
Old 06-09-2021, 10:35 AM   #7
mqrris
LQ Newbie
 
Registered: Jun 2021
Posts: 14

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by igadoter View Post
I am guessing /dev/tty0 is just console you are working now on. I think tty command can tell you - maybe try to open another virtual console - switch to that opened console and issue the same comman xinit -e xterm. Maybe Xserver by default is set to run on /dev/tty0. I am guessing of course. Switch to /dev/tty1.
Yeah I tried that right away, output is the same.
 
Old 06-09-2021, 02:53 PM   #8
igadoter
Senior Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: many, primary Slackware
Posts: 2,717
Blog Entries: 1

Rep: Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625
Perhaps it is security policy. Tried run as root?
 
Old 06-09-2021, 08:01 PM   #9
mqrris
LQ Newbie
 
Registered: Jun 2021
Posts: 14

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by igadoter View Post
Perhaps it is security policy. Tried run as root?
This is the errors in the .local/share/xorg/Xorg.0.log when I run startx or xinit or xinit -e xterm as user
Code:
[   320.303] (EE) 
[   320.303] (EE) xf86OpenConsole: Cannot open virtual console 2 (Permission denied)
[   320.303] (EE) 
[   320.303] (EE) 
[   320.303] (EE) Please also check the log file at "/home/mqrris/.local/share/xorg/Xorg.0.log" for additional information.
[   320.303] (EE) 
[   320.303] (EE) Server terminated with error (1). Closing log file.
Xsession-errors if it's somewhat relevant.

Also, I executed xinit -e xterm as root and it didn't go well.
But just xinit worked and startx works as well, it even got me into dwm.
 
Old 06-10-2021, 06:26 AM   #10
igadoter
Senior Member
 
Registered: Sep 2006
Location: wroclaw, poland
Distribution: many, primary Slackware
Posts: 2,717
Blog Entries: 1

Rep: Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625Reputation: 625
So you know that it is about limited uses permission. Perhaps making user a member of some group is needed to run xinit?
 
Old 06-16-2021, 06:34 AM   #11
mqrris
LQ Newbie
 
Registered: Jun 2021
Posts: 14

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by igadoter View Post
So you know that it is about limited uses permission. Perhaps making user a member of some group is needed to run xinit?
I recently boot into my Debian installation and the errors were gone, but startx still does not work as regular user. If I execute xinit there will be errors with the privilege restrictions. But I have Xwrapper that does provide xorg with roots rights if needed.
I'm quite confused, don't know where the problem rooted.

UPD: I issued startx -e xterm and it worked, thanks for your support.

Last edited by mqrris; 06-16-2021 at 06:38 AM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] NFS subdirectory - regular user can read - root user denied qajaq Linux - Software 2 12-29-2016 12:59 PM
[SOLVED] how to change "-bash-4.1$ "to regular user mood user user@ mhsahkir Linux - Newbie 6 03-31-2015 12:39 PM
[SOLVED] Zorin dock launch (ie quick launch) instalation and use provobis Linux - Newbie 4 01-16-2015 07:25 PM
Unable to launch application from workstation but able to launch from vnc chaitanya1982 Linux - Desktop 2 04-30-2010 03:52 AM
Can one launch a rootless Xorg server in Xgl suger Linux - Software 2 05-13-2006 10:51 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Debian

All times are GMT -5. The time now is 09:48 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration