You introduce a question here that intrigues me. Does a restart actually 
stop and start a program, flushing memory and cache? Or does it just do 
a reload? sometimes it seems that things don't really change with 
restart, just freshen up, so a manual stop and start are required.  
Maybe it's a cache issues like browsers experience?

On 02/14/2012 12:21 AM, Michael Markstaller wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Am 13.02.2012 22:22, schrieb Paul Alfille:
>> Or even better, how about if I can figure out how to make the one
>> process work without problems and restarts.
> That would be the preferred way ;)
>
> Michael
>
>
> In the meantime the script I use here, called from crontab every minute:
> - --- cut ---
> #!/bin/sh
>
> ps | grep -v grep | grep owserver>  /dev/null
> if [ $? != 0 ] ; then
>       /etc/init.d/owserver restart
>      logger -p warn "owserver not running! RESTARTING"
> else
>       echo "owserver OK"
> fi
>
> # set LED's
> LED_DEV=/tmp/LED
> if [ -e "/sys/class/leds/tl-mr3x20:green:qss/brightness" ] ; then
>      LED_DEV="/sys/class/leds/tl-mr3x20:green:qss/brightness"
> elif [ -e "/sys/class/leds/tl-wr1043nd:green:qss/brightness" ] ; then
>      LED_DEV="/sys/class/leds/tl-wr1043nd:green:qss/brightness"
> fi
>
> SCOUNT=`owget /uncached | grep -c "^/uncached/2"`
> if [ $SCOUNT -gt 0 ] ; then
>      echo 255>  $LED_DEV
> else
>      echo 0>  $LED_DEV
> fi
>
> # Check if any BM is active anytime
> BMCOUNT=`owget | grep -c "^/81"`
> BMSAVED=0
>
> if [ ! -e /tmp/ow_busmaster_found ] ; then
>      # save initial state
>      for i in `owget | grep "^/81"`;
>      do
>          BM=`basename $i`;
>          touch /tmp/ow_busmaster-$BM;
>      done
>       touch /tmp/ow_busmaster_found
>      logger "Saved DS9490 - $BMCOUNT found active"
> fi
>
> # If a busmaster was found anytime at startup
> # we try really hard to recover if one is lost!
> for j in `ls /tmp/ow_busmaster-*`;
> do
>      BM=`basename $j | cut -d'-' -f 2`
>      owget | grep $BM>/dev/null
>      if [ $? != 0 ] ; then
>          logger -p warn "$BM lost - RESTARTING OWSERVER!"
>          /etc/init.d/owserver restart
>      fi
> done
>
> # check owhttpd
> ps | grep -v grep | grep owhttpd>  /dev/null
> if [ $? != 0 ] ; then
>      /etc/init.d/owhttpd restart
>      logger -p warn "owhttpd not running! RESTARTING"
> else
>       echo "owhttpd OK"
> fi
> - --- cut ---
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.11 (GNU/Linux)
> Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/
>
> iEYEARECAAYFAk86NcAACgkQaWRHV2kMuALU9ACg4hSXCingEP4cpqglMp8adBmY
> qWUAoJZUsG5njzRXlbSQ3s4NK4Q1ikE0
> =NIJU
> -----END PGP SIGNATURE-----
>
> ------------------------------------------------------------------------------
> Keep Your Developer Skills Current with LearnDevNow!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-d2d
> _______________________________________________
> Owfs-developers mailing list
> Owfs-developers@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/owfs-developers
>


------------------------------------------------------------------------------
Keep Your Developer Skills Current with LearnDevNow!
The most comprehensive online learning library for Microsoft developers
is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
Metro Style Apps, more. Free future releases when you subscribe now!
http://p.sf.net/sfu/learndevnow-d2d
_______________________________________________
Owfs-developers mailing list
Owfs-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/owfs-developers

Reply via email to