Waitmax executes a program in a new process.
Waitmax is available under GPL Version 2. The precompiled RPM runs on all i386-based systems. It contains a version of waitmax which is statically linked with diet and does not need libc nor any other library.
Copy a large file with scp. Interrupt if this takes more than one hour:
waitmax 3600 scp bigfile.tar.gz somehost:/tmp
-s, --signal signum
Use signum to kill the program instead of TERM.
Show short help and exit.
Show version and exit.
255 The program has been signalled and terminated, because the
time has elapsed, before the program has exited itself.
254 The program has exited neither by signal nor normally.
Strange. This should never happen.
253 The program couldn~t be executed.
The program has terminated with signal signum before the
time has elapsed (not by waitmax, but by itself or some
1 Waitmax has been called with illegal options.