Pandora FMS community forums
[Solved] No WMI After Upgrade [Error with WMI Explorer] - 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: [Solved] No WMI After Upgrade [Error with WMI Explorer] (/thread-7527.html)

Pages: 1 2


[Solved] No WMI After Upgrade [Error with WMI Explorer] - Murigar - 07-15-2014

After upgrade, WMI modules never initialize.

Upgrade steps performed. On working 5.0 SP4. Which was an updated appliance.

Below are my upgrade steps:
# /etc/init.d/pandora_server stop
# /etc/init.d/tentacle_serverd stop
# yum upgrade -y
(installs new RPMs, pandorafms_server, _console, _agent_unix)
# cat /var/www/html/pandora_console/extras/pandoradb_migrate_5.0.x_to_5.1.mysql.sql | mysql -uroot -pXXXXXXXXXXXXXX -D pandora
# /etc/init.d/pandora_server start
# /etc/init.d/tentacle_serverd start
# /usr/share/pandora_server/util/pandora_migrate_recon_scripts.pl pandora localhost pandora XXXXXXXXXXXXXX
(1 script migrated)

If I execute the WMI command manually it works fine.

The log shows:
"2014-07-15 10:00:43 pandorafmxxx.xxxx.xxx [V9] Executing AM # 3133 WMI command 'wmic -U "xxxxx/xxxxx"%"xxxxxx" --namespace="ROOT\CIMV2" //xxx.xx.x.xx "select PercentFreeSpace from Win32_PerfFormattedData_PerfDisk_LogicalDisk WHERE name = 'C:'"'
2014-07-15 10:00:43 pandorafmxxx.xxxx.xxx [V10] Updating module Free Disk Space C: % (ID 3133) on error.

Suggestions?




Re: No WMI After Upgrade - ivo_yordanov - 07-23-2014

Hello

Can you send us a copy of the execution of the command manually in a terminal and a screencapture of the module configuration.

Regards
Ivo


Re: No WMI After Upgrade - Murigar - 07-23-2014

Please keep in mind that I am providing a limited example. I have over 400 WMI modules in use in total. None of them will initialize after the upgrade.

Command:
[[email protected] pandora]# wmic -U XXX/XXX%XXX --namespace="ROOT\CIMV2" //x.x.x.x "select Name from Win32_PageFileUsage"

Returns:
CLASS: Win32_PageFileUsage
Name
C:\pagefile.sys

Screenshot of module:

[Image: 160setv.png]



Re: No WMI After Upgrade - Murigar - 07-23-2014

Below is the corresponding log file entry:


2014-07-23 14:39:57 pandorafmsairporttest.xxx.xxx.xxx [V9] Executing AM # 3126 WMI command 'wmic -U "xx/xxx"%"xxx" --namespace="ROOT\CIMV2" //x.x.x.x "select Name from Win32_PageFileUsage"'

2014-07-23 14:39:57 pandorafmsairporttest.xxx.xxx.xxx [V10] Updating module Page File Location (ID 3126) on error.


Re: No WMI After Upgrade - mario.pulido - 07-31-2014

Hi

Why you are using the field Namespace?

Have you tried using only Username:, Password and Query??

Regards


Re: No WMI After Upgrade - Murigar - 08-01-2014

Thank you for this discovery.

There is no specific reason why this is being used. But it is configured on all of my WMI modules.

From the GUI
In version 5.0 the back or forward slash "\" "/" works.
In version 5.1 only the forward slash "/" works.

From the CLI
Only the forward slash "/" works in both versions.

Is version 5.0 translating this on execution?

Do you know any way to change all the modules "/", or remove that field? I don't see that filed in the "Massive operations."


Re: No WMI After Upgrade - mario.pulido - 08-04-2014

Hi

You can't do it massively, but you can change it by mysql query:

update tagente_modulo set tcp_send = "/" where id_tipo_modulo = 3

Before to run this query, run this:

select * from tagente_modulo where id_tipo_modulo = 3

and check if all modules are WMI modules.

Regards



Re: No WMI After Upgrade - Murigar - 08-04-2014

Good Day,

Query: select * from tagente_modulo where id_tipo_modulo = 3;

Is returning 243 rows.

I have 424 WMI modules.

If I apply the update, I can confirm that it in fact only updates about half of them.

Any ideas?



Re: No WMI After Upgrade - mario.pulido - 08-05-2014

Oh Sorry,

id_tipo_modulo=3 is the type generic_data_string, not only WMI. Not exist any option to see only WMI modules in database. Only you can change it manually or if you have agents only with WMI modules, you can select the query as id_agent and change all modules at same time.

Regards


Re: No WMI After Upgrade - Murigar - 08-05-2014

I understand.

Wouldn't the below sql query accomplish the task of removing the entry?

update tagente_modulo set tcp_send = replace(tcp_send, ‘ROOT\CIMV2’, ‘’);