Microtik Pluggin Log error

General discussion about Plugins for Cacti

Moderators: Developers, Moderators

Post Reply
JinitShah
Posts: 4
Joined: Sat May 11, 2019 1:44 am

Microtik Pluggin Log error

Post by JinitShah »

06/06/2019 23:34:48 - CMDPHP ERROR: A DB Exec Failed!, Error: Table 'cacti.plugin_mikrotik_storage' doesn't exist
06/06/2019 23:34:48 - CMDPHP SQL Backtrace: (/plugins/mikrotik/poller_mikrotik.php[138]:checkHost(), /plugins/mikrotik/poller_mikrotik.php[802]:collect_storage(), /plugins/mikrotik/poller_mikrotik.php[1537]:collectHostIndexedOid(), /plugins/mikrotik/poller_mikrotik.php[1197]:db_execute(), /lib/database.php[187]:db_execute_prepared())
06/06/2019 23:34:48 - CMDPHP ERROR: A DB Exec Failed!, Error: Table 'cacti.plugin_mikrotik_storage' doesn't exist

Getting this error in Microtik Plugin Latest version
Cacti v1.2.3
rrd 1.4x
Spine latest version v1.2.3
netniV
Cacti Guru User
Posts: 3441
Joined: Sun Aug 27, 2017 12:05 am

Re: Microtik Pluggin Log error

Post by netniV »

I would report this on github
Cacti Developer & Release Manager
The Cacti Group

Director
BV IT Solutions Ltd

+--------------------------------------------------------------------------+

Cacti Resources:
Cacti Website (including releases)
Cacti Issues
Cacti Development Releases
Cacti Development Documentation
JinitShah
Posts: 4
Joined: Sat May 11, 2019 1:44 am

Re: Microtik Pluggin Log error

Post by JinitShah »

Any solution for it
gargola
Posts: 1
Joined: Thu Jun 20, 2019 6:38 pm

Re: Microtik Pluggin Log error

Post by gargola »

I'm having the same issues:

Code: Select all

2019/06/20 17:36:00 - CMDPHP SQL Backtrace: (/plugins/mikrotik/poller_mikrotik.php[135]:process_hosts(), /plugins/mikrotik/poller_mikrotik.php[635]:db_execute(), /lib/database.php[187]:db_execute_prepared())
2019/06/20 17:36:00 - CMDPHP ERROR: A DB Exec Failed!, Error: Table 'cacti.plugin_mikrotik_storage' doesn't exist
2019/06/20 17:36:00 - CMDPHP SQL Backtrace: (/plugins/mikrotik/poller_mikrotik.php[135]:process_hosts(), /plugins/mikrotik/poller_mikrotik.php[608]:db_execute(), /lib/database.php[187]:db_execute_prepared())
2019/06/20 17:36:00 - CMDPHP ERROR: A DB Exec Failed!, Error: Table 'cacti.plugin_mikrotik_storage' doesn't exist
2019/06/20 17:35:04 - POLLER: Poller[Main Poller] WARNING: Invalid Response(s), Errors[1] Device[2.O-RB1100AHx2] Thread[1] DS[2.O-RB1100AHx2 - Uptime] Graphs[2.O-RB1100AHx2 - Uptime]
jfrater
Posts: 1
Joined: Fri Mar 20, 2020 9:52 am

Re: Microtik Pluggin Log error

Post by jfrater »

In my case I had to create that table:

CREATE TABLE IF NOT EXISTS `plugin_mikrotik_storage` (
`host_id` int(10) unsigned NOT NULL,
`index` int(10) unsigned NOT NULL,
`type` int(10) unsigned NOT NULL default '1',
`description` varchar(255) NOT NULL default '',
`allocationUnits` int(10) unsigned NOT NULL default '0',
`size` int(10) unsigned NOT NULL default '0',
`used` int(10) unsigned NOT NULL default '0',
`failures` int(10) unsigned NOT NULL default '0',
`present` tinyint(3) unsigned NOT NULL DEFAULT '1',
PRIMARY KEY (`host_id`,`index`),
INDEX `description` (`description`),
INDEX `index` (`index`))
ENGINE=MyISAM
COMMENT='Stores the Storage Information';

Engine should be InnoDB but but since I get the error #1709 - Index column size too large. The maximum column size is 767 bytes. I had to use MyISAM.

Pretty sure that is the underlying problem but since it works I didn't want to mess with it.
User avatar
Osiris
Cacti Guru User
Posts: 1424
Joined: Mon Jan 05, 2015 10:10 am

Re: Microtik Pluggin Log error

Post by Osiris »

You should Google this error and get yourself back to innodb as it's the way forward. The solution is pretty strait forward:

Innodb file per table =1
Innodb large prefix = on
Innodb file format = Barracuda

Restart MariaDB, then run:

php -q convert_tables.php --dynamic --innodb
Before history, there was a paradise, now dust.
Post Reply

Who is online

Users browsing this forum: No registered users and 0 guests