starbuck has asked for the wisdom of the Perl Monks concerning the following question:
I have a script that loops around several hundred times, each time gathering a dataset to measure performance over time.
If this process gets a hard kill (either ctrl-c or server reboot etc), is there a graceful way to "dump the results so far" to file?
Currently I append/open, print, then close the file, for every single iteration, is there a neater way to do this?
Thanks.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: How do I dump data to file on hard exit?
by Anonymous Monk on Mar 31, 2006 at 13:52 UTC | |
by displeaser (Hermit) on Mar 31, 2006 at 13:54 UTC | |
by johngg (Canon) on Mar 31, 2006 at 14:17 UTC | |
by salva (Canon) on Mar 31, 2006 at 14:22 UTC | |
by bart (Canon) on Apr 01, 2006 at 08:50 UTC | |
by starbuck (Novice) on Apr 03, 2006 at 11:29 UTC | |
|
Re: How do I dump data to file on hard exit?
by larryl (Monk) on Mar 31, 2006 at 22:29 UTC | |
|
Re: How do I dump data to file on hard exit?
by nimdokk (Vicar) on Mar 31, 2006 at 17:38 UTC | |
|
Re: How do I dump data to file on hard exit?
by sgifford (Prior) on Apr 01, 2006 at 04:39 UTC |