Welcome to OCS Inventory NG community support, where you can ask questions and receive answers from other members of the community.

Please ask questions only in English or French.

Release 2.11.1 available

The official documentation can be found on http://wiki.ocsinventory-ng.org. Read it before asking your question.

OCS Plugins - output is not a valid XML document


After installing the plugins in ocs-server and copying the plugins to the endpoints in the agent path. When I run an inventory collection through the agent, I can see the following in the OCSInventory.log of ProgramData.

AGENT => Inventory required

AGENT => Launching hardware and software checks

ERROR *** EXECUTABLE PLUGIN => Executable plugin <C:\Program Files\OCS Inventory Agent\plugins\winusers.ps1> output is not a valid XML document

AGENT => Sending Inventory

INVENTORY => Inventory changed since last run

AGENT => Inventory successfully sent

AGENT =>  Communication Server asked for Package Download

AGENT => Unloading communication provider

AGENT => Unloading plug-in(s)

AGENT => Execution duration: 00:05:26.

The winusers.ps1 script is the official script as of today.

But it doesn't only happen with this script, it happens with all the scripts I have added, they are plugins downloaded and installed from the official OCS website.

The error "output is not a valid XML document" happens to me with other plugins as well. Maybe I'm missing something?

Thanks, best regards.

in OCS Inventory NG plugins by (140 points)

1 Answer

0 votes

Hi @petate,

check that in the output values of the plugin there is no character < or > because these replace tags and can crash the information feedback of the plugin, or even of the entire inventory !

Otherwise, the execution of Powershell scripts (*.ps1) must be activated in the machine to be inventoried, see OCS wiki at : Enable Powershell Support on Windows Agent

by (32.6k points)
Powered by Question2Answer