poor mans watch, watch for solaris
Here is a simple script that you can use as watch in Solaris as well.
watch() { #Poor man's watch while (true) do clear $* sleep 2; done }
Here is a simple script that you can use as watch in Solaris as well.
watch() { #Poor man's watch while (true) do clear $* sleep 2; done }
Today I was working on a solaris box and wanted to do a watch. watch command is not available on Solaris 8 by default and I did not want to install it just for this small one time job. So I wrote this:
for (( i=0; i<=100; i++ )); do ls -lrt /tmp/amit*; sleep 2; done
You can replace the command in bold with whatever command you want to watch.
Continue readingI know ubuntu is out already but this is something that you can use to monitor a webpage.
This script will run check a for the Ubuntu 9.10 launch once every 5 mins and let you know when it’s available:
while [ 1 ]; do if [ -z \"`curl -I \"http://cdimage.ubuntu.com/releases/9.10/release/\"|grep \"404\"`\" ]; then kdialog --msgbox \"9.10 Released\"; exit; fi; sleep 300; done
<a href="http://feedads.g.doubleclick.net/~a/99XcDO7_UNXZESNlOirXkV4_tfA/0/da"><img src="http://blog.amit-agarwal.com/wp-content/uploads/img.zemanta.com/~a/99XcDO7_UNXZESNlOirXkV4_tfA/0/di" alt="" align="bottom" />
<a href="http://feedads.g.doubleclick.net/~a/99XcDO7_UNXZESNlOirXkV4_tfA/1/da"><img src="http://blog.amit-agarwal.com/wp-content/uploads/img.zemanta.com/~a/99XcDO7_UNXZESNlOirXkV4_tfA/1/di" alt="" align="bottom" />