When I recently ran validate.php it informed me that my database is out of date, and asked me to fix it by running ./lnms migrate.
After running the migrate command I got various errors, so I searched this forum and came upon the thread here.
I followed the instructions kindly provided by Murrant, but after a while reached a point beyond which I cannot proceed. The queries just return errors.
Here’s the current output from “sudo -u librenms ./lnms migrate --pretend”: https://pastebin.com/q5tnAhMf
Running the first command in that list simply returns this error:
SQLSTATE[42S22]: Column not found: 1054 Unknown column ‘start_recurring_dt’ in ‘field list’ (SQL: update
start = CONVERT_TZ(IF(
recurring = 1, STR_TO_DATE(C
ONCAT(start_recurring_dt, ’ ', start_recurring_hr), ‘%Y-%m-%d %H:%i:%s’), start), @@global.time_zone, ‘+00:00’),
end = CONVERT_TZ(IF(
recurring = 1, STR_TO_DATE(CONCAT(IFNULL(en
d_recurring_dt, ‘9000-09-09’), ’ ', end_recurring_hr), ‘%Y-%m-%d %H:%i:%s’), end), @@global.time_zone, ‘+00:00’),
recurring_day = REPLACE(recurring_day, 0, 7))
Looking at the next command, I suspect it will also fail due to referencing the same columns.
Any help in getting through this would be greatly appreciated, as I’m not terribly good with database management.
Obligatory output from validate:
sudo -u librenms ./validate.php
Component | Version
--------- | -------
LibreNMS | 1.65-51-g3c78e0ccc
DB Schema | 2020_04_06_001048_the_great_index_rename (165)
PHP | 7.4.8
Python | 3.6.9
MySQL | 5.7.30-0ubuntu0.18.04.1
RRDTool | 1.7.0
SNMP | NET-SNMP 5.7.3
[OK] Composer Version: 1.10.9
[OK] Dependencies up-to-date.
[OK] Database connection successful
[FAIL] Your database is out of date!