tee with telnet

tee with telnet

Post by doug.. » Thu, 16 Sep 1993 23:24:41



I have been using telnet to carry out the occasional ARCHIE search.
Some of my searches produce a large number of hits.  Is it possible
to turn on tee just before I do "telnet archie.rutgers" so I can
capture the output to a file?

I'm not too familiar with telnet.  Does telnet have a tee equivalent?

Thanks.

------------------------------------------------------------------------

Whiteshell Laboratories               communications have
Atomic Energy of Canada Limited       completely broken down.
Pinawa, MB   R0E 1L0                     - Ashleigh Brilliant
------------------------------------------------------------------------

 
 
 

tee with telnet

Post by Tom Park » Fri, 17 Sep 1993 04:05:07



>I have been using telnet to carry out the occasional ARCHIE search.
>Some of my searches produce a large number of hits.  Is it possible
>to turn on tee just before I do "telnet archie.rutgers" so I can
>capture the output to a file?

>I'm not too familiar with telnet.  Does telnet have a tee equivalent?

What I do after telnet'ing to archie and seeing a long list, is to type "mail

will break up a large list into several pieces.

There are probably other ways to accomplish this too.

-- Tom
--
+--------------------------------------------------------------------+
| Tom Parker             |  National Center for Atmospheric Research |

+--------------------------------------------------------------------+

 
 
 

tee with telnet

Post by Hiren Hindo » Fri, 17 Sep 1993 21:29:23




>>I have been using telnet to carry out the occasional ARCHIE search.
>>Some of my searches produce a large number of hits.  Is it possible
>>to turn on tee just before I do "telnet archie.rutgers" so I can
>>capture the output to a file?

>What I do after telnet'ing to archie and seeing a long list, is to type "mail

>will break up a large list into several pieces.

>There are probably other ways to accomplish this too.

Other Ways:
1)
you can capture output/input of your telnet session using the script(1)
command. Start script and then start your telnet session , after the
telnet session type control-D to end your script session .
The scriptfile will contain Control-M's and Control-H's which can
be easily taken out by vi.

2)  If you are running screen ( a program that gives you multiple windows
on a character terminal + is freely available), then screen output logging
is very easy. I find the program very very useful. ( Look for it on archie)
or mail me for more info.

3) If you have Tcl/tk and the expect program , then you can do your
telnet session in a batch mode (using expect) and use the shell commands
to redirect output etc. (check out comp.lang.tcl for more info)

Hiren

 
 
 

tee with telnet

Post by Brian D. Kel » Sun, 19 Sep 1993 08:17:26



>>to turn on tee just before I do "telnet archie.rutgers" so I can
>>capture the output to a file?

>>I'm not too familiar with telnet.  Does telnet have a tee equivalent?
>What I do after telnet'ing to archie and seeing a long list, is to type "mail


Another idea is to grab the remote archie software and pipe the output
to a file in the background.
--
           _____                         Brian Kelly
          /     )                        aka Hiway Star
         /_____/  ___    .   __  ___


 
 
 

tee with telnet

Post by Wolfgang Sander-Beuerma » Wed, 22 Sep 1993 20:30:45



> I have been using telnet to carry out the occasional ARCHIE search.
> Some of my searches produce a large number of hits.  Is it possible
> to turn on tee just before I do "telnet archie.rutgers" so I can
> capture the output to a file?
> I'm not too familiar with telnet.  Does telnet have a tee equivalent?

[...lots of other things of former replies deleted...]

Why not do, what this postings asks for, just using telnet with tee:

   telnet RemoteMachine | tee File

saves everthing additionally in File.


 
 
 

1. vscript | tee -a out => tee is hanging

In June 2001 Ning Zhu posted to comp.unix.shell about a problem with
"somefunction 2>&1 | tee -a filename" hanging.
I am having a very similar problem. There was no solution posting to Ning's

I'm starting !"xterm -e myscript" (from a Xwindows menu pick)
where myscript sets some things, then runs
vscript 2>&1 | tee -a outfile

vscript is a giant vendor-supplied script that starts a GUI; vscript has an
initial interactive part, so we can't just capture all output from it (ie
use > outfile) since the user has to SEE what vscript says, & respond to it
in the xterm. One thinks | tee -a outfile is just the ticket.

"vscript" actually *does* exit, but the tee -a is hanging.
When GUI starts, one picks File -> Exit; the GUI goes away, the vscript
process goes away too, but tee -a process is hanging *and* the myscript
process *and* the xterm too.
ctrl-C in the xterm kills them all; but ungraceful + other bad sub-effects.

If run plain "vscript" from myscript (without | tee -a outfile), all works
fine: when exit GUI, the parent xterm also evaporates. But we want to log the
dratted output on that xterm!
If replace vscript with test script that echoes a few things to stdout &
stderr: in that case the tee -a does not hang, it is properly notified that
the other end of the pipe is gone, & it too exits nicely. So the concept of
vscript | tee -a outfile seems perfectly valid.

Since from "vscript 2>&1 | tee -a outfile" the vscript process really does
exit, I can only think something is not closing the pipe ok. But what/how, if
vscript & the subprocsses(GUI) it started all really do go away on their own?

Clues? Hints? Other things to try debugging it?
I found a few other somewhat related postings about slightly diff tee-related
probs so will study those.

Grateful Gal,

-----------------------------------------------------------
Ms W Lacesso, Unix Analyst, PanCdn Energy, Calgary 403.290.2740

2. My modem hangup after the negociation......

3. telnet client locks terminal when tee'd

4. LILO version 22.0 released

5. telnet 0 vs telnet `hostname` vs telnet 127.0.0.1

6. Tape Format Tool under Linux

7. unset T; echo a | tee /dev/stderr | $T; what happens?

8. umask question, please help.

9. Question: Tee Pipes

10. Qs about "tee"

11. teeing stderr

12. "tee" in the middle of a session?

13. Tee hee hee