comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Re: log output of an existing idl process
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Re: log output of an existing idl process [message #52566] Mon, 12 February 2007 10:39
aetherlux is currently offline  aetherlux
Messages: 12
Registered: July 2006
Junior Member
Ok. At least I know how to do it for the next time. Screen seems a
good way combinated with journal.
Thank you very much.

Juan.
Re: log output of an existing idl process [message #52569 is a reply to message #52566] Mon, 12 February 2007 09:29 Go to previous message
Craig Markwardt is currently offline  Craig Markwardt
Messages: 1869
Registered: November 1996
Senior Member
"aetherlux" <aetherlux@gmail.com> writes:
> I have read about different ways to log the idl outputs (errors and
> others). But I have a problem in a different way.
> I have an idl process which is running in a machine which I connect
> using ssh. Because of limitations of the firewall my ssh session is
> closed after a certain time. If I login again by ssh, I can see that
> the process is running yet ($top).
> The problem is that I have not previously defined a log file with
> journal or in a similar way. So, is it possible to obtain a log file
> of the current running idl program with the possible error output?. I
> am not sure about if it is possible with modifications of the stdout
> in the GNU/Linux remote system or the "catcher" tip by David.
>
> As I am not an expert I would thank a step by step explanation.

If your process is running *right now*, I think you are out of luck.
There are no really good ways to reconnect to an isolated process in
Unix.

Otherwise Foldy's suggestion of the "screen" program is a good one.
It allows you to reconnect and interact with an old job. It does
require foresight to start "screen" before anything else. Also, it
has a limited buffer size, so you won't be able to see very old
output.

Another solution is to use the "script" program, which keeps a log
of everything you do on the console. For example, you can run
it like this,
script -c "idl" myrun.log

Good luck!
Craig

--
------------------------------------------------------------ --------------
Craig B. Markwardt, Ph.D. EMAIL: craigmnet@REMOVEcow.physics.wisc.edu
Astrophysics, IDL, Finance, Derivatives | Remove "net" for better response
------------------------------------------------------------ --------------
Re: log output of an existing idl process [message #52574 is a reply to message #52569] Mon, 12 February 2007 08:56 Go to previous message
Foldy Lajos is currently offline  Foldy Lajos
Messages: 268
Registered: October 2001
Senior Member
On Mon, 12 Feb 2007, aetherlux wrote:

> I have read about different ways to log the idl outputs (errors and
> others). But I have a problem in a different way.
> I have an idl process which is running in a machine which I connect
> using ssh. Because of limitations of the firewall my ssh session is
> closed after a certain time. If I login again by ssh, I can see that
> the process is running yet ($top).
> The problem is that I have not previously defined a log file with
> journal or in a similar way. So, is it possible to obtain a log file
> of the current running idl program with the possible error output?. I
> am not sure about if it is possible with modifications of the stdout
> in the GNU/Linux remote system or the "catcher" tip by David.
>
> As I am not an expert I would thank a step by step explanation.
>
> Thank you very much.
>

I assume linux and console mode IDL, so try screen (man screen :-):

starting IDL:

- ssh to your IDL machine
- screen
- idl
...
- Ctrl-A D ; detach console
- exit ; exit ssh

next time:

- ssh to your IDL machine
- screen -r ; reattach your console
...

regards,
lajos
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: remove duplicates WITHOUT sorting
Next Topic: handling zero size file

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Fri Oct 10 12:43:14 PDT 2025

Total time taken to generate the page: 0.31963 seconds