File: check-memcached-runs

package info (click to toggle)
python-tooz 6.3.0-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 840 kB
  • sloc: python: 5,530; sh: 158; makefile: 27
file content (12 lines) | stat: -rwxr-xr-x 356 bytes parent folder | download | duplicates (8)
1
2
3
4
5
6
7
8
9
10
11
12
#!/bin/sh

set -e
set -x

# If it's already up, don't do anything
IS_UP=`netstat -anle | grep LISTEN | grep 127.0.0.1:11211 | awk '{print $4}'`
if [ "${IS_UP}" = "127.0.0.1:11211" ] ; then
	exit 0
fi

/sbin/start-stop-daemon --start --background --quiet --make-pidfile --pidfile `pwd`/TEST_PID_MEMCACHE.pid --exec /usr/bin/memcached -- /etc/memcached.conf