This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: how can I set $REMOTEHOST ( so I can set $DISPLAY with sshd w\X11 forwarding)


Brian Dessent <brian <at> dessent.net> writes:

> 
> Igor Pechtchanski wrote:
> 
> > > It could be that if DISPLAY is set before you run ssh -X then ssh won't
> > > change it.  Try unsetting DISPLAY first.
> > 
> > This is wrong.  "ssh -X/-Y" will not enable X11 forwarding *unless*
> > DISPLAY is set in the local shell.
> 
> Ahh, I should read the man page more often.  I knew there was some
> relation between setting $DISPLAY before invoking ssh -X, but I guess
> those neurons were crossed.
> 
> Brian
> 
> 

there are 2 configurations when I'm ssh'ing into the machine.

1 - I use the windows version of the ssh2 client from www.ssh.com.  X11
tunneling is a feature which you can either enable or disable (enabled on my
machine).  the x-server is the pc-xware x-server.  there is no problem when I
ssh into any of the other server's on my school's network, but I can't determine
what the local $DISPLAY var is set to.

2 - using another machine with cygwin, I use the startxwin.bat script to start
the xserver and open a window with a bash shell prompt in it.  again, I have no
issue with X11 being tunneled if I ssh into any of the other unix servers on our
shool's network.  the local $DISPLAY var for the cygwin client is set to
localhost:0.

Both configurations have the same problem where X11 apps launched from the
client's shell get launched and opened under the x-server running on the machine
running the cygwin sshd daemon (also launched using the startxwin.bat script).


I believe this is the pertinent section of the sshd_config file:

    #AllowTcpForwarding yes
    #GatewayPorts no
    X11Forwarding yes
    X11DisplayOffset 10
    X11UseLocalhost yes
    #PrintMotd yes
    #PrintLastLog yes
    #TCPKeepAlive yes
    #UseLogin no
    UsePrivilegeSeparation yes
    #PermitUserEnvironment no
    #Compression yes
    #ClientAliveInterval 0
    #ClientAliveCountMax 3
    #UseDNS yes
    #PidFile /var/run/sshd.pid
    #MaxStartups 10

and perms 

$ ls -al /etc/sshd_config
-rwxr-xr-x+   1 eecsexec Domain U     2485 Aug  4 17:29 /etc/sshd_config

Additional info about my setup, the server (grad107m) is part of a windows
domain and is running windows XP professional.  the account I use to log in is
not the machine admin, though the machine admin account was used to install
cygwin.  The domain accts and groups had to be added post-install using the

mkpasswd -l -d > /etc/passwd

and 

mkgroup -l -d > /etc/group

commands.

thanks for any ideas or suggestions,

Peter





--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]