check_nagios_mailq not working
Posted: Tue Aug 24, 2021 8:18 am
Hello Team,
I am getting the below error in Nagiosxi portal for the service emailq which is using the plugin "check_nagios_mailq.py".
==========================================================================================================
(No output on stdout) stderr: Traceback (most recent call last):
File "/usr/local/nagios/libexec/check_nagios_mailq.py", line 46, in
main()
File "/usr/local/nagios/libexec/check_nagios_mailq.py", line 34, in main
outb = int (outb)
ValueError: invalid literal for int() with base 10: 'Program mode requires special privileges, e.g., root or TrustedUser.'
==========================================================================================================
I have followed the https://support.nagios.com/forum/viewto ... lq#p272409 link to verify my issue but couldn't resolve it. Below are the output details based on the information provided in the link.
==========================================================================================================
ls -l /usr/bin/mailq
lrwxrwxrwx 1 root root 27 Aug 20 03:14 /usr/bin/mailq -> /etc/alternatives/mta-mailq
ls -l /etc/alternatives/mta-mailq
lrwxrwxrwx 1 root root 23 Aug 20 03:14 /etc/alternatives/mta-mailq -> /usr/bin/mailq.sendmail
ls -l /usr/bin/mailq.sendmail
lrwxrwxrwx 1 root root 25 Aug 20 03:13 /usr/bin/mailq.sendmail -> ../sbin/sendmail.sendmail
==========================================================================================================
Nagios server is running on RHEL 7.9 in AWS with postfix service running
==========================================================================================================
service postfix status
Redirecting to /bin/systemctl status postfix.service
● postfix.service - Postfix Mail Transport Agent
Loaded: loaded (/usr/lib/systemd/system/postfix.service; disabled; vendor preset: disabled)
Active: active (running) since Tue 2021-08-24 05:48:03 PDT; 28min ago
Process: 16839 ExecStop=/usr/sbin/postfix stop (code=exited, status=0/SUCCESS)
==========================================================================================================
Can someone help me in resolving this issue?
I am getting the below error in Nagiosxi portal for the service emailq which is using the plugin "check_nagios_mailq.py".
==========================================================================================================
(No output on stdout) stderr: Traceback (most recent call last):
File "/usr/local/nagios/libexec/check_nagios_mailq.py", line 46, in
main()
File "/usr/local/nagios/libexec/check_nagios_mailq.py", line 34, in main
outb = int (outb)
ValueError: invalid literal for int() with base 10: 'Program mode requires special privileges, e.g., root or TrustedUser.'
==========================================================================================================
I have followed the https://support.nagios.com/forum/viewto ... lq#p272409 link to verify my issue but couldn't resolve it. Below are the output details based on the information provided in the link.
==========================================================================================================
ls -l /usr/bin/mailq
lrwxrwxrwx 1 root root 27 Aug 20 03:14 /usr/bin/mailq -> /etc/alternatives/mta-mailq
ls -l /etc/alternatives/mta-mailq
lrwxrwxrwx 1 root root 23 Aug 20 03:14 /etc/alternatives/mta-mailq -> /usr/bin/mailq.sendmail
ls -l /usr/bin/mailq.sendmail
lrwxrwxrwx 1 root root 25 Aug 20 03:13 /usr/bin/mailq.sendmail -> ../sbin/sendmail.sendmail
==========================================================================================================
Nagios server is running on RHEL 7.9 in AWS with postfix service running
==========================================================================================================
service postfix status
Redirecting to /bin/systemctl status postfix.service
● postfix.service - Postfix Mail Transport Agent
Loaded: loaded (/usr/lib/systemd/system/postfix.service; disabled; vendor preset: disabled)
Active: active (running) since Tue 2021-08-24 05:48:03 PDT; 28min ago
Process: 16839 ExecStop=/usr/sbin/postfix stop (code=exited, status=0/SUCCESS)
==========================================================================================================
Can someone help me in resolving this issue?