I want to limit the time a grep process command is allowed to run or be alive.
For example. I want to perform the following:
grep -qsRw -m1 "parameter" /var
But before running the grep command I want to limit how long the grep process is to live, say no longer than 30 seconds.
How do I do this?
And if it can, how do I return or reset to have no time limit afterwards.
timeout, and you even got instructions on how to install it. It's rude to ignore this answer and then duplicate your question. – Paul R Jun 17 '10 at 15:27