# Problems with Xorg and remote display



## bsd4masses (Feb 8, 2016)

Hello,

Since some time now the remote display is not working "properly".  That means: I did on the local machine a `xhost +` allowing all to display, and after login over ssh on the remote machine set environment `setenv DISPLAY host:0` or as parameter --display host:0.  What I actually get is:


```
# emacs --display=host:0
Display host:0 can't be opened
```

starting ssh with "-v -X" gives me

...

```
debug2: x11_get_proto: /usr/local/bin/xauth -f /tmp/ssh-ruksMZHwvnkO/xauthfile generate :0.0 MIT-MAGIC-COOKIE-1 untrusted timeout 1200 2>/dev/null
Warning: untrusted X11 forwarding setup failed: xauth key data not generated
Warning: No xauth data; using fake authentication data for X11 forwarding.
debug1: Requesting X11 forwarding with authentication spoofing.
```
...

Sometimes there was a message about missing xauth - but not here...

Hopefully someone can give me an answer - because these things worked before since years

Thanks! Norbert


----------



## SirDice (Feb 8, 2016)

Don't set anything after logging in with ssh(1). Everything should already be set correctly. Simply login with ssh(1) and issue the command (no need for options either).


----------



## Juha Nurmela (Feb 8, 2016)

Just to clarify, which way you intend to connect X ? Directly to *workstation:0* or via ssh's *remote:10* ? Does xauth list on workstation and on remote give expected output?

Juha


----------



## bsd4masses (Mar 2, 2016)

thanks for the answers - but I still have no luck...

To clarify I did:
`# ssh -X user@remotehost`

and on the remotehost:
`# emacs --display displayhost:0`

and get:

```
Display displayhost:0 can't be opened
```


----------



## Maxnix (Mar 2, 2016)

Recently X switched to -nolisten tcp by default. Do you specify -listen tcp? This will let X listen for remote connections.


----------



## Juha Nurmela (Mar 2, 2016)

And delete the /tmp/.X0-lock 
(On both machines, verify `echo $DISPLAY` is what you expect.)

`ssh -X` (or `ssh -Y`) is so convenient to use, why are you ignoring the ssh-redirected display ?

Juha


----------

