Monday, 25 August 2014

Nagios: CRITICAL - Could not interpret output from ping command

PING     UNKNOWN /bin/ping -n -U -w 10 -c 5 xx.xx.xx.xx

Nagios monitoring page showing above error when configuring in the client host ?

'Set-user-ID-on-execution permission' to fix the issue,

# ls -al /bin/ping
-rwxr-xr-x. 1 root root 40760 xxx xx  xxxx /bin/ping

# chmod u+s /bin/ping  // fix the issue.

# ls -la /bin/ping
-rwsr-xr-x. 1 root root 40760 xxx xx  xxxx /bin/ping

Nagios: -bash: /usr/local/nagios/libexec/check_nrpe: No such file or directory

To fix "check_nrpe: No such file or directory"

# cd
# wget http://prdownloads.
# tar zxvf nrpe*.tar.gz
# cd nrpe*
# ./configure --with-nagios-user=nagios --with-nagios-group=nagios
# cd ./src/
# make check_nrpe
# mv ./check_nrpe /usr/local/nagios/libexec/

Now you can find: /usr/local/nagios/libexec/check_nrpe !!!

Thursday, 21 August 2014

STOP :: logging query cache denied to /var/log/messages :: named

How to stop logging query cache denied to /var/log/message and /var/named/data/ ?


Adding the following to your /etc/named.conf will stop logging the cache denied messages:

category security { null; };

So named.conf will looking like below:


logging {
    category security { null; };
    channel default_debug {
            file "data/";
            severity dynamic;


Thursday, 14 August 2014

HowTo : Execute BASH Shell Commands over MySQL environment in Linux?

Yes, We can execute shell commands over mysql environment without exit by adding "\! " before commands as like "\! command",

mysql> \! uptime
 06:52:18 up 36 min,  1 user,  load average: 0.00, 0.00, 0.00

mysql> \! pwd

(or) We can get the shell prompt here by doing,

mysql> \! bash


mysql> \! sh

HowTo: Get current working database information in mysql?

Add the below lines in /etc/my.cnf


your  mysql environment will be,


To revert this,

HowTo: Get hostname in mysql environment?

Add the below lines in /etc/my.cnf


Also in /root/.my.cnf should have below,

please make sure the hostname should be valid and added in /etc/hosts

If you would like to return default PROMPT of mysql(this time only)

Returning to default PROMPT of mysql>

Enjoy !!....