Linux Shell:Timeout

Posted by linuxaria on Jun 20, 2013 3:54 AM EDT
Mail this story
Print this story

Sometimes it’s useful to write a bash script that do something like “Do this job, if it’s still running after XX second kill it”, how to implement this in a normal bash environment ? Nothing simpler: Use the timeout shell command to achieve this. From its info page: timeout runs the given COMMAND and kills it if it is still running after the specified time interval. Let’s see how to use it.

Full Story

» Read more about: Story Type: Tutorial; Groups: Linux

« Return to the newswire homepage

This topic does not have any threads posted yet!

You cannot post until you login.