On Tue, Nov 07, 2000 at 05:42:22PM +1100, Howard Lowndes wrote:
> Well, I have managed to find the source code for telnet and am trying to
> make some sense out of it, never having studied C in depth, or even in the
> shallows.
>
> In the meantime I am looking at alternatives using a redirected ssh
> session and I am trying to get the following script to work:
>
> #!/bin/sh
> PATH=/bin:/sbin:/usr/bin:/usr/sbin:/usr/bin/X11
> PORT=4104
> ssh -x -L ${PORT}:cwsvr:${PORT} cwsvr
> sleep 5
> xterm -e telnet localhost ${PORT}
>
how about you just do
ssh -x -L ${PORT}:cwsvr:${PORT} cwsvr xterm -e telnet localhost ${PORT}
ie ssh treats anything on the command line after the remote machine as
the remote process to run instead of the default shell
>
> The idea is that the redirect by the ssh is set up, 5 seconds is then
> allowed for it to establish followed by an xterm/telnet session starting.
>
> The problem is that I can't get the ssh line to background so that the
> remainder of the script continues, it just leaves me at the prompt on the
> cwsvr.
>
> Could someone give me a short bash lesson on this one, pse.
>
> --
> Howard.
> ______________________________________________________
> LANNet Computing Associates <http://www.lannet.com.au>
>
>
>
> --
> SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
> More Info: http://slug.org.au/lists/listinfo/slug
--
John
The difference between a good man and a bad one is the
choice of cause - William James
--
SLUG - Sydney Linux User Group Mailing List - http://slug.org.au/
More Info: http://slug.org.au/lists/listinfo/slug