On Tuesday 26 September 2006 03:50, Wolfgang Liebich 
<[EMAIL PROTECTED]> wrote about '[gentoo-user] Question about 
the dcop utility: How to use it from a remote computeR?':
> I'm logged in on my new computer, Machine N. I have setup ssh to connect
> by DSA key to my old computer, Machine O. Now i want to use the dcop
> program on O to give me a list of all open konqueror sessions on O. At
> first I just want to do something like:
> <new machine>:ssh <old machine> '/usr/kde/3.5/bin/dcop'
> But I always get "ERROR: Couldn't attach to a DCOP server'"

I've never used DCOP, but I figured this was probably related to 
environment variables, so I did an strace on a simple dcop invocation to 
try and figure out why it can't find the (presumably) running dcop server 
on "O".

On my system communication with the local DCOP server is via 
~/.DCOPserver_<hostname>__0, and I'm fairly sure the _0 at the end 
corresponds to part of my DISPLAY setting, ":0", indicating a local X 
server.  You may need to set your DISPLAY environment variable on "O" 
before you do the dcop invocation.

Assuming "O" is a standard desktop machine and you are the only one logged 
on to it, you should be able to do something like:
ssh O env DISPLAY=:0.0 dcop
to get the standard dcop output.

The only sure-fire way to determine the correct DISPLAY setting is to pull 
it from the X session you want to connect to. E.g.:
$ env | grep ^DISPLAY
DISPLAY=:0.0

-- 
"If there's one thing we've established over the years,
it's that the vast majority of our users don't have the slightest
clue what's best for them in terms of package stability."
-- Gentoo Developer Ciaran McCreesh

Attachment: pgpvryhK5Ef8w.pgp
Description: PGP signature

Reply via email to