Closed rcsmota closed 5 years ago
Was this a fresh install or an upgrade?
I have the same problem on upgrade, but this output was on a fresh instalation.
After I had a problem on upgrade i tried a fresh.
Well, that is strange given that the table is created between the others on a fresh install:
https://github.com/Cacti/plugin_routerconfigs/blob/develop/setup.php#L252
I will have a go myself and see if I can spot an issue.
So I have just tried this myself using Cacti v1.2.5
with mysql v14.14 (v5.7.26)
and routerconfigs v1.5.1
. I completely uninstalled and then installed fresh to get:
+----------------------------------+
| Tables_in_cacti_site (%router%) |
+----------------------------------+
| plugin_routerconfigs_accounts |
| plugin_routerconfigs_backups |
| plugin_routerconfigs_devices |
| plugin_routerconfigs_devicetypes |
+----------------------------------+
4 rows in set (0.00 sec)
Can you confirm what versions you are using?
Double check here, Cacti 1.2.4 with mysql Ver 15.1 Distrib 10.1.38-MariaDB, and routerconfigs 1.5.1.
I've removed all the files, and re-configured the installation to test, but I have the same problem.
Did you do the plugin uninstall process or simply remove the files?
I actually suspect that this is a MariaDB issue for some reason. Do you have anything in the logs for routerconfigs whilst its trying to install?
I uninstall (cacti, configuration, plugins) disable and uninstall before remove files.
I dont get any error on cacti log when installing the plugin, only when I try make a backup.
There is a way to "force" manual creation of this table to test?
This is my definition:
CREATE TABLE `plugin_routerconfigs_backups` (
`id` int(11) NOT NULL AUTO_INCREMENT,
`btime` int(18) DEFAULT NULL,
`device` int(11) DEFAULT NULL,
`directory` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`filename` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
`lastchange` int(24) DEFAULT NULL,
`lastuser` varchar(64) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
PRIMARY KEY (`id`),
KEY `btime` (`btime`),
KEY `device` (`device`),
KEY `directory` (`directory`),
KEY `lastchange` (`lastchange`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci COMMENT='Router Config Backups'
I don't know why (yet) but this is the error.
ERROR 1709 (HY000): Index column size too large. The maximum column size is 767 bytes.
My large prefix is on.
Must be a bug in that specific version since none of those add up to that much. Unless it’s the combined total.
Make some tests (decreased value) and manual create a table with this changes, the plugin work
directory
varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
filename
varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
to
directory
varchar(191) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
filename
varchar(191) COLLATE utf8mb4_unicode_ci DEFAULT NULL,
I don't know if this change can cause some problem in another place after
File/directory paths can be up to 255 in length so maybe but as long as you keep that paths short it shouldn’t be a problem. Are you using the barracuda format ?
This is my path to plugins directory. /opt/cacti/plugins/.
Yes I'm using barracuda format, I follow the recommendation on cacti install.
What happens if you use ROW_FORMAT=dynanic?
I made the change in the table
Everything work fine, but to do this i need create a table and after change the value.
Maybe I can add ROW_FORMAT=DYNAMIC after ENGINE=InnoDB DEFAULT on CREATE TABLE (my mysql skills are limited :) )
Yes, that is possible. I'll have to check what we did with other table creation code to see how that was done to enforce the dynamic mode.
Currently we do not have code that handles that. For now, as your issue is resolved, I am going to close this with the recommendation being that the default be InnoDB, Barracuda with DYNAMIC row_format
Hi; I'm using cacti 1.2.4 on Debian 9 with Routerconfigs 1.5.1 and I get this error.
CMDPHP ERROR: A DB Row Failed!, Error: Table 'cacti.plugin_routerconfigs_backups' doesn't exist
On mysql i see only this 3 tables
Thanks