Google Groups Home
Help | Sign in
Message from discussion root konsole (kde) - Cannot run applications
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Sumo Wrestler (or just ate too much)  
View profile
 More options Mar 24 2006, 2:57 am
Newsgroups: alt.os.linux.debian
From: "Sumo Wrestler (or just ate too much)" <sumo.wrest...@microsoft.invalid>
Date: Fri, 24 Mar 2006 07:57:40 GMT
Local: Fri, Mar 24 2006 2:57 am
Subject: Re: root konsole (kde) - Cannot run applications

On Thu, 23 Mar 2006 19:16:48 +0000, Paulo da Silva wrote:
> I can not run X applications from a root konsole (kde).

> 1. DISPLAY env var is not defined.
> 2. No authorization.

> I could turn around this by:
> 1. Defining DISPLAY=:0 (for :0 vt)
> 2. xauth merge /home/<normal_user>/.Xauthority

> Is there a better way?
> I could put "xauth merge /home/<normal_user>/.Xauthority" in .bashrc. But
> what about DISPLAY?

> Thanks for any help

You should run X applications as root as little as possible, and the extra
work required to get X apps to run as root is a good discouragement of the
practice.

You could set the DISPLAY variable in .bashrc as well as do the xauth
merge, but I would put those command into a separate script.

Typically, I don't bother with the xauth stuff; instead I do this:

useraccount$ xhost +local:
root# export DISPLAY=:0.0

The command "xhost +local:" allows any programs on your machine to contact
the X server.

I haven't created a script to do this. I just type the commands into the
terminal window because it isn't often that I run X apps as root.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google