Welcome to Pandora FMS Community!

Find answers, ask questions, and connect with our community around the world.

Welcome to Pandora FMS Community Forums Community support Advanced troubleshooting [Solved] No WMI After Upgrade [Error with WMI Explorer]

  • [Solved] No WMI After Upgrade [Error with WMI Explorer]

    Posted by Murigar on July 15, 2014 at 20:06

    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=”ROOTCIMV2″ //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?

    HerpDerper replied 9 years, 5 months ago 5 Members · 15 Replies
  • 15 Replies
  • ivo_yordanov

    Member
    July 23, 2014 at 17:11
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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

  • Murigar

    Member
    July 24, 2014 at 00:45
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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:
    [root@pandorafmsairporttest pandora]# wmic -U XXX/XXX%XXX –namespace=”ROOTCIMV2″ //x.x.x.x “select Name from Win32_PageFileUsage”

    Returns:
    CLASS: Win32_PageFileUsage
    Name
    C:pagefile.sys

    Screenshot of module:

  • Murigar

    Member
    July 24, 2014 at 00:52
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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=”ROOTCIMV2″ //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.

  • Mario

    Administrator
    July 31, 2014 at 19:52
    1150 Karma points
    Community rank: tentacle_master_icon Tentacle Master
    Like it
    Up
    0
    Down
    Drop it
    ::

    Hi

    Why you are using the field Namespace?

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

    Regards

  • Murigar

    Member
    August 1, 2014 at 18:41
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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.”

  • Mario

    Administrator
    August 4, 2014 at 14:19
    1150 Karma points
    Community rank: tentacle_master_icon Tentacle Master
    Like it
    Up
    0
    Down
    Drop it
    ::

    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

  • Murigar

    Member
    August 5, 2014 at 00:57
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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?

  • Mario

    Administrator
    August 5, 2014 at 20:23
    1150 Karma points
    Community rank: tentacle_master_icon Tentacle Master
    Like it
    Up
    0
    Down
    Drop it
    ::

    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

  • Murigar

    Member
    August 5, 2014 at 21:58
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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’, ‘’);

  • Murigar

    Member
    August 5, 2014 at 23:13
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    I believe this to be more accurate.

    Use pandora;
    Update tagente_modulo set tcp_send = replace(tcp_send,’ROOT\CIMV2′,”);

  • Mario

    Administrator
    August 6, 2014 at 12:41
    1150 Karma points
    Community rank: tentacle_master_icon Tentacle Master
    Like it
    Up
    0
    Down
    Drop it
    ::

    Oh, yes, if you have the same namespace in all module configuration you can use this query.

    Great!

  • HerpDerper

    Member
    March 18, 2015 at 17:47
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    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.”

    Just a heads up to everyone looking. This fixed my WMI login errors on domain servers. For some reason if you use a normal backslash “” it dosnt work. Change it to a forward slash “/” and the WMI browser/queries will work.

    For example: domain/administrator instead of domainadministrator

    Tag to help others find this… took me FOREVER:
    ERROR Unable to do WMI explorer

  • Carnivalesk

    Member
    September 3, 2015 at 06:49
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    Thanks Gray,

    I have check and re-loaded the controller files onto the server but still no luck…still the same error message…any futher ideas.?

    Many thanks
    A

  • Carnivalesk

    Member
    September 4, 2015 at 05:45
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    I am also getting this error sporadically, did the error return after changing legacy plug in?

  • HerpDerper

    Member
    September 4, 2015 at 05:51
    0 Karma points
    Community rank: tentacle-noob-1 Tentacle noob
    Like it
    Up
    0
    Down
    Drop it
    ::

    Did you read my post above your 1st one?