SlackwareThis Forum is for the discussion of Slackware Linux.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
I just installed slackware 10.2 and while I was configuring some users and groups I accident removed the "video" group, so now whenever I try to run a program from a terminal window it says it can't access the xserver, I am running the console in the Xwindows, and before I screwed up it would run the program from the console.
the command I ran was
groupmod -n "username" video
I wanted to add the "username" to the video group, but instead it added a group called "username" to the /etc/groups file.
I'm not sure, so let me ask a few elementary questions.
First, did you add your username(s) and not mine?
Second, did you remove that username group you created by accident?
Third, have you Google this error?
Fourth, what command are you running that returns that error?
You might need to restart the X server -- not sure. Just exit
the X server with your GUI menu, or "Ctrl+Alt+Backspace" and
then type "startx" to start the X server again.
What I did was vigr as root changed "username"::18: to video::18:"usernames" for "usernames" I added 3 users to the list root, my ID and the ID I want to use to run the program, seperated by a comma. I restarted X as you suggested and it still wont work. I get the same error. I have googled this error but I get a lot of stuff that doesn't seem to be similar to my problem. :
------Update------
I ran xhost + as the user and it works.. But I assume this is a temp fix and would like to find a permenant fix.
Are you trying to run a command that uses a users display as root? IE log in as a user, su to root and run a command in a terminal? That's the usual cause of that type of error.
2 things you can try in this situation. One is 'xhost +local:' and the other is making sure that env variable DISPLAY is :0.0 (or whichever display is currently running) by 'export DISPLAY=:0.0'
I have the xhost command in my users fluxbox startup script, and use the display variable in cron scripts, which also suffer from this problem.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.