/[sysadmin-cookbook]/recepies/lxc/lxc-watchdog.sh
This is repository of my old source code which isn't updated any more. Go to git.rot13.org for current projects!
ViewVC logotype

Diff of /recepies/lxc/lxc-watchdog.sh

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 244 by dpavlin, Tue Mar 29 18:00:40 2011 UTC revision 245 by dpavlin, Tue Mar 29 18:02:44 2011 UTC
# Line 150  while true; do Line 150  while true; do
150          vps_utmp=${rootfs}/var/run/utmp          vps_utmp=${rootfs}/var/run/utmp
151          tasks=`wc -l < /cgroup/${name}/tasks`          tasks=`wc -l < /cgroup/${name}/tasks`
152          stop_on=1 # init          stop_on=1 # init
153          sulogins=`lxc-ps --name backuppc | grep sulogin | wc -l`          sulogins=`lxc-ps --name $name | grep sulogin | wc -l`
154          if [ "$sulogins" -gt 0 ] ; then          if [ "$sulogins" -gt 0 ] ; then
155                  stop_on=`expr $stop_on + $sulogins`                  stop_on=`expr $stop_on + $sulogins`
156          fi          fi

Legend:
Removed from v.244  
changed lines
  Added in v.245

  ViewVC Help
Powered by ViewVC 1.1.26