[ZBX-9751] No process in PID file zabbix-server Created: 2015 Aug 03  Updated: 2017 May 30  Resolved: 2015 Aug 04

Status: Closed
Project: ZABBIX BUGS AND ISSUES
Component/s: Server (S)
Affects Version/s: 2.4.3
Fix Version/s: None

Type: Problem report Priority: Trivial
Reporter: Stanislav Assignee: Unassigned
Resolution: Won't fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

ubuntu


Attachments: File zabbix_server.conf     File zabbix_server.conf    
Issue Links:
Duplicate
duplicates ZBXNEXT-2898 No process in PID file zabbix-server Closed

 Description   

Hi all!
Have working Zabbix.. Made full clone of working Zabbix with VMware tools. I want start this clone on reserve server in case of main server will be broken.
So, tried to "service zabbix-server start" nothing changes. Then i tried to "service zabbix-server restart". Here is issue:
Stopping Zabbix server zabbix_server
No process in pidfile 'var/run/zabbix/zabbix_server.pid' Found running; none killed. [OK]
Starting Zabbix server zabbix_server

In zabbix_server.log there is only:
cannot send list of active checks to host #1
cannot send list of active checks to host #2
cannot send list of active checks to host #3 etc.

Checked directory var/run/zabbix/
There is no zabbix_server.pid file



 Comments   
Comment by Lukas S [ 2015 Aug 03 ]

Please check your init.d file, are you sure your path is 'var/run/zabbix/zabbix_server.pid' instead of '/var/run/zabbix/zabbix_server.pid' (slash at beginning) ? Next step, you should check permission for this directory, zabbix user should have proper rights.

Comment by Stanislav [ 2015 Aug 03 ]

my init.d

#! /bin/sh

      1. BEGIN INIT INFO
  1. Provides: zabbix-server
  2. Required-Start: $remote_fs $network
  3. Required-Stop: $remote_fs
  4. Default-Start: 2 3 4 5
  5. Default-Stop: 0 1 6
  6. Should-Start: mysql
  7. Should-Stop: mysql
  8. Short-Description: Start zabbix-server daemon
      1. END INIT INFO

set -e

NAME=zabbix_server
DAEMON=/usr/sbin/$NAME
DESC="Zabbix server"

test -x $DAEMON || exit 0

DIR=/var/run/zabbix
PID=$DIR/$NAME.pid
RETRY=15

my zabbix_server.conf

      1. Option: PidFile
  1. Name of PID file.
    #
  2. Mandatory: no
  3. Default:
  4. PidFile=/tmp/zabbix_server.pid

PidFile=/var/run/zabbix/zabbix_server.pid

Comment by Stanislav [ 2015 Aug 03 ]

drwxr-xr-x 2 zabbix zabbix 100 Aug 3 14:41 zabbix
proper rights on reserve identical proper rights on main server

Comment by Lukas S [ 2015 Aug 03 ]

paste your zabbix_server.conf file here, probably there is something wrong with your configuration and zabbix_server is not starting

Comment by Lukas S [ 2015 Aug 03 ]

Configuration seems to be OK. How did you clone zabbix to reserve server?

Comment by Stanislav [ 2015 Aug 04 ]

I cloned Zabbix with VMWare VSphere.
I have virtual server - made full clone of Zabbix vurtual machine with all configs, DB, setting, etc.
Then started .vmx file and on reserve server.
Me and my colleagues do it almost every month with other servers and systems, so I didn't expect any problems.

Comment by Aleksandrs Saveljevs [ 2015 Aug 04 ]

In the issue description there is the following suspicious output:

No process in pidfile 'var/run/zabbix/zabbix_server.pid' Found running; none killed. [OK]

There is no "/" before "var". I would expect it to be "/var/run/zabbix/zabbix_server.pid". Could you please check whether fixing it makes a difference?

Comment by Stanislav [ 2015 Aug 04 ]

My mistake
server respons this message with "/"

No process in pidfile '/var/run/zabbix/zabbix_server.pid' Found running; none killed. [OK]

Comment by Stanislav [ 2015 Aug 04 ]

Important detail

After "service zabbix-server restart" ON MAIN SERVER
I have same mistake No process in PID file!!!

Comment by Stanislav [ 2015 Aug 04 ]

when I type "bash -x zabbix-server restart" I have this message:
zabbix-server: line 57: zabbix-server: command not found

Comment by Stanislav [ 2015 Aug 04 ]

My /etc/init.d/zabbix-server script

#! /bin/sh

      1. BEGIN INIT INFO
  1. Provides: zabbix-server
  2. Required-Start: $remote_fs $network
  3. Required-Stop: $remote_fs
  4. Default-Start: 2 3 4 5
  5. Default-Stop: 0 1 6
  6. Should-Start: mysql
  7. Should-Stop: mysql
  8. Short-Description: Start zabbix-server daemon
      1. END INIT INFO

set -e

NAME=zabbix_server
DAEMON=/usr/sbin/$NAME
DESC="Zabbix server"

test -x $DAEMON || exit 0

DIR=/var/run/zabbix
PID=$DIR/$NAME.pid
RETRY=15

if test ! -d "$DIR"; then
mkdir "$DIR"
chown -R zabbix:zabbix "$DIR"
fi

export PATH="${PATH:+$PATH:}/usr/sbin:/sbin"

  1. define LSB log_* functions.
    . /lib/lsb/init-functions

case "$1" in
start)
log_daemon_msg "Starting $DESC" "$NAME"
start-stop-daemon --oknodo --start --pidfile $PID \
--exec $DAEMON >/dev/null 2>&1
case "$?" in
0) log_end_msg 0 ;;
*) log_end_msg 1; exit 1 ;;
esac
;;
stop)
log_daemon_msg "Stopping $DESC" "$NAME"
start-stop-daemon --oknodo --stop --pidfile $PID --retry $RETRY
case "$?" in
0) log_end_msg 0 ;;
*) log_end_msg 1; exit 1 ;;
esac
;;
status)
status_of_proc "$DAEMON" "$NAME" && exit 0 || exit $?
;;
restart|force-reload)
$0 stop
$0 start
;;
*)
echo "Usage: /etc/init.d/$NAME

{start|stop|restart|force-reload}

" >&2
exit 1
;;
esac

exit 0

Comment by Stanislav [ 2015 Aug 04 ]

I fixed this problem
When I execute /etc/init.d/zabbix-server/ Line
" start-stop-daemon --oknodo --start --pidfile $PID \
--exec $DAEMON >/dev/null 2>&1"
there is message "Unknown parametr DisableHouseKeeping = 1"
after commenting DisableHouseKeeping = 1 in zabbix_server.conf everything works fine/

Comment by richlv [ 2015 Aug 04 ]

as a reminder, please do use channels, listed at https://zabbix.org/wiki/Getting_help , for support

Generated at Wed Apr 16 15:00:56 EEST 2025 using Jira 9.12.4#9120004-sha1:625303b708afdb767e17cb2838290c41888e9ff0.