Pandora FMS community forums
database broken after recent update - Printable Version

+- Pandora FMS community forums (https://pandorafms.org/forum)
+-- Forum: Pandora FMS (https://pandorafms.org/forum/forum-3.html)
+--- Forum: Advanced troubleshooting and problems (https://pandorafms.org/forum/forum-11.html)
+--- Thread: database broken after recent update (/thread-11725.html)



database broken after recent update - [email protected] - 05-02-2018

Hi All, I'm in a pickle now after the recent update. I get this error:

SQL error: Table 'pandora.tagent_secondary_group' doesn't exist ('SELECT DISTINCT count(DISTINCT id_agente) as total_agents FROM tagente LEFT JOIN tagent_secondary_group ON tagent_secondary_group.id_agent=tagente.id_agente WHERE tagent_secondary_group.id_group IN ("12", "8", "4", "9", "2", "10", "13", "11") OR `id_grupo` IN ("12", "8", "4", "9", "2", "10", "13", "11") AND 1 = 1 AND ( 1 = 1) AND disabled = 0 ') in /var/www/html/pandora_console/include/db/mysql.php on line 93.
The latest version of package installed is:

180430


If you can help I'd be very thankful!


RE: database broken after recent update - mkconsulting - 05-08-2018

I have the same issue. What Minor Release are you on? Mine is on MR 2. I have tried manually applying the updates and the file just have errors.


RE: database broken after recent update - mkconsulting - 05-08-2018

Found that the 14.sql file is the one that creates the tagent_secondary_group table. Even though the files have errors when I apply them I did them all anyways and now my console works properly.


RE: database broken after recent update - djungle - 06-27-2018

I also get this error and it's messing with the console display. I upgraded the 7.0NG Windows version from 719 to 724 using the update option in the installer. The upgrade went through without errors but when viewing the console, the database error message precedes most of the screen graphics.

I don't have access to any separate install files. Any fix?


RE: database broken after recent update - vic - 06-28-2018

Hi all,

You need to insert the MRs from the folder /var/www/html/pandora_console/extras/mr/X.sql (Insert it in order).

cat X.sql | mysql -u root -p <pandora_db_name>

Then move these files (X.sql) to the folder /var/www/html/pandora_console/extras/mr/updated

Lastly ejecute this command to modify the footer of the console.

update tconfig set value=17 where token='MR';

Best regards,
vic.


RE: database broken after recent update - djungle - 07-04-2018

Is there an equivalent set of commands for Windows setup?

thx Don


RE: database broken after recent update - bartvanleeuwen - 07-04-2018

Tried this,
still 'all systems down'

Thx Bart


RE: database broken after recent update - annomatik - 11-01-2018

Same here. First, the update destroyed my db (like in your post). Then, I tried again and now instead of the console, I only get "500 Internal Error". Also, server and agents are no longer working. I'm restoring an earlier backup of 726.

Let's hope this gets fixed soon.


RE: database broken after recent update - fraguas - 11-02-2018

Hello djungle , annomatik , bartvanleeuwen:

Remember that if you apply the MR , they must be in sequential order , that is, first 1.sql,2.sql..until arriving at the last one, since if for example, we pass a mr 15 before the mr 10 , possibly it will give us failure sql.



Anyway, I would like you to send me the server log, to see what may be causing your problems. Also you can make in the terminal a ""pandora_server -h"", and see if it throws some error.



I'm waiting for your answers.



Cordial greetings, and excuse the inconvenience,



Fraguas