nsca not writing data to file

Julian Hein jhein at netways.de
Sat Apr 3 20:36:46 CEST 2004


Hi everyone,

I have a problem with the NSCA. Communication between both hosts seem to
be OK, but NSCA is not writing to any file on the central Nagios Server.
I really tried a lot in testing and debuging. This is my configuration:

Distributed Server:
-------------------

1.) in /etc/nagios/send_nsca.cfg:

  password=nagios
  encryption_method=0


2.) For testing I used the following shell script:

  /bin/echo -e "testhost\tPING\t0\t(No Output)\n" | \
  /usr/sbin/send_nsca ip.of.server -c /etc/nagios/send_nsca.cfg

when executing this script I get the following message:

  1 data packet(s) sent to host successfully.

So everything looks promising :-)


Central Server:
---------------

1.) in /etc/nagios/nsca.cfg:

  server_port=5667
  #server_address=192.168.1.1
  allowed_hosts=all IP Adresses the client has
  nsca_user=nagios
  nsca_group=nagios
  debug=1

  # for testing:
  command_file=/var/log/nagios/rw/nagios.test

  alternate_dump_file=/var/log/nagios/rw/nagios.dump
  aggregate_writes=0
  append_to_file=0
  max_packet_age=300
  password=nagios
  decryption_method=0


2.) for testing I set the command file like this (777):

  -rwxrwxrwx    1 nagios   nagios  0 nagios.test


3.) /etc/inetd.conf:

  nsca stream tcp nowait  nagios  /usr/sbin/nsca -c \
  /etc/nagios/nsca.cfg --inetd

4.) in /etc/services

  nsca  5667/tcp  # NSCA (Nagios)


My Problem is, that send_nsca says, that it successfully submitted the
data to the other server, but nothing gets written to the command file
"nagios.test". I tried the following things in tracking down the
problem:

1.) tcpdump          

I veryfied with tcpdump and tethereal "tcpdump dst port 5667 ", that tcp
communication is OK. And there seems to be no problem. Because I am
using no encryption, I can even see the Nagios Infos in the packets, if
using "tethereal -x dst port 5667"

2.) telnet

When telneting from the distributed to the central servers nsca port I
get the following result:

  # telnet ip.of.central.server 5667
  Trying 111.222.333.444...
  Connected to central.server.
  Escape character is '^]'.
  Incorrect command line arguments supplied

  NSCA - Nagios Service Check Acceptor
  Copyright (c) 2000-2003 Ethan Galstad (nagios at nagios.org)
  Version: 2.4
  Last Modified: 07-23-2003
  License: GPL
  Encryption Routines: AVAILABLE

  Usage: -c -c <config_file> [mode]

  (..)

So the nsca Daemon is running and listening, but this result looks a
little bit strange to me, but I don't know if this is standard.

3.) Debug Log

Well, I tried everything to get the debug logging working, but I had no
success, too. I even modified /etc/syslog.conf to log _everything_ (*.*)
into a test logfile and activated debugging in nsca.cfg, but it is not
logging a single line. :-(


Ok, if somebody has an idea, I would be very happy.

Thanks,
Julian


-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id70&alloc_id638&op=click
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list