Thursday, April 11, 2019

[Nagios] Error unable to get process status

Bismillah

#Error Unable to get process status

Solusi cek error dengan menggunakan command dibawah ini :
[root@nms servers]# /usr/local/nagios/bin/nagios -v /usr/local/nagios/etc/nagios.cfg



# Normalnya seperti dibawah ini :
-----------------------------------------

Nagios Core 4.1.1
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-19-2015
License: GPL

Website: https://www.nagios.org
Reading configuration data...
   Read main config file okay...
   Read object config files okay...

Running pre-flight check on configuration data...

Checking objects...
Checked 19 services.
Checked 13 hosts.
Checked 1 host groups.
Checked 0 service groups.
Checked 1 contacts.
Checked 1 contact groups.
Checked 25 commands.
Checked 5 time periods.
Checked 0 host escalations.
Checked 0 service escalations.
Checking for circular paths...
Checked 13 hosts
Checked 0 service dependencies
Checked 0 host dependencies
Checked 5 timeperiods
Checking global event handlers...
Checking obsessive compulsive processor commands...
Checking misc settings...

Total Warnings: 0
Total Errors:   0


# Apabila ada error, maka hasil cek seperti dibawah ini :
------------------------------------------------------------------
Nagios Core 4.1.1
Copyright (c) 2009-present Nagios Core Development Team and Community Contributors
Copyright (c) 1999-2009 Ethan Galstad
Last Modified: 08-19-2015
License: GPL

Website: https://www.nagios.org
Reading configuration data...
   Read main config file okay...
Error: Could not find any host matching 'MAIL-SERVER' (config file '/usr/local/nagios/etc/servers/portal.cfg', starting on line 19)
Error: Failed to expand host list 'MAIL-SERVER' for service 'Pop3' (/usr/local/nagios/etc/servers/portal.cfg:19)
   Error processing object config files!


***> One or more problems was encountered while processing the config files...

     Check your configuration file(s) to ensure that they contain valid
     directives and data defintions.  If you are upgrading from a previous
     version of Nagios, you should be aware that some variables/definitions
     may have been removed or modified in this version.  Make sure to read
     the HTML documentation regarding the config files, as well as the

     'Whats New' section to find out what has changed.

Untuk memperbaiki error tersebut, edit pada file CFG yang dibuat.
Seperti pada contoh diatas error ada pada bagian MAIL-SERVER.cfg line 19 dan portal.cfg line 19. cek kembali apakah sudah sesuai dengan format standarisasi nagios.

#Berikut contoh .CFG yang benar :
........................................................
define host {
        use                             linux-server
        host_name                       ITMSPD201
        alias                           ITMSPD201
        address                         182.253.XXX.XXX
        max_check_attempts              5
        check_period                    24x7
        notification_interval           30
        notification_period             24x7
}

define service {
        use                             generic-service
        host_name                       ITMSPD201
        service_description             PING
        check_command                   check_ping!100.0,20%!500.0,60%
}

define service {
        use                             generic-service
        host_name                       ITMSPD201
        service_description             Pop3
        check_command                   check_pop!182.253.XXX.XXX

}




Share:

Monday, April 8, 2019

Zimbra and Ubuntu OS

ZIMBRA AND UBUNTU OS
Bismillah,

Pada saat kita melakukan installasi mail server berbasis zimbra 8 diatas Ubuntu server 16.04, tidak semua tutorial yang kita ikutin berjalan normal, selalu ada kekurangan / error pada saat instalasi. seperti yang saya alami tutorial yang saya ikutin adalah tutorial pada link ini : https://blog.zimbra.com/2016/05/install-zimbra-collaboration-8-7-ubuntu-14-04-lts/ tetapi pada proses berjalan instalasi ada beberapa error diantaranya :

1. ERROR: Installation can not proceeed. Please fix your /etc/hosts file to contain: Where is the ip address of the host, is the FULLY QUALIFIED host name, and is the (optional) hostname-only portion.

Solusinya :

1.1 Tahap pertama periksa file /etc/hosts
127.0.0.1     mail.domainanda.com   mail

1.2 Tahap kedua periksa file /etc/hostname
mail.domainanda.com

1.3 Tahap ketiga periksa file /etc/resolv.conf
nameserver 127.0.0.1
nameserver XX.XX.XX.XX (Masukan DNS Server anda/ DNS Local anda / DNS ISP Anda)

nameserver 1.1.1.1


2. Error perl: warning: Setting locale failed.
Operations logged to /tmp/install.log.bKlF2yxd
Checking for existing installation...
    zimbra-drive...NOT FOUND
    zimbra-imapd...NOT FOUND
    zimbra-patch...NOT FOUND
    zimbra-mta-patch...NOT FOUND
    zimbra-proxy-patch...NOT FOUND
    zimbra-license-tools...NOT FOUND
    zimbra-license-extension...NOT FOUND
    zimbra-network-store...NOT FOUND
    zimbra-network-modules-ng...NOT FOUND
    zimbra-chat...NOT FOUND
    zimbra-talk...NOT FOUND
    zimbra-ldap...NOT FOUND
    zimbra-logger...NOT FOUND
    zimbra-mta...NOT FOUND
    zimbra-dnscache...NOT FOUND
    zimbra-snmp...NOT FOUND
    zimbra-store...NOT FOUND
    zimbra-apache...NOT FOUND
    zimbra-spell...NOT FOUND
    zimbra-convertd...NOT FOUND
    zimbra-memcached...NOT FOUND
    zimbra-proxy...NOT FOUND
    zimbra-archiving...NOT FOUND
    zimbra-core...NOT FOUND
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
 LANGUAGE = (unset),
 LC_ALL = (unset),
 LC_CTYPE = "UTF-8",
 LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_US.UTF-8").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
 LANGUAGE = (unset),
 LC_ALL = (unset),
 LC_CTYPE = "UTF-8",
 LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_US.UTF-8").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
 LANGUAGE = (unset),
 LC_ALL = (unset),
 LC_CTYPE = "UTF-8",
 LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_US.UTF-8").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
 LANGUAGE = (unset),
 LC_ALL = (unset),
 LC_CTYPE = "UTF-8",
 LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_US.UTF-8").
perl: warning: Setting locale failed.
perl: warning: Please check that your locale settings:
 LANGUAGE = (unset),
 LC_ALL = (unset),
 LC_CTYPE = "UTF-8",
 LANG = "en_US.UTF-8"
    are supported and installed on your system.
perl: warning: Falling back to a fallback locale ("en_US.UTF-8").
----------------------------------------------------------------------
PLEASE READ THIS AGREEMENT CAREFULLY BEFORE USING THE SOFTWARE.
SYNACOR, INC. ("SYNACOR") WILL ONLY LICENSE THIS SOFTWARE TO YOU IF YOU
FIRST ACCEPT THE TERMS OF THIS AGREEMENT. BY DOWNLOADING OR INSTALLING
THE SOFTWARE, OR USING THE PRODUCT, YOU ARE CONSENTING TO BE BOUND BY
THIS AGREEMENT. IF YOU DO NOT AGREE TO ALL OF THE TERMS OF THIS
AGREEMENT, THEN DO NOT DOWNLOAD, INSTALL OR USE THE PRODUCT.
License Terms for this Zimbra Collaboration Suite Software:
https://www.zimbra.com/license/zimbra-public-eula-2-6.html
----------------------------------------------------------------------

Solusinya :

2.1 sudo vim /etc/default/locale
Tambahkan export LC_ALL="en_US.UTF-8" seperti pada dibawah ini

# File generated by update-locale
LANG="en_US.UTF-8"
export LC_ALL="en_US.UTF-8"

Share: