Ad Widget

Collapse

Zabbix not collecting data after upgrading from 1.8 to 2.0

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • pdube
    Junior Member
    • Dec 2011
    • 23

    #1

    Zabbix not collecting data after upgrading from 1.8 to 2.0

    Hi,

    I upgraded Zabbix from 1.8.11 to 2.0.13 (running on Ubuntu 12.04LTS).

    I got the sources, compiled them, replaced php frontend files, replaced zabbix_server in /usr/sbin
    I upgraded the database using the path.sql script and it went well.

    Now in Zabbix interface, the Dashboard tells me that Zabbix Server is running but I cannot see any new data in any graph. It was working well for the last 2 years with 1.8.

    What's wrong? I don't know what else to check.

    TIA

    Paul
  • kloczek
    Senior Member
    • Jun 2006
    • 1771

    #2
    Did you done what is on https://www.zabbix.com/documentation...lation/upgrade?
    http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
    https://kloczek.wordpress.com/
    zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
    My zabbix templates https://github.com/kloczek/zabbix-templates

    Comment

    • pdube
      Junior Member
      • Dec 2011
      • 23

      #3
      Yes I did follow these instructions.
      I have a simple installation with default parameters and ports. Zabbix web, mysql runs on same box.

      Comment

      • pdube
        Junior Member
        • Dec 2011
        • 23

        #4
        Do I absolutely need to update the agents on my hosts?
        I tried to update zabbix agent on one host, without success (same result: no data retrieved on Zabbix server)
        Last edited by pdube; 02-11-2014, 16:56.

        Comment

        • BDiE8VNy
          Senior Member
          • Apr 2010
          • 680

          #5
          Originally posted by pdube
          Do I absolutely need to update the agents on my hosts?
          No, you don't. See Version compatibility

          Comment

          • kloczek
            Senior Member
            • Jun 2006
            • 1771

            #6
            Originally posted by pdube
            Yes I did follow these instructions.
            I have a simple installation with default parameters and ports. Zabbix web, mysql runs on same box.
            Did you check content of the logs?
            Except kind of effect that zabbix is not collecting the data you gave us nothing?
            No details about what happens on agents side or proxies (do you have some proxies?)
            If you are thinking that it is obvious reason, it is not.
            http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
            https://kloczek.wordpress.com/
            zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
            My zabbix templates https://github.com/kloczek/zabbix-templates

            Comment

            • pdube
              Junior Member
              • Dec 2011
              • 23

              #7
              No proxy. After rolling back to the snapshot of 1.8.11 everything works normally as before.

              In zabbix_server.log, right after a reboot I had errors saying " failed 2002 can't connect to local mysql server through socket".
              If, then, I stop and restart zabbix_server, there is no error message in the log, except for some "no records in table config", which is not true, but still no data collected.

              So, there must be something missing in my upgrade procedure, which I'll have to retry I guess.

              Any other idea what I might check?

              Comment

              • kloczek
                Senior Member
                • Jun 2006
                • 1771

                #8
                Originally posted by pdube
                No proxy. After rolling back to the snapshot of 1.8.11 everything works normally as before.

                In zabbix_server.log, right after a reboot I had errors saying " failed 2002 can't connect to local mysql server through socket".
                If, then, I stop and restart zabbix_server, there is no error message in the log, except for some "no records in table config", which is not true, but still no data collected.

                So, there must be something missing in my upgrade procedure, which I'll have to retry I guess.

                Any other idea what I might check?
                So why did you not solve problem with connecting to mysql engine instead rolling back all your changes?
                Did you made simple test using mysql command like:
                Code:
                mysql -p<zbx_password> -u<zbx_user> <zbx_db>
                ?

                Error message from server logs that was problem with conectiong to DB backend has only few explanations:
                • wrong user/password/zabbix db
                • DB engine is not working/is down


                Are you sure that you made DB scheme upgrade as it is described in doc?
                Messages about missing data suggest that you may not done DB upgrade or it was some problem during this part.
                Just as small test try to create empty test database -> import 2.0.x database schema -> list of available tables -> compare it with list of tables after upgrade DB schema to 2.0 layout.
                http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
                https://kloczek.wordpress.com/
                zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
                My zabbix templates https://github.com/kloczek/zabbix-templates

                Comment

                • pdube
                  Junior Member
                  • Dec 2011
                  • 23

                  #9
                  I was able to browse the database using msql Navigator.

                  Yes, I ran the mysql update script and it ran without errors.

                  I will get back to my snapshot of 2.0.13 tomorrow and do some more tests as you suggested. I will let you know.

                  Thank you.

                  Comment

                  • kloczek
                    Senior Member
                    • Jun 2006
                    • 1771

                    #10
                    Originally posted by pdube
                    I was able to browse the database using msql Navigator.

                    Yes, I ran the mysql update script and it ran without errors.

                    I will get back to my snapshot of 2.0.13 tomorrow and do some more tests as you suggested. I will let you know.

                    Thank you.
                    Mysql access on exact account usually is fro only specific host.
                    Running mysql from command test user/pwd from the same source address which will be using zabbix server. Browsing database from Navigator probably you been accessing to database not form the same src address as zabbix server is using.
                    As I wrote such issue has nothing to do with zabbix or zabbix upgrade. I'm almost sure that it is db backend access issue.
                    http://uk.linkedin.com/pub/tomasz-k%...zko/6/940/430/
                    https://kloczek.wordpress.com/
                    zapish - Zabbix API SHell binding https://github.com/kloczek/zapish
                    My zabbix templates https://github.com/kloczek/zabbix-templates

                    Comment

                    • pdube
                      Junior Member
                      • Dec 2011
                      • 23

                      #11
                      Database is fine. Access to the database should be fine.
                      Again I am running mysql, zabbix and web on the same server.

                      I checked the database and obviously the mysql update worked. Number of tables in 1.8.11: 88 ; number of tables after upgrade to 2.0.13: 103 tables.

                      I am using user root.
                      The only things defined in zabbix_server.conf are LogFile, DBName=zabbix, DBUser=root and DBPassword=********

                      My other problem is that I am not sure which conf zabbix_server is using.

                      I have zabbix_server.conf in
                      /etc/zabbix
                      /usr/local/etc
                      /usr/share/zabbix/misc/conf
                      /usr/share/zabbix/debian/zabbix-server-pgsql/usr/share/zabbix-server-pgsql
                      /usr/share/zabbix/debian/tmp-build-MYSQL/misc/conf
                      /usr/share/zabbix/debian/tmp-build-PGSQL/misc/conf
                      /usr/share/zabbix/debian/zabbix-server-mysql/usr/share/zabbix-server-mysql

                      Which one is it using?
                      However I updated the first 3 files in this list so that they have the correct user and password defined.

                      Could it be zabbix_server that was not compiled correctly?
                      I compiled using ./configure --enable-server --enable-agent --with-mysql --with-net-snmp --with-libcurl

                      What else do you suggest?

                      Comment

                      • kustodian
                        Member
                        • Oct 2012
                        • 33

                        #12
                        I'm not using Debian, but you should be able to run:
                        Code:
                        ps auxf | grep zabbix_server
                        find the zabbix_server master process, it should print with what parameters it was started, e.g:
                        Code:
                        zabbix_server -c /etc/zabbix/zabbix_server.conf
                        Other way to find out what config file it is using is to open the init script, which should be in /etc/init.d/zabbix-server.

                        Comment

                        • pdube
                          Junior Member
                          • Dec 2011
                          • 23

                          #13
                          Working now

                          Somehow I did not see that zabbix_server.conf did not have NodeId=1 which was needed.

                          With that it's working fine now.

                          Comment

                          Working...