[PLUG] ssh / window manager interaction land mine.

Russell Senior seniorr at aracnet.com
Wed Jan 7 19:10:02 UTC 2004


I have configured my X11 window manager (sawfish, but it's not unique
to any window manager) menu to launch remote xterms (and emacs and
browsers) via a ssh tunnel.  In .sawfishrc, I construct a menu based
on a list of hostnames, so that *root-menu* is something like:

  (("Xterms..." 
     ("localhost" (system "$HOME/bin/remote/run_xterm &"))
     ("remote-host1" (system "/usr/bin/ssh remote-host1 bin/remote/run_xterm &"))
     ("remote-host2" (system "/usr/bin/ssh remote-host2 bin/remote/run_xterm &"))))

where bin/remote/run_xterm is just a shell script adapted to the local
requirements for getting an xterm, usually just something like: 

  #!/bin/sh
  exec /usr/bin/X11/xterm [various options]

The *root-menu* form is just a lisp form that is interpretted by
sawfish's menu infrastructure to generate labels and execute
associated code based on user interaction.

However, when the ssh keys aren't all kosher, my window manager
freezes up.  Looking at the virtual terminal where I launched X, I see
it asking me to type a password or confirm I want to connect to a new
host, etc.  However, typing there doesn't help and basically I am
hosed.  I "have to"[1] kill X to recover.  I have learned about this
particular landmine and am usually careful to avoid it[2], but (having
just stepped on it again last night) I would really like to figure out
the _real_ solution.  Anyone know how to get ssh to behave itself, by
asking in a way I can provide the right answer, or otherwise save me
from nuking my X session every time I hit the mine?

[1] "have to" here means I haven't figured out a better way.  I'd
    prefer to think I am just inadequately clued and that this post
    will elicit the required clue.

[2] by first confirming that I can slogin to the host without any
    keyboard interaction.

-- 
Russell Senior         ``I have nine fingers; you have ten.''
seniorr at aracnet.com




More information about the PLUG mailing list