Page 1 of 1

check_unread_mails Plugin in NagiosXI

Posted: Mon Mar 16, 2020 8:27 am
by imadc
Hello Team

I am trying to use this plugin: https://exchange.nagios.org/directory/P ... ls/details

I am getting the following error, do you if any prerequisites needed for this plugin? do we need perl?

[root@prodnagios libexec]# ./check_unread_mails.pl
-bash: ./check_unread_mails.pl: /usr/bin/perl^M: bad interpreter: No such file or directory

Thanks
Insurity

Re: check_unread_mails Plugin in NagiosXI

Posted: Mon Mar 16, 2020 8:46 am
by scottwilkerson
this looks like you have windows line ending in the file

Lets install a line ending converter

Code: Select all

yum install dos2unix -y
Then run the following

Code: Select all

dos2unix /usr/local/nagios/libexec/check_unread_mails.pl