Re: Howto redirect output from a terminal
On Wednesday 29 January 2003 10:48 am, Michael Kahle wrote:
> I am not sure how to ask for what I want here. But, here goes. I was
> using dump to make a backup of a directory on my computer. This was
> started from a terminal in X. As it was running I could see in the
> terminal window all the status output from the program. Good. This backup
> job took a long time to complete and so I went home while the backup was
> still running. When at home I ssh'd into the box to see if the dump
> process was still running, it was. Then I got to thinking, how can I see
> the output of this program in my current ssh session? Is there a program
> that exists to allow me to redirect the output of a program running in a
> terminal to another terminal? I hope I am explaining this clearly.
>
> Thanks,
>
> Michael
two options.
the option I think you want is screen.
while in an xterm, start screen. Now start executing commands like normal.
When you are ready to log out, type CTRL+A, CTRL+D to detach the screen
session.
Later, when you ssh back into your machine, type "screen -r" to re-attach that
session, just as it was.
the second option is to use script. If you just want to capture the output of
a program, start script, execute stuff, and then type exit to stop script.
All screen ouput was logged to a file in the current directory.
-jason pepas
Reply to: