# Connecting to Xwindows Remotely



## kendotone (Jan 14, 2011)

Hi, this is my first post to the forums. I frequent the forums a lot because of the great wealth of information that is shared here.

My question to all of you is,

I am running FreeBSD 7.2. I have installed a HPoint RocketRaid card that has a WEBGUI interface. The Client does not want to use the CLI interface so I have no option there.

I have configured and gotten Xorg to start on the server. I'm using XFCE4 as the windowmanager. I installed the WEBGUI software and plugins and that is working great.

Now, My client would like to be able to remote into the server via VPN and pull up Xwindows on his Windows Desktop and run the WEBGUI to monitor the Raid status from home.

My question is, What do I need running on the server for him to be able to run Xwindows off his home PC and not have it load on the server when he types startxfce4. 

So basically, he will VPN into his network, and then run some of program that allows the Xwindows to load on his current Desktop..

I am very new to this and would appreciate any help possible. Thanks.


----------



## kpedersen (Jan 14, 2011)

Hello kendotone,

Does his home machine run windows? If so make sure the following is installed:

xming (http://sourceforge.net/projects/xming/)
ssh for windows (http://sshwindows.sourceforge.net/)

Once you have them installed, it is as simple as running in a command prompt (on the windows machine) and running:-


```
c:\> xming
c:\> set DISPLAY=localhost:0
c:\> ssh -Y <yourserverip>
   % xterm
```

Also.. make sure your server has x11 forwarding enabled in /etc/ssh/sshd_config
You might want to put the above commands into a .bat file to make it easier for him.
Note that 'ssh -Y' is less secure than 'ssh -X' but easier when getting the stuff to work in the first place. Once it is working, you can start using -X

I might add that VNC would be a much easier solution that you might like to look into.


----------



## kendotone (Jan 14, 2011)

Thank you for the response Kpedersen.

Yes, the client is running windows 7. He also has REALVNC installed on his machine.

I believe he isuing SecureCRT or Putty to SSH once he is connected via the VPN.

So, do I install that xming on the FreeBSD server or on the windows machine?

How would I use VNC to get this working?

I will edit the /etc/ssh/sshd_config file to make sure that x11 forwarding is enabled.

Thank you again.

Kendotone~


----------



## kpedersen (Jan 14, 2011)

xming goes on the Windows machine. All it really is is a simple xserver which ssh can use to tunnel X data to.

If your client is more comfortable using putty than 'ssh for windows', then putty can also be used to tunnel X, however I am not sure off the top of my head how this is done. A quick play with it and you will probably figure it out quite soon.

Going the VNC route (which is more responsive and fast than X11/forwarding), VNC can be used by setting up a VNC server (TightVNC in ports) on the FreeBSD server which will then allow your client to connect using his VNC client on Windows (RealVNC) and allow him to remotely control the FreeBSD server (and the required application). It is of course possible to set up different VNC sessions so you can both use the machine at the same time.


----------

