I've been trying to get emacs to let me open a local frame to an
already-running emacs for a while now, and I can't seem to make it
work. This is with emacs 23.
I start emacs --daemon on my desktop machine, then on my laptop, I run
ssh -X <desktop> -f emacsclient -c. I get the following response:
"X11 connection rejected because of wrong authentication
*ERROR*: Display localhost:10.0 can't be opened"
I don't claim to be an expert in xauth, but I've never had any trouble
with running ssh -X on these machines.
ssh -X <desktop> -f emacs works fine
ssh <desktop> -f emacsclient -t works fine
ssh -X <desktop> -f emacsclient --eval '"(make-frame-on-display
\"$DISPLAY"\)"' gives the same rejection as emacsclient -c
In terms of X and, what are these commands doing differently? Is the
$DISPLAY that emacs --daemon is started in somehow causing the remote
access to fail?
Any ideas? I've done a bit of Googling and I can't seem to find a good
answer. Any thoughts here?
Jason
> "X11 connection rejected because of wrong authentication
>
> *ERROR*: Display localhost:10.0 can't be opened"
>
> ...
> In terms of X and, what are these commands doing differently? Is the
> $DISPLAY that emacs --daemon is started in somehow causing the remote
> access to fail?
>
> Any ideas?
How about:
xhost localhost:10.0
It might also work to leave away the ":10.0" part. The command allows
access from your local machine's nominal display #10, screen #0 on
the display (usually 0) on which you are working. Leaving away that ":
10.0" specifier would allow every X related process running on your
computer to connect to your X server.
The ssh protocols have extra options for (port) re-direction...
I'm neither no X authorisation expert...
--
Greetings
Pete
They that can give up essential liberty to obtain a little temporary
safety deserve neither liberty nor safety.
-Benjamin Franklin, Historical Review of Pennsylvania.
This syntax is not understood by my xhost (1.0.2) and I have reason to
believe that it is not possible to specify a display like that; in the
'bugs' section, it says:
"You can’t specify a display on the command line because -display is a
valid command line argument (indicating that you want to remove the
machine named ‘‘display’’ from the access list)."
> It might also work to leave away the ":10.0" part. The command allows access
> from your local machine's nominal display #10, screen #0 on the display
> (usually 0) on which you are working. Leaving away that ":10.0" specifier
> would allow every X related process running on your computer to connect to
> your X server.
>
> The ssh protocols have extra options for (port) re-direction...
>
> I'm neither no X authorisation expert...
Since I have no problem getting remote windows to open on my laptop's
display (xterm&, emacs&, etc) with the same remote client, I feel like
the issue is that emacsclient -c is doing something different in
redirecting the display. Do you folk think a post to emacs-devel would
be useful? Do you know who spearheaded the emacsclient -c development?
Thanks for your help,
Jason