×
Create a new article
Write your page title here:
We currently have 3,189 articles on s23. Type your article name above or create one of the articles listed here!



    s23
    3,189Articles

    Nagios/build/Solaris

    Revision as of 15:00, 12 November 2010 by imported>DrOwl (→‎Build Nagios server)

    Building Nagios On Solaris Sparc

    Prepare

    Install gcc

    get the gcc package form sunfreeware

    # wget ftp://ftp.sunfreeware.com/pub/freeware/sparc/10/gcc-3.4.6-sol10-sparc-local.gz
    
    # gunzip gcc-3.4.6-sol10-sparc-local.gz
    
    # pkgadd -d gcc-3.4.6-sol10-sparc-local
    

    you then need to set up the environment (you can add this to /etc/profile or some enlivenment =)

    # export CC ; CC=gcc
    
    # export LD_LIBRARY_PATH;  LD_LIBRARY_PATH=/usr/sfw/lib:/usr/local/ssl/lib
    
    # export PATH ; PATH=/usr/local/bin:/usr/sfw/bin:/usr/sbin:/usr/bin:/usr/ccs/bin
    
    install ligiconv

    gcc needs libiconv

    wget ftp://ftp.sunfreeware.com/pub/freeware/sparc/10/libiconv-1.11-sol10-sparc-local.gz

    # gunzip libiconv-1.11-sol10-sparc-local.gz
    # pkgadd -d libiconv-1.11-sol10-sparc-local
    


    Install Lib gd

    Get the source form www.libgd.org

    # wget http://www.libgd.org/releases/gd-2.0.35.tar.gz
    
    # gunzip -dc gd-2.0.35.tar.gz | tar -xf -
    
    # cd gd-2.0.35
    
    # ./configure --prefix=/opt/libgd
    ...
    # make
    ...
    # make install
    ...
    
    

    Build Nagios server

    get the nagios source from www.nagios.org

    # gunzip -dc nagios-3.0.6.tar.gz | tar -xf -
    
    # cd nagios-3.0.6
    
    # groupadd -g 510 nagios
    # useradd -u 510 -g nagios nagios
    

    Refer to the Read Only Webaccount Patch below

    1. ./configure --prefix=/opt/nagios-3.0.6 --with-nagios-user=nagios --with-nagios-group=nagios --with-gd-lib=/opt/libgd/lib --with-gd-inc=/opt/libgd/include
    2. gmake pkgclean
    3. gmake all
    4. gmake pkgset

    Read Only Web account patch

    get the patch from http://www.nagios3book.com/

    in the directory you have extracted the nagios source code:

    # wget http://www.nagios3book.com/nagios-3-enm/patches/readonly.tar
    
    # tar xvf readonly.tar
    
    
    

    in the cgi/ dir

    # patch -r cgiauth.c < cgiauth.diff
    # patch -r extinfo.c < extinfo.diff
    

    and in the include/ dir

    # patch -r cgiauth.h < cgiauth.h.diff
    





    Building Nagios On Solaris x86

    Prepare

    Install gcc

    get the gcc package form sunfreeware

    # wget ftp://ftp.sunfreeware.com/pub/freeware/intel/10/gcc-3.4.6-sol10-x86-local.gz
    
    # gunzip gcc-3.4.6-sol10-x86-local.gz
    
    # pkgadd -d gcc-3.4.6-sol10-x86-local
    

    you then need to set up the enviroment (you can add this to /etc/profile or some eqilivent =)

    # export CC ; CC=gcc
    
    # export LD_LIBRARY_PATH;  LD_LIBRARY_PATH=/usr/sfw/lib:/usr/local/ssl/lib
    
    # export PATH ; PATH=/usr/local/bin:/usr/sfw/bin:/usr/sbin:/usr/bin:/usr/ccs/bin
    
    install ligiconv

    gcc need libiconv

    wget ftp://ftp.sunfreeware.com/pub/freeware/intel/10/libiconv-1.11-sol10-x86-local.gz

    # gunzip libiconv-1.11-sol10-x86-local.gz 
    # pkgadd -d libiconv-1.11-sol10-x86-local 
    


    Install Lib gd

    Get the source form www.libgd.org

    # wget http://www.libgd.org/releases/gd-2.0.35.tar.gz
    
    # gunzip -dc gd-2.0.35.tar.gz | tar -xf -
    
    # cd gd-2.0.35
    
    # ./configure --prefix=/opt/libgd
    ...
    # make
    ...
    # make install
    ...
    
    

    Build Nagios server

    get the nagios source from www.nagios.org

    # gunzip -dc nagios-3.0.3.tar.gz | tar -xf -
    
    # cd nagios-3.0.3
    
    # groupadd -g 510 nagios
    # useradd -u 510 -g nagios nagios
    

    Referee to the Read Only Webaccount Patch below

    # ./configure --prefix=/opt/nagios-3.0.3 --with-nagios-user=nagios --with-nagios-group=nagios --with-gd-lib=/opt/libgd/lib   --with-gd-inc=/opt/libgd/include
    
    # gmake 
    





    Read Only Web account patch

    get the patch from http://www.nagios3book.com/

    in the directory you have extracted the nagios source code:

    # wget http://www.nagios3book.com/nagios-3-enm/patches/readonly.tar
    
    # tar xvf readonly.tar
    
    
    

    in the cgi/ dir

    # patch -r cgiauth.c < cgiauth.diff
    # patch -r extinfo.c < extinfo.diff
    

    and in the include/ dir

    # patch -r cgiauth.h < cgiauth.h.diff
    
    Cookies help us deliver our services. By using our services, you agree to our use of cookies.
    Cookies help us deliver our services. By using our services, you agree to our use of cookies.