Page 1 of 1

NSCA Network server accept failure (9: Bad file descriptor)

Posted: Thu Jun 23, 2016 3:17 am
by dhineshkumar
Hi.,

I am seeing the following error for NSCA in system logs. After restarting the NSCA services, this error stops coming for a while. When this error is coming the passive checks are not accepted in the Nagios.

nsca[20579]: Network server accept failure (9: Bad file descriptor)

NSCA Server version is 2.9.1.
NSCA Client Version 2.9.1

Can help me to stop this error coming.

Thanks in Advance.

Re: NSCA Network server accept failure (9: Bad file descript

Posted: Thu Jun 23, 2016 10:43 am
by tgriep
I did some searching and found that this was a bug that was fixed in an earlier version on NSCA.
But another thing that could cause it is too many connections or dropped connections to the server leaving the NSCA daemon stuck and not shutting down.
Can you check and see if that is happening?
Can you login to the server, run the following and post the output?

Code: Select all

ps -ef
ulimit -a
You can try and add these 2 lines to your /etc/xinetd.d/nsca file to give it unlimited connections and instances.

Code: Select all

per_source      = UNLIMITED
instances       = UNLIMITED
But, if the connections never drop, you may want to fix that instead of doing the edits.

Re: NSCA Network server accept failure (9: Bad file descript

Posted: Thu Jun 23, 2016 11:48 am
by dhineshkumar
Thanks for your reply tgriep.

Nsca is running as standlone and not under xinetd. I could not see any connection dropping in the Nagios server.

Attached the output of the ps -ef and ulimit -a command ouput.

Thanks.

Re: NSCA Network server accept failure (9: Bad file descript

Posted: Thu Jun 23, 2016 12:37 pm
by tgriep
Without more detailed messages, it is hard to debug.
You could enable debugging in the NSCA daemon by setting the following option to 1 in the nsca.cfg file

Code: Select all

debug=1
Then restart NSCA and wait for the error to happen again.

It could also be the open file limit is set too small.
Currently it is set to 1024 open files, you may want to increase that.

Re: NSCA Network server accept failure (9: Bad file descript

Posted: Thu Jul 21, 2016 8:03 am
by dhineshkumar
After troubleshooting for weeks, found the issue on the MTU setting. MTU set on the server is high than the MTU on Network device, which broke the packets and NSCA couldnot identify those packets.

Re: NSCA Network server accept failure (9: Bad file descript

Posted: Thu Jul 21, 2016 10:08 am
by mcapra
Thanks for sharing your findings!

Is it alright if we lock this thread and mark the issue as resolved?

Re: NSCA Network server accept failure (9: Bad file descript

Posted: Thu Jul 28, 2016 9:59 pm
by dhineshkumar
Yes. We can mark this Thread as Resolved.

Thanks.