Skip to content

Instantly share code, notes, and snippets.

@shrop
Last active December 19, 2015 12:48
Show Gist options
  • Select an option

  • Save shrop/5957019 to your computer and use it in GitHub Desktop.

Select an option

Save shrop/5957019 to your computer and use it in GitHub Desktop.
# If memcached is running, flush it.
if [ `sudo /etc/init.d/memcached status` =~ 'memcached is running' ]; then
echo ”flush_all” | nc localhost 11211
echo "memcached flushed!"
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment