# X11 Forwarding



## atwinix (Aug 14, 2010)

Dear All,

I have just setup a FreeBSD server on VirtualBox and I am trying to open software like xcalc and xeyes remotely using PuTTY.

I have installed xming in windows to act as my xserver.

I have enabled *X11Forwarding Yes* in sshd_config and on PuTTY as well.  I also have the following in sshd_Config:


```
X11Forwarding yes
X11DisplayOffset 10
X11UseLocalhost no
```

But I cannot still get the applications to display (xming server is running).  I get the message "*Error: Can't open display: *" in PuTTY.  I tried with Xming's own plink as well and I still get the same problem.

How can I solve this?

Kind Regards,

atwinix


----------



## gordon@ (Aug 14, 2010)

Did you setup Putty to do the forwarding? In the Putty configuration window under Connection -> SSH -> X11, did you check the Enable X11 forwarding checkbox?


----------



## atwinix (Aug 15, 2010)

Yes, I did enable X11 Forwading in PuTTY.

Do I need to install X11 or Xorg in FreeBSD as well?

Correction:  *I installed X11/Xorg and I can startx with no problem locally but I still get the same error when I try Forwarding.*


----------



## kpedersen (Aug 15, 2010)

If it helps, this is what I usually do.


```
c:/> Xming.exe -fullscreen
c:/> set DISPLAY=127.0.0.1:0
c:/> ssh -X kpedersen@decdev (On some setups I need to replace -X with -Y (Non trusted X11 forwarding)
<password>
# xterm
```


----------

