Ad Widget

Collapse

HELP PLEASE - Zabbix 1.8 UNIX Install - getting frustrating now !!!

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • newbie01.oracle
    Junior Member
    • Feb 2010
    • 18

    #1

    HELP PLEASE - Zabbix 1.8 UNIX Install - getting frustrating now !!!

    Hi all,

    Am trying to install Zabbix 1.8 from the source and using XAMPP. After several attempt, I finally managed to get it going.

    So far, I was able to get the zabbix_server and zabbix_agent running.

    From the document, it is very vague whether after doing a make install it will create the Zabbix conf file. Apparently it didn't so I copied all the .conf files that comes with the source and copied them to /etc

    My first problem is there is no "simple" instruction on what to setup as a minimum on either the zabbix_server.conf or zabbix_agent.conf file so not really sure what to configure as a minimum, can someone please advise on this? That is, am only interested on what are the minimum configuration settings that I need to set just to get Zabbix working

    The second problem is the Zabbix web interface, again, am I supposed to copy the whole frontends directory to wherever is my htdocs is?

    Last problem, the Zabbix database user, does it get created automatically? There is a note to create the Zabbix UNIX user, which I did but there is no mention on how to create the Zabbix database user? Also the manual did not mention anything about what should be the permissions, group etc of the Zabbix UNIX account, does this matter?

    Any help or feedback will be very much appreciated. Thanks in advance.
  • richlv
    Senior Member
    Zabbix Certified Trainer
    Zabbix Certified SpecialistZabbix Certified Professional
    • Oct 2005
    • 3112

    #2
    Originally posted by newbie01.oracle
    From the document, it is very vague whether after doing a make install it will create the Zabbix conf file. Apparently it didn't so I copied all the .conf files that comes with the source and copied them to /etc
    /etc/zabbix, i suppose
    Originally posted by newbie01.oracle
    My first problem is there is no "simple" instruction on what to setup as a minimum on either the zabbix_server.conf or zabbix_agent.conf file so not really sure what to configure as a minimum, can someone please advise on this? That is, am only interested on what are the minimum configuration settings that I need to set just to get Zabbix working
    default should do for the starters
    Originally posted by newbie01.oracle
    The second problem is the Zabbix web interface, again, am I supposed to copy the whole frontends directory to wherever is my htdocs is?
    yes
    Originally posted by newbie01.oracle
    Last problem, the Zabbix database user, does it get created automatically? There is a note to create the Zabbix UNIX user, which I did but there is no mention on how to create the Zabbix database user? Also the manual did not mention anything about what should be the permissions, group etc of the Zabbix UNIX account, does this matter?
    db user - no, you have to create user and insert sqls manually.
    unix user - for basic functionality no, but for some checks security restrictions might have to be modified
    Zabbix 3.0 Network Monitoring book

    Comment

    • tchjts1
      Senior Member
      • May 2008
      • 1605

      #3
      Originally posted by richlv
      /
      db user - no, you have to create user and insert sqls manually.
      This is from Linux, but should probably be the same for you on Unix:

      Start mysql – sudo /sbin/service mysql start
      Code:
      sudo mysql
      >create database zabbix character set utf8; 
      >grant all on zabbix.* to zabbix@’localhost’ identified by ‘password’;
      >quit;
      For the above statements, use 'localhost' if the app and DB run on the same machine. If the app server is on a separate machine, then substitue the IP of your Zabbix app server for 'localhost'. 'password' should be whatever password you have for user zabbix to access mysql.

      From /home/zabbix/zabbix-1.8.1/ (Or whatever your 1.8.1 code directory is)
      Code:
      cd create/schema
      cat mysql.sql | mysql -uroot -ppassword zabbix
      cd ../data
      cat data.sql | mysql -uroot -ppassword zabbix
      cat images_mysql.sql | mysql -uroot -ppassword zabbix
      for the above statements, you can use -uzabbix -ppassword if you like also.

      If you get stuck, send me a private message here... I have a decent set of Linux install directions start-to-finish that you could probably easily adapt to Unix.
      Last edited by tchjts1; 05-03-2010, 07:31.

      Comment

      • newbie01.oracle
        Junior Member
        • Feb 2010
        • 18

        #4
        Originally posted by tchjts1
        This is from Linux, but should probably be the same for you on Unix:

        Start mysql – sudo /sbin/service mysql start
        Code:
        sudo mysql
        >create database zabbix character set utf8; 
        >grant all on zabbix.* to zabbix@’localhost’ identified by ‘password’;
        >quit;
        For the above statements, use 'localhost' if the app and DB run on the same machine. If the app server is on a separate machine, then substitue the IP of your Zabbix app server for 'localhost'. 'password' should be whatever password you have for user zabbix to access mysql.

        From /home/zabbix/zabbix-1.8.1/ (Or whatever your 1.8.1 code directory is)
        Code:
        cd create/schema
        cat mysql.sql | mysql -uroot -ppassword zabbix
        cd ../data
        cat data.sql | mysql -uroot -ppassword zabbix
        cat images_mysql.sql | mysql -uroot -ppassword zabbix
        for the above statements, you can use -uzabbix -ppassword if you like also.

        If you get stuck, send me a private message here... I have a decent set of Linux install directions start-to-finish that you could probably easily adapt to Unix.
        Hi,

        Thanks to all who responded especially tchjts1, I will send you a private message later aas you've instructed.

        For the meantime, can you please confirm whether I need to create a zabbix database username or just create the schema? I was able to create the zabbix schema, but am not sure whether I need a zabbix database user or only a zabbix UNIX login, this is the part that is confusing me

        At the moment, I managed to create the schema, zabbix_agentd and zabbix_server are running. I copied all the example zabbix conf files to /etc/zabbix and had not touch them and I get some errors on the /tmp/zabbix_server.log and /tmp/zabbix_agentd.log which are expected since I have not made any changes on the sample conf files. My problem is I don't really know what to set or configure on the Zabbix .conf for a start, i.e. for example, CPU, disk space, memory etc.?

        From the zabbix_agent.log, am getting "No active checks on server: host [Zabbix Server} not found'

        From the zabbix_server.log, am getting "Sending list of active checks to [127.0.0.1] failed: host [Zabbix Server] not found"

        Am expecting these errors 'coz I had not configured the Zabbix .conf file and I cannot find a very minimal example of a Zabbix conf file to use as a test.

        FYI, on my test machine, Zabbix server and agent are on the same machine and it is not on the network so am expecting emailing to fail as well but would want to see that it try to sendmail alerts.

        Thanks in advance.

        Comment

        • tchjts1
          Senior Member
          • May 2008
          • 1605

          #5
          Originally posted by newbie01.oracle
          Hi,

          Thanks to all who responded especially tchjts1, I will send you a private message later aas you've instructed.

          For the meantime, can you please confirm whether I need to create a zabbix database username or just create the schema? I was able to create the zabbix schema, but am not sure whether I need a zabbix database user or only a zabbix UNIX login, this is the part that is confusing me

          At the moment, I managed to create the schema, zabbix_agentd and zabbix_server are running. I copied all the example zabbix conf files to /etc/zabbix and had not touch them and I get some errors on the /tmp/zabbix_server.log and /tmp/zabbix_agentd.log which are expected since I have not made any changes on the sample conf files. My problem is I don't really know what to set or configure on the Zabbix .conf for a start, i.e. for example, CPU, disk space, memory etc.?

          From the zabbix_agent.log, am getting "No active checks on server: host [Zabbix Server} not found'

          From the zabbix_server.log, am getting "Sending list of active checks to [127.0.0.1] failed: host [Zabbix Server] not found"

          Am expecting these errors 'coz I had not configured the Zabbix .conf file and I cannot find a very minimal example of a Zabbix conf file to use as a test.

          FYI, on my test machine, Zabbix server and agent are on the same machine and it is not on the network so am expecting emailing to fail as well but would want to see that it try to sendmail alerts.

          Thanks in advance.
          Under the circumstances, those are the errors one would expect to see without the configurations being completed.

          The basic configuration you have to do in zabbix_server.conf is near the end of the config where it wants the DB login info. I am not a Unix guy, so I don't know if you have to create a zabbix user or if you can just use the Unix user.

          On our Zabbix setups, we have a root account that we use for overall MySql administration, but then we also have a zabbix user account set up for access to the zabbix DB. We could use root if we wanted to, we just choose not to.

          So with that said... Here is what you need to configure in zabbix_server.conf

          Code:
          ### Option: DBHost
          #       Database host name.
          #       If set to localhost, socket is used for MySQL.
          #
          # Mandatory: no
          # Default:
          DBHost=localhost      [B]<-- use IP address of DB server if DB is on another machine[/B]
          ### Option: DBName
          #       Database name.
          #       For SQLite3 path to database file must be provided. DBUser and DBPassword are ignored.
          #
          # Mandatory: yes
          # Default:
          # DBName=
          
          DBName=zabbix
          
          ### Option: DBUser
          #       Database user. Ignored for SQLite.
          #
          # Mandatory: no
          # Default:
          # DBUser=
          
          DBUser=zabbix      [B]<-- Put the appropriate DB user here[/B]
          
          ### Option: DBPassword
          #       Database password. Ignored for SQLite.
          #       Comment this line if no password is used.
          #
          # Mandatory: no
          # Default:
          DBPassword=password     [B]<-- Use whatever password for your zabbix MySql user[/B]
          Now for your agent configuration:

          In /etc/zabbix/zabbix_agentd.conf -

          Code:
          ### Option: Server
          #       List of comma delimited IP addresses (or hostnames) of Zabbix servers.
          #       No spaces allowed. First entry is used for receiving list of and sending active checks.
          #       Note that hostnames must resolve hostname->IP address and IP address->hostname.
          #
          # Mandatory: yes
          # Default:
          # Server=
          
          Server=127.0.0.1    [B]<-- use this if the agent is on the same machine as the App server[/B]
          ### Option: Hostname
          #       Unique hostname.
          #       Required for active checks and must match hostname as configured on the server.
          #
          # Default:
          # Hostname=system.uname
          
          Hostname=Unix Test Box   [B]<--- make anything you want, but it must be changed in the front end (GUI) to match exactly, including spaces, lower/upper case[/B]
          This is just bits and pieces. respond to the private message I sent you and you will get the big picture.

          Comment

          Working...