[lxc-users] Question about "lxc-wait"

Thouraya TH thouraya87 at gmail.com
Mon Aug 31 13:57:15 UTC 2015


Hello all :)

Here is my script: i try to do the dumping process in parallel with its
running

#!/bin/bash
if [ $# -ne 1 ]
then
 echo "USE: ./Dumping.sh worker-name"
 else

lxc-start -n $1 *& my_pid=$!*
sleep 10
mkdir $1
while lxc-checkpoint -D  /home/$1 -n  $1 * $my_pid*
do
         sleep 20
done
fi
-----------
Please, is it possible to use lxc-wait and change my script like this:

#!/bin/bash
if [ $# -ne 1 ]
then
 echo "USE: ./Dumping.sh worker-name"
 else

lxc-start -n $1
sleep 10
mkdir $1
while  lxc-wait -n $1 -s *STOPPED*
do

         lxc-checkpoint -D  /home/$1 -n  $1
         sleep 20
done
fi

Thank you so much for answers.
Kind regards.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxcontainers.org/pipermail/lxc-users/attachments/20150831/35f663e0/attachment.html>


More information about the lxc-users mailing list