{ local @SIG{'INT', 'TERM'} = (sub {warn 'Interrupt!'}) x 2; `$cmd -P ALL $interval >> $path`; }
This works the way I pictured it to, thank you! But for some reason it doesn't work for this one.
{ local @SIG{'INT', 'TERM'} = (sub {warn 'Interrupt!'}) x 2; `$cmd -P ALL $interval | timestamp.pl >> $path`; }
Processing mpstat-5_EDT Number of samples: 9 Processing iostat-5_EDT Number of samples: 50 Processing vmstat-5_EDT Number of samples: 0
And VM stat is the only one that runs with timestamp.pl
In reply to Re^2: Catching Kill Process
by Jabox
in thread Catching Kill Process
by Jabox
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |