# which ports to forward for X over DSL-router?

## meyerm

Hi,

I'm using an ADSL-router (USR8000) to connect to the net. Now I want to start X apps at university and admire them at home  :Wink: . I'm forwarding port 22 and ssh-ing works. I can also forward X over ssh. But since this is so awful slow (old machines at university) I would prefer direct X forwarding.

But which ports will I have to forward from my router to my PC? As already said, forwarding port 22 works, after forwarding ports 1-65535 the router needs a complete reset...

So which ports are normally used for X connects? Thanks,

Marcel

----------

## rizzo

I don't really know that you need to forward ports if you are starting the connection.  If someone from the outside wanted to access a service inside your lan then you'd need to forward those ports.  But you should be able to initiate the action without having to forward ports.  Just don't block the ports.  I could be totally off.

----------

## Naan Yaar

Firstly, you can turn on compression over ssh.  It makes things a little bit quicker.  By "direct X forwarding" I am not sure what you mean (ssh has a port forwarding option to create a "tunnel" between server and client).

Anyway, the X server listens on port 6000 for the first display and 6001, 6002, for subsequent displays.

You can probably look at LBX - which is supposed to be more efficient; I haven't tried it myself.  X is a "heavy" protocol, especially when toolkits like Motif are used...

 *meyerm wrote:*   

> Hi,
> 
> I'm using an ADSL-router (USR8000) to connect to the net. Now I want to start X apps at university and admire them at home . I'm forwarding port 22 and ssh-ing works. I can also forward X over ssh. But since this is so awful slow (old machines at university) I would prefer direct X forwarding.
> 
> But which ports will I have to forward from my router to my PC? As already said, forwarding port 22 works, after forwarding ports 1-65535 the router needs a complete reset...
> ...

 

----------

## meyerm

 *rizzo wrote:*   

> I don't really know that you need to forward ports if you are starting the connection. If someone from the outside wanted to access a service inside your lan then you'd need to forward those ports. 

 

Well, I'm sitting at home, but starting the apps at university (logged in over ssh). Therefore the Sparc at university is trying to open a connection to my workstation at home. The open ssh should not be used (slow machines). Therefore, the Sparcs are really trying to access a service inside my lan.

----------

## meyerm

 *Naan Yaar wrote:*   

> Firstly, you can turn on compression over ssh.

 

Yes, that's right. As long as the connection itself is the problem. But at this situation it is more the slow station at university (I have to use it, since it is offering unique services) which is used by several users at the same time.

 *Naan Yaar wrote:*   

> By "direct X forwarding" I am not sure what you mean (ssh has a port forwarding option to create a "tunnel" between server and client).

 

I meant really sending the X-protocol over the wire. Not tunneled in ssh or similar programs. This means, the "sever" has only to send the draw orders to my client and doesn't have to encrypt it before.

 *Naan Yaar wrote:*   

> Anyway, the X server listens on port 6000 for the first display and 6001, 6002, for subsequent displays.

 

Yes!  :Smile:  That was it. Thank you. It is still slow, but better than over ssh.

 *Naan Yaar wrote:*   

> You can probably look at LBX - which is supposed to be more efficient;

 

Hey, that looks interessting. It's useless for now since our old sparcs are using NetBSD and a quite old XFree but the new machines are already appearing at the horizont. Perhaps it will be very usefull. Thanks!

----------

