check_ping: <max_packets> (%s) must be a non-negative number

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
donnyforbes
Posts: 357
Joined: Tue Jun 13, 2017 2:17 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by donnyforbes »

here is the /usr/local/nagios/etc/objects/commands.cfg file

Code: Select all

###############################################################################
# COMMANDS.CFG - SAMPLE COMMAND DEFINITIONS FOR NAGIOS 4.3.2 # # # NOTES: This config file provides you with some example command definitions
#        that you can reference in host, service, and contact definitions.
#       
#        You don't need to keep commands in a separate file from your other
#        object definitions.  This has been done just to make things easier to
#        understand.
#
###############################################################################


#check_nrpe

define command{
command_name check_nrpe
command_line $USER1$/check_nrpe -H $HOSTADDRESS$ -c $ARG1$ }



#host and service definitions

define host{
name linux-box ; Name of this template
use generic-host ; Inherit default values
check_period 24x7
check_interval 5
retry_interval 1
max_check_attempts 10
check_command check-host-alive
notification_period 24x7
notification_interval 30
notification_options d,r
contact_groups admins
register 0 ; DONT REGISTER THIS - ITS A TEMPLATE
}

#remote Linux/Unix hosts

define host{
use linux-box ; Inherit default values from a template
host_name huey  ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.1.42 ; IP address of the remote server
}

define host{
use linux-box ; Inherit default values from a template
host_name duey  ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.1.43 ; IP address of the remote server
}

define host{
use linux-box ; Inherit default values from a template
host_name louie   ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.39.10 ; IP address of the remote server
}

define host{
use linux-box ; Inherit default values from a template
host_name proxy4gl   ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.1.12 ; IP address of the remote server
}

define host{
use linux-box ; Inherit default values from a template
host_name taz2   ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.1.10 ; IP address of the remote server
}

define host{
use linux-box ; Inherit default values from a template
host_name tank   ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.1.15 ; IP address of the remote server
}

define host{
use linux-box ; Inherit default values from a template
host_name ernestine   ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.39.12 ; IP address of the remote server
}


#remote services monitored

#This service will monitor the CPU Load

define service{
use generic-service
host_name huey
service_description CPU Load
check_command check_nrpe!check_load
}

define service{
use generic-service
host_name duey
service_description CPU Load
check_command check_nrpe!check_load
}

define service{
use generic-service
host_name louie
service_description CPU Load
check_command check_nrpe!check_load
}

define service{
use generic-service
host_name proxy4gl
service_description CPU Load
check_command check_nrpe!check_load
}

define service{
use generic-service
host_name taz2
service_description CPU Load
check_command check_nrpe!check_load
}

define service{
use generic-service
host_name tank
service_description CPU Load
check_command check_nrpe!check_load
}

define service{
use generic-service
host_name ernestine
service_description CPU Load
check_command check_nrpe!check_load
}


#This service will monitor number of currenlty logged on users

define service{
use generic-service
host_name huey
service_description Current Users
check_command check_nrpe!check_users
}

define service{
use generic-service
host_name duey
service_description Current Users
check_command check_nrpe!check_users
}

define service{
use generic-service
host_name louie
service_description Current Users
check_command check_nrpe!check_users
}

define service{
use generic-service
host_name proxy4gl
service_description Current Users
check_command check_nrpe!check_users
}

define service{
use generic-service
host_name taz2
service_description Current Users
check_command check_nrpe!check_users
}

define service{
use generic-service
host_name tank
service_description Current Users
check_command check_nrpe!check_users
}

define service{
use generic-service
host_name ernestine
service_description Current Users
check_command check_nrpe!check_users
}

#This service will monitor the free drive space on /dev/hda1

define service{
use generic-service
host_name huey
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

define service{
use generic-service
host_name duey
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

define service{
use generic-service
host_name louie
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

define service{
use generic-service
host_name proxy4gl
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

define service{
use generic-service
host_name taz2
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

define service{
use generic-service
host_name tank
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

define service{
use generic-service
host_name ernestine
service_description /dev/hda1 Free Space
check_command check_nrpe!check_hda1
}

#service will monitor the total number of processes

define service{
use generic-service
host_name huey
service_description Total Processes
check_command check_nrpe!check_total_procs
}

define service{
use generic-service
host_name duey
service_description Total Processes
check_command check_nrpe!check_total_procs
}

define service{
use generic-service
host_name louie
service_description Total Processes
check_command check_nrpe!check_total_procs
}

define service{
use generic-service
host_name proxy4gl
service_description Total Processes
check_command check_nrpe!check_total_procs
}

define service{
use generic-service
host_name taz2
service_description Total Processes
check_command check_nrpe!check_total_procs
}

define service{
use generic-service
host_name tank
service_description Total Processes
check_command check_nrpe!check_total_procs
}


define service{
use generic-service
host_name ernestine
service_description Total Processes
check_command check_nrpe!check_total_procs
}


# SAMPLE NOTIFICATION COMMANDS
#
# These are some example notification commands.  They may or may not work on
# your system without modification.  As an example, some systems will require 
# you to use "/usr/bin/mailx" instead of "/usr/bin/mail" in the commands below.
#
################################################################################


# 'notify-host-by-email' command definition
define command{
	command_name	notify-host-by-email
	command_line	/usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: $NOTIFICATIONTYPE$\nHost: $HOSTNAME$\nState: $HOSTSTATE$\nAddress: $HOSTADDRESS$\nInfo: $HOSTOUTPUT$\n\nDate/Time: $LONGDATETIME$\n" | /bin/mail -s "** $NOTIFICATIONTYPE$ Host Alert: $HOSTNAME$ is $HOSTSTATE$ **" $CONTACTEMAIL$
	}

# 'notify-service-by-email' command definition
define command{
	command_name	notify-service-by-email
	command_line	/usr/bin/printf "%b" "***** Nagios *****\n\nNotification Type: $NOTIFICATIONTYPE$\n\nService: $SERVICEDESC$\nHost: $HOSTALIAS$\nAddress: $HOSTADDRESS$\nState: $SERVICESTATE$\n\nDate/Time: $LONGDATETIME$\n\nAdditional Info:\n\n$SERVICEOUTPUT$\n" | /bin/mail -s "** $NOTIFICATIONTYPE$ Service Alert: $HOSTALIAS$/$SERVICEDESC$ is $SERVICESTATE$ **" $CONTACTEMAIL$
	}


################################################################################
#
# SAMPLE HOST CHECK COMMANDS
#
################################################################################


# This command checks to see if a host is "alive" by pinging it
# The check must result in a 100% packet loss or 5 second (5000ms) round trip 
# average time to produce a critical error.
# Note: Five ICMP echo packets are sent (determined by the '-p 5' argument)

# 'check-host-alive' command definition
#define command{
#        command_name    check-host-alive
#        command_line    $USER1$/check_ping -H HOSTADDRESS$ -w 3000.0,80% -c 5000.0,100% -p 5
#        }



################################################################################
#
# SAMPLE SERVICE CHECK COMMANDS
#
# These are some example service check commands.  They may or may not work on
# your system, as they must be modified for your plugins.  See the HTML 
# documentation on the plugins for examples of how to configure command definitions.
#
# NOTE:  The following 'check_local_...' functions are designed to monitor
#        various metrics on the host that Nagios is running on (i.e. this one).
################################################################################

# 'check_local_disk' command definition
define command{
        command_name    check_local_disk
        command_line    $USER1$/check_disk -w $ARG1$ -c $ARG2$ -p $ARG3$
        }


# 'check_local_load' command definition
define command{
        command_name    check_local_load
        command_line    $USER1$/check_load -w $ARG1$ -c $ARG2$
        }


# 'check_local_procs' command definition
define command{
        command_name    check_local_procs
        command_line    $USER1$/check_procs -w $ARG1$ -c $ARG2$ -s $ARG3$
        }


# 'check_local_users' command definition
define command{
        command_name    check_local_users
        command_line    $USER1$/check_users -w $ARG1$ -c $ARG2$
        }


# 'check_local_swap' command definition
define command{
	command_name	check_local_swap
	command_line	$USER1$/check_swap -w $ARG1$ -c $ARG2$
	}


# 'check_local_mrtgtraf' command definition
define command{
	command_name	check_local_mrtgtraf
	command_line	$USER1$/check_mrtgtraf -F $ARG1$ -a $ARG2$ -w $ARG3$ -c $ARG4$ -e $ARG5$
	}


################################################################################
# NOTE:  The following 'check_...' commands are used to monitor services on
#        both local and remote hosts.
################################################################################

# 'check_ftp' command definition
define command{
        command_name    check_ftp
        command_line    $USER1$/check_ftp -H $HOSTADDRESS$ $ARG1$
        }


# 'check_hpjd' command definition
define command{
        command_name    check_hpjd
        command_line    $USER1$/check_hpjd -H $HOSTADDRESS$ $ARG1$
        }


# 'check_snmp' command definition
define command{
        command_name    check_snmp
        command_line    $USER1$/check_snmp -H $HOSTADDRESS$ $ARG1$
        }


# 'check_http' command definition
define command{
        command_name    check_http
        command_line    $USER1$/check_http -I $HOSTADDRESS$ $ARG1$
        }


# 'check_ssh' command definition
define command{
	command_name	check_ssh
	command_line	$USER1$/check_ssh $ARG1$ $HOSTADDRESS$
	}


# 'check_dhcp' command definition
define command{
	command_name	check_dhcp
	command_line	$USER1$/check_dhcp $ARG1$
	}


# 'check_ping' command definition
define command{
        command_name    check_ping
        command_line    $USER1$/check_ping -H $HOSTADDRESS$ -w $ARG1$ -c $ARG2$ -p 5
        }


# 'check_pop' command definition
define command{
        command_name    check_pop
        command_line    $USER1$/check_pop -H $HOSTADDRESS$ $ARG1$
        }


# 'check_imap' command definition
define command{
        command_name    check_imap
        command_line    $USER1$/check_imap -H $HOSTADDRESS$ $ARG1$
        }


# 'check_smtp' command definition
define command{
        command_name    check_smtp
        command_line    $USER1$/check_smtp -H $HOSTADDRESS$ $ARG1$
        }


# 'check_tcp' command definition
define command{
	command_name	check_tcp
	command_line	$USER1$/check_tcp -H $HOSTADDRESS$ -p $ARG1$ $ARG2$
	}


# 'check_udp' command definition
define command{
	command_name	check_udp
	command_line	$USER1$/check_udp -H $HOSTADDRESS$ -p $ARG1$ $ARG2$
	}


# 'check_nt' command definition
define command{
	command_name	check_nt
	command_line	$USER1$/check_nt -H $HOSTADDRESS$ -p 12489 -s F1reF1411  -v $ARG1$ $ARG2$
	}



################################################################################
#
# SAMPLE PERFORMANCE DATA COMMANDS
#
# These are sample performance data commands that can be used to send performance
# data output to two text files (one for hosts, another for services).  If you
# plan on simply writing performance data out to a file, consider using the 
# host_perfdata_file and service_perfdata_file options in the main config file.
#
################################################################################


# 'process-host-perfdata' command definition
define command{
	command_name	process-host-perfdata
	command_line	/usr/bin/printf "%b" "$LASTHOSTCHECK$\t$HOSTNAME$\t$HOSTSTATE$\t$HOSTATTEMPT$\t$HOSTSTATETYPE$\t$HOSTEXECUTIONTIME$\t$HOSTOUTPUT$\t$HOSTPERFDATA$\n" >> /usr/local/nagios/var/host-perfdata.out
	}


# 'process-service-perfdata' command definition
define command{
	command_name	process-service-perfdata
	command_line	/usr/bin/printf "%b" "$LASTSERVICECHECK$\t$HOSTNAME$\t$SERVICEDESC$\t$SERVICESTATE$\t$SERVICEATTEMPT$\t$SERVICESTATETYPE$\t$SERVICEEXECUTIONTIME$\t$SERVICELATENCY$\t$SERVICEOUTPUT$\t$SERVICEPERFDATA$\n" >> /usr/local/nagios/var/service-perfdata.out
	}

donnyforbes
Posts: 357
Joined: Tue Jun 13, 2017 2:17 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by donnyforbes »

Here is what I notice ...
Failed at step EXEC spawning /usr/lib/systemd/scripts/nagios: No such file or directory

This /usr/lib/systemd/scripts/nagios ----- Does not exist, however it is here

Code: Select all

[root@nag systemd]# pwd
/usr/lib/systemd
[root@nag systemd]# ls
catalog             rhel-loadmodules   systemd-bootchart         systemd-importd            systemd-pull            systemd-shutdownd      systemd-user-sessions   user-preset
import-pubring.gpg  rhel-readonly      systemd-bus-proxyd        systemd-initctl            systemd-quotacheck      systemd-sleep          systemd-vconsole-setup
ntp-units.d         system             systemd-cgroups-agent     systemd-journald           systemd-random-seed     systemd-socket-proxyd  system-generators
rhel-autorelabel    systemd            systemd-coredump          systemd-localed            systemd-readahead       systemd-sysctl         system-preset
rhel-configure      systemd-ac-power   systemd-cryptsetup        systemd-logind             systemd-remount-fs      systemd-timedated      system-shutdown
rhel-dmesg          systemd-activate   systemd-fsck              systemd-machined           systemd-reply-password  systemd-udevd          system-sleep
rhel-domainname     systemd-backlight  systemd-hibernate-resume  systemd-machine-id-commit  systemd-rfkill          systemd-update-done    user
rhel-import-state   systemd-binfmt     systemd-hostnamed         systemd-modules-load       systemd-shutdown        systemd-update-utmp    user-generators
[root@nag systemd]#

Code: Select all

[root@nag init.d]# pwd
/etc/init.d
[root@nag init.d]# ls
functions  iprdump  iprinit  iprupdate  nagios  netconsole  network  README
[root@nag init.d]#
The /var/log/messages says it should be here /usr/lib/systemd/scripts/nagios is that correct or misleading?

Thanks
donnyforbes
Posts: 357
Joined: Tue Jun 13, 2017 2:17 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by donnyforbes »

so I did the following

Code: Select all

/usr/lib/systemd/
mkdir scripts
then did this ..

Code: Select all

cp /etc/init.d/scripts/nagios -> /usr/lib/systemd/scripts 
Then ran systemctl start nagios

Code: Select all

tail -f /var/log/messages  

Jun 23 09:51:10 nag nagios: Starting nagios:
Jun 23 09:51:10 nag nagios: Nagios Core 4.3.2
Jun 23 09:51:10 nag nagios: Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Jun 23 09:51:10 nag nagios: Copyright (c) 1999-2009 Ethan Galstad
Jun 23 09:51:10 nag nagios: Last Modified: 2017-05-09
Jun 23 09:51:10 nag nagios: License: GPL
Jun 23 09:51:10 nag nagios: Website: https://www.nagios.org
Jun 23 09:51:10 nag nagios: Reading configuration data...
Jun 23 09:51:10 nag nagios: Read main config file okay...
Jun 23 09:51:10 nag nagios: Read object config files okay...
Jun 23 09:51:10 nag nagios: Running pre-flight check on configuration data...
Jun 23 09:51:10 nag nagios: Checking objects...
Jun 23 09:51:10 nag nagios: Checked 166 services.
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'ansel' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'babylon2' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'babylon3' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'centari' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'cylon2' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'drakh' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'drazi' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'duey' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'ernestine' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'goauld' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'huey' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'localhost' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'louie' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'narn' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'netmon' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'ori' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'pablo' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'prints' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'proxy4gl' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'rdp-server' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'sgc' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'shadow' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'sql' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'tank' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'taz2' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'tokra' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'tollan' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Error: Host check command 'check-host-alive' specified for host 'vorlon' is not defined anywhere!
Jun 23 09:51:10 nag nagios: Checked 28 hosts.
Jun 23 09:51:10 nag nagios: Checked 2 host groups.
Jun 23 09:51:10 nag nagios: Checked 0 service groups.
Jun 23 09:51:10 nag nagios: Checked 1 contacts.
Jun 23 09:51:10 nag nagios: Checked 1 contact groups.
Jun 23 09:51:10 nag nagios: Checked 24 commands.
Jun 23 09:51:10 nag nagios: Checked 5 time periods.
Jun 23 09:51:10 nag nagios: Checked 0 host escalations.
Jun 23 09:51:10 nag nagios: Checked 0 service escalations.
Jun 23 09:51:10 nag nagios: Checking for circular paths...
Jun 23 09:51:10 nag nagios: Checked 28 hosts
Jun 23 09:51:10 nag nagios: Checked 0 service dependencies
Jun 23 09:51:10 nag nagios: Checked 0 host dependencies
Jun 23 09:51:10 nag nagios: Checked 5 timeperiods
Jun 23 09:51:10 nag nagios: Checking global event handlers...
Jun 23 09:51:10 nag nagios: Checking obsessive compulsive processor commands...
Jun 23 09:51:10 nag nagios: Checking misc settings...
Jun 23 09:51:10 nag nagios: Total Warnings: 0
Jun 23 09:51:10 nag nagios: Total Errors:   28
Jun 23 09:51:10 nag nagios: ***> One or more problems was encountered while running the pre-flight check...
Jun 23 09:51:10 nag nagios: Check your configuration file(s) to ensure that they contain valid
Jun 23 09:51:10 nag nagios: directives and data definitions.  If you are upgrading from a previous
Jun 23 09:51:10 nag nagios: version of Nagios, you should be aware that some variables/definitions
Jun 23 09:51:10 nag systemd: nagios.service: control process exited, code=exited status=8
Jun 23 09:51:10 nag nagios: may have been removed or modified in this version.  Make sure to read
Jun 23 09:51:10 nag nagios: the HTML documentation regarding the config files, as well as the
Jun 23 09:51:10 nag nagios: 'Whats New' section to find out what has changed.
Jun 23 09:51:10 nag systemd: Failed to start Nagios Core Monitoring Daemon.
Jun 23 09:51:10 nag systemd: Unit nagios.service entered failed state.
Jun 23 09:51:10 nag systemd: nagios.service failed.
Please advise. Thank you.
User avatar
lmiltchev
Former Nagios Staff
Posts: 13587
Joined: Mon May 23, 2011 12:15 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by lmiltchev »

Can you first make sure you don't have any config errors? Please run the following command to verify configuration:

Code: Select all

/usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg
Note: If the path to the binary and/or the main config file is different, modify the above command accordingly.

You configs don't look right. You don't have a check command configured for your hosts. You are inheriting the check command from the "linux-box" template.
define host{
use linux-box ; Inherit default values from a template
host_name huey ; The name or IP or remote server
alias RHEL 7.3 ; A longer name for the server
address 192.168.1.42 ; IP address of the remote server
}
In your template, you have "check-host-alive" command defined.
define host{
name linux-box ; Name of this template
use generic-host ; Inherit default values
check_period 24x7
check_interval 5
retry_interval 1
max_check_attempts 10
check_command check-host-alive
notification_period 24x7
notification_interval 30
notification_options d,r
contact_groups admins
register 0 ; DONT REGISTER THIS - ITS A TEMPLATE
}
However, your "check-host-alive" command is commented out...
# 'check-host-alive' command definition
#define command{
# command_name check-host-alive
# command_line $USER1$/check_ping -H HOSTADDRESS$ -w 3000.0,80% -c 5000.0,100% -p 5
# }
In addition to this, you are missing the first "$" in the "$HOSTADDRESS$" macro... See the text in red.
Be sure to check out our Knowledgebase for helpful articles and solutions!
donnyforbes
Posts: 357
Joined: Tue Jun 13, 2017 2:17 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by donnyforbes »

Ok I fixed this hosts issue. I had that line comment out by accident trying something I remove the comments and start nagios up.

Code: Select all

[root@nag objects]# systemctl start nagios
[root@nag objects]# ps -ef |grep nagios
nagios    2693     1  0 10:05 ?        00:00:00 /usr/local/nagios/bin/nagios -d /usr/local/nagios/etc/nagios.cfg
nagios    2695  2693  0 10:05 ?        00:00:00 /usr/local/nagios/bin/nagios --worker /usr/local/nagios/var/rw/nagios.qh
nagios    2696  2693  0 10:05 ?        00:00:00 /usr/local/nagios/bin/nagios --worker /usr/local/nagios/var/rw/nagios.qh
nagios    2697  2693  0 10:05 ?        00:00:00 /usr/local/nagios/bin/nagios --worker /usr/local/nagios/var/rw/nagios.qh
nagios    2698  2693  0 10:05 ?        00:00:00 /usr/local/nagios/bin/nagios --worker /usr/local/nagios/var/rw/nagios.qh
nagios    2699  2693  0 10:05 ?        00:00:00 /usr/local/nagios/bin/nagios -d /usr/local/nagios/etc/nagios.cfg
root      2768  2328  0 10:06 pts/0    00:00:00 grep --color=auto nagios
[root@nag objects]#
was able to hit the console had to restart httpd.

Code: Select all

[root@nag objects]# service httpd restart
Redirecting to /bin/systemctl restart  httpd.service
[root@nag objects]# ps -ef |grep httpd
root      2982     1  1 10:09 ?        00:00:00 /usr/sbin/httpd -DFOREGROUND
apache    2985  2982  0 10:09 ?        00:00:00 /usr/sbin/httpd -DFOREGROUND
apache    2986  2982  0 10:09 ?        00:00:00 /usr/sbin/httpd -DFOREGROUND
apache    2987  2982  0 10:09 ?        00:00:00 /usr/sbin/httpd -DFOREGROUND
apache    2988  2982  0 10:09 ?        00:00:00 /usr/sbin/httpd -DFOREGROUND
apache    2989  2982  0 10:09 ?        00:00:00 /usr/sbin/httpd -DFOREGROUND
root      2997  2328  0 10:09 pts/0    00:00:00 grep --color=auto httpd
[root@nag objects]#
backup and running now, however back to what originated this request. Please see the attached file.
Attachments
Please see what I am getting on the console.
Please see what I am getting on the console.
donnyforbes
Posts: 357
Joined: Tue Jun 13, 2017 2:17 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by donnyforbes »

Thank you added the $ sign and I think everything is coming up now the way it was before. Thanks so much. I appreciate your assistance.
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by dwhitfield »

It sounds like this issue has been resolved. Is it okay if we lock this thread? Thanks for choosing the Nagios forums!
donnyforbes
Posts: 357
Joined: Tue Jun 13, 2017 2:17 pm

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by donnyforbes »

I just want to say that you guys are great with support. Again thank you for assisting us newbe's as we are still learning.
dwhitfield
Former Nagios Staff
Posts: 4583
Joined: Wed Sep 21, 2016 10:29 am
Location: NoLo, Minneapolis, MN
Contact:

Re: check_ping: <max_packets> (%s) must be a non-negative nu

Post by dwhitfield »

no problem! Are we ready to lock the thread?
Locked