[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-bash] How to monitor bash variables periodically

From: Patrick Schleizer
Subject: Re: [Help-bash] How to monitor bash variables periodically
Date: Mon, 26 Jan 2015 18:03:54 +0000

I don't understand the question or what it is what you really want to do
well enough... Consider to elaborate.

To just listen for signals, you can use an endless loop in combination
with sleep an wait.

sleep 10 &
wait $!

Then set up a signal handler, handle the signal as it comes in, then go
back to the endless loop using wait.

And if watching disk i/o is what you're after, then an i/o friendly way
to do this is using inotifywait. That way you don't have to periodically
pull the file system.

Hope that helps.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]