Skip to content

Instantly share code, notes, and snippets.

@bageljp
Created February 13, 2014 07:12
Show Gist options
  • Select an option

  • Save bageljp/8971088 to your computer and use it in GitHub Desktop.

Select an option

Save bageljp/8971088 to your computer and use it in GitHub Desktop.
glusterfs
#!/bin/bash
DIR_IMAGE="/var/www/html/contents/"
CMD_FIND="/usr/bin/find"
CMD_XARGS="/usr/bin/xargs"
echo "### Self Heal Start. [${DIR_IMAGE}][time=`date +'%Y/%m/%d %H:%M:%S'`] ###"
${CMD_FIND} ${DIR_IMAGE} -noleaf -print0 | ${CMD_XARGS} --null stat > /dev/null
ret=$?
echo "### Self Heal End. [${DIR_IMAGE}][time=`date +'%Y/%m/%d %H:%M:%S'`] ###"
exit ${ret}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment