Ad Widget

Collapse

Tables missing in database.

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • elementalmist
    Junior Member
    • Oct 2020
    • 3

    #1

    Tables missing in database.

    Hi All,

    I was basically just thrown into a Zabbix Admin role at my company with no prior experience with Zabbix or Galera/MySQL and its been broken since the day the last guy left


    I've been doing my best to repair it, and i've gotten it working mostly. But i'm running into an error.
    • Error in query [SELECT MIN(ht.c) AS min_clock FROM (SELECT MIN(ht.clock) AS c FROM trends_uint ht WHERE ht.itemid='50292' UNION ALL SELECT MIN(ht.clock) AS c FROM trends_uint ht WHERE ht.itemid='50287') ht] [Table 'zabbix.trends_uint' doesn't exist]


    This table seems to exist on the proxys, but not the servers. I'm not sure how it would've been deleted. Is there any way to restore this table? I looked in /var/lib/mysql/zabbix and I don't see the trends_uint.ibd there. Just the FRM and a bunch of other files.

    Click image for larger version

Name:	zabbix.PNG
Views:	1571
Size:	31.5 KB
ID:	411886

    (Sorry in advance if this is a dumb question)
  • tim.mooney
    Senior Member
    • Dec 2012
    • 1427

    #2
    Sorry you've inherited a mess. That's a tough situation to be in.

    It seems like your trends_uint table may have been partitioned, using mysql Partitioning. If you connect up to mysql using the mysql command-line monitor and then do:

    Code:
    use zabbix;
    SHOW CREATE TABLE trends_unit\G
    It should tell you whether that table is a partitioned table.

    What version of Zabbix are you running? How big is your monitoring environment? You can get the # of items, triggers, hosts, via the web front end. It would also be useful to include the calculated value for NVPS (new values per second, a measure of how busy your server can expect to be).

    Comment

    • elementalmist
      Junior Member
      • Oct 2020
      • 3

      #3
      Originally posted by tim.mooney
      Sorry you've inherited a mess. That's a tough situation to be in.

      It seems like your trends_uint table may have been partitioned, using mysql Partitioning. If you connect up to mysql using the mysql command-line monitor and then do:

      Code:
      use zabbix;
      SHOW CREATE TABLE trends_unit\G
      It should tell you whether that table is a partitioned table.

      What version of Zabbix are you running? How big is your monitoring environment? You can get the # of items, triggers, hosts, via the web front end. It would also be useful to include the calculated value for NVPS (new values per second, a measure of how busy your server can expect to be).


      Hey Tim,

      Thanks for the help! Appreciate the sympathy haha.

      i'm getting this back.
      Click image for larger version

Name:	zabbix2.PNG
Views:	1535
Size:	4.5 KB
ID:	412026

      We're running Zabbix 3.0.27. Which is apparently the only version vetted by my leadership

      We have two servers (primary, backup), and 2 proxy pairs (primary1, backup1, primary2, backup2).
      The tables that are missing seem to exist on the proxies but not the servers.

      We have 3744 hosts that we're monitoring 763 Linux boxes, and 1981 Windows Server nodes.

      Click image for larger version

Name:	zabbix3.PNG
Views:	1514
Size:	15.9 KB
ID:	412027

      Comment

      Working...