title: Stopping/Rebooting Gearmand
body: <p>I have installed Gearman Job Server (aka Gearmand) 1.0.6 to my Ubuntu:</p>
  
  <pre><code>Distributor ID: Ubuntu
  Description:    Ubuntu 14.04.2 LTS
  Release:        14.04
  </code></pre>
  
  <p>I have also installed gearman-tools, libgearman-dev.
  <img src="https://i.stack.imgur.com/9myje.jpg" alt="enter image description here">
  Trying to restart the Gearmand with command:</p>
  
  <pre><code>/etc/init.d/gearman-job-server restart
  </code></pre>
  
  <p>But I am getting an error:</p>
  
  <pre><code> No /usr/sbin/gearmand found running; none killed.
   /usr/sbin/gearmand already running.
  </code></pre>
  
  <p><img src="https://i.stack.imgur.com/v5Y38.jpg" alt="enter image description here"></p>
  
  <p>The same happens when I am trying to stop it:</p>
  
  <pre><code>/etc/init.d/gearman-job-server stop
  </code></pre>
  
  <p>response:                                                                         <code>No /usr/sbin/gearmand found running; none killed.</code></p>
  
  <p>The /etc/init.d/gearman-job-server code is:</p>
  
  <pre><code>#!/bin/sh
  
  # Gearman server and library
  # Copyright (C) 2008 Brian Aker, Eric Day
  # All rights reserved.
  #
  # Use and distribution licensed under the BSD license.  See
  # the COPYING file in this directory for full text.
  
  ### BEGIN INIT INFO
  # Provides:          gearman-job-server
  # Required-Start:    $network $remote_fs $syslog
  # Required-Stop:     $network $remote_fs $syslog
  # Default-Start:     2 3 4 5
  # Default-Stop:      0 1 6
  # Short-Description: Start daemon at boot time
  # Description:       Enable gearman job server
  ### END INIT INFO
  
  prefix=/usr
  exec_prefix=${prefix}
  NAME=gearmand
  DAEMON=${exec_prefix}/sbin/gearmand
  PIDDIR=/var/run/gearman
  PIDFILE=${PIDDIR}/gearmand.pid
  GEARMANUSER="gearman"
  PARAMS=""
  
  test -x ${DAEMON} || exit 0
  
  . /lib/lsb/init-functions
  
  test -f /etc/default/gearman-job-server &amp;&amp; . /etc/default/gearman-job-server
  
  start()
  {
    log_daemon_msg "Starting Gearman Server" "gearmand"
    if ! test -d ${PIDDIR}
    then
      mkdir ${PIDDIR}
      chown ${GEARMANUSER} ${PIDDIR}
    fi
    if start-stop-daemon \
      --start \
      --exec $DAEMON \
      -- --pid-file=$PIDFILE \
         --user=$GEARMANUSER \
         --daemon \
         --log-file=/var/log/gearman-job-server/gearman.log \
         $PARAMS 
    then
      log_end_msg 0
    else
      log_end_msg 1
      log_warning_msg "Please take a look at the syslog"
      exit 1
    fi
  }
  
  stop()
  {
    log_daemon_msg "Stopping Gearman Server" "gearmand"
    if start-stop-daemon \
      --stop \
      --oknodo \
      --exec $DAEMON \
      --pidfile $PIDFILE
    then
      log_end_msg 0
    else
      log_end_msg 1
      exit 1
    fi
  }
  
  status()
  {
      status_of_proc -p $PIDFILE $DAEMON $NAME &amp;&amp; exit 0 || exit $?
  }
  
  case "$1" in
  
    start)
      start
    ;;
  
    stop)
      stop
    ;;
  
    status)
      status
    ;;
  
    restart|force-reload)
      stop
      start
    ;;
  
    *)
      echo "Usage: $0 {start|stop|restart|force-reload|status}"
    ;;
  
  esac
  </code></pre>
  
  <p>Google does not help... maybe searching the wrong way. Can you help me to make it work please? :) </p>