Quantcast
Channel: Ocsinventory Q&A - Recent questions and answers in OCS Inventory NG server
Viewing all 7071 articles
Browse latest View live

How to use 2 differents certificates on OCS

$
0
0
Hello,

I red that OCS agent doesn't accept wildcard certificate. But i absolutely need a signed certificate because i can't have the navigator security warning that we get with autosgned certificate.

Someone know if it's possible to configure one autosigned certificate for the agent and one wildcard certificate just for the web page?

Informations. OCS server is a Debian 8, Apache version 2.4.1,

Thank you very much for your help.

Answered: Force Inventory Update

Search package don't work on teledeploy page

VM CentOS + OCS Server - No access to Portal

$
0
0
Hello,

When I try to open xxx.xxx.xxx/ocsreports on the physical machine I can not access it. Do I need to configure something in OCS Reports or Linux? SELinux is disabled.

Thanks!

Error 500 Win10 agent 2.3.1.1:undefined subroutine

$
0
0

Hello,

after hours of researches on your website, impossible to find a solution to my basic problem : My OCS Agent 2.3.1.1 is unable to send its data collected on the Windows 10 to OCS Server : it logs error 500 ! But no other post could help me ! (I had install previously a OCS server in a similar way and I had absolutely NO such problem, so, as I’m using exactly the same method I can’t understand why it’s not running for this second install !).

Here are my configurations :

1. OCS Server (perfectly running with with OCS -Reports) :

Système :

  • Nom du système :Linux x86_64

  • Version :4.9.0-4-amd64

  • RAM totale :2004 Mo

  • RAM disponible :1673 Mo

  • CPU :Intel(R) Xeon(R) CPU E5606 @ 2.13GHz

  • Distribution :Debian GNU/Linux 9 (stretch)

Logiciel :

  • Version de PHP :7.0.27

  • Serveur Web :Apache/2.4.25 (Debian)

  • Serveur SQL :Debian 9.1 version 10.1.26-MariaDB-0+deb9u1

  • Version OCSReports:2.4.

Réseau :

  • IP: 172.16.20.190/17

2. In my Win10Pro station where agent 2.3.1.1 is running :

    • C:\programData\OCS Inventory NG\Agent\OCSInventory.log : after good connection to the server at the beginning of the process (code 200 received), finally, error 500 appears and NO inventory can be sent to the server... => see BOLD lines ...

Starting OCS Inventory NG Agent on Thursday, May 17, 2018 16:49:49.

AGENT => Running OCS Inventory NG Agent Version 2.3.1.1

AGENT => Using OCS Inventory NG FrameWork Version 2.3.1.1

AGENT => Loading plug-in(s)

DLL PLUGIN => Searching for Plug-in DLL(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>

DLL PLUGIN => 0 DLL Plug-in(s) successfully loaded on 0 DLL(s) found

AGENT => Using network connection with Communication Server

COM PROVIDER => Loading Communication Provider <C:\Program Files (x86)\OCS Inventory Agent\ComHTTP.dll>

AGENT => Using Communication Provider <OCS Inventory NG cURL Communication Provider> Version <2.3.1.1>

AGENT => Sending Prolog

DID_CHECK => Read DeviceID <WIN10-PRO-BASE--2018-05-02-11-43-33> and MACs <00:50:56:0B:BA:CD> in file <ocsinventory.dat>

COM SERVER => Initializing cURL library for sendRequest

COM SERVER => Using cURL without server authentication

COM SERVER => Disabling cURL proxy support

COM SERVER => Enabling cURL SSL server validation support using CA Bundle <C:\ProgramData\OCS Inventory NG\Agent\cacert.pem>

COM SERVER => Sending HTTP Post request to URL <http://172.16.20.190/ocsinventory>

COM SERVER => HTTP Post response received <HTTP Status Code #200>

COM SERVER => Cleaning cURL library

AGENT => Prolog successfully sent

AGENT => Prolog Frequency set to 24 hour(s)

AGENT => Inventory on startup option set to 1

AGENT => Inventory required

AGENT => Launching hardware and software checks

INVENTORY => Loading Download history

INVENTORY => Logged on user ID is <Administrateur>

INVENTORY => Operating System is <Microsoft Windows 10 Professionnel 10.0.15063 >, description <>

INVENTORY => User domain is <>

INVENTORY => System Manufacturer <VMware, Inc.>, System Model <VMware Virtual Platform>, System S/N <VMware-42 15 46 34 2e fc ef bf-91 9c ff 36 96 4d 4a a8>, Bios Manufacturer <Phoenix Technologies LTD>, Bios Date <07/09/2012>, Bios Version <6.00>, Motherboard Manufacturer <Intel Corporation>, Motherboard Model <440BX Desktop Reference Platform>, Motherboard S/N <None>

....
WARNING *** INVENTORY => Failed to retrieve modems

INVENTORY => 1 network adapter(s) found

...
INVENTORY => System Memory set to 6144 (instead of 6144)

INVENTORY => Reading last inventory state

EXECUTABLE PLUGIN => Searching for VBS script(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>

EXECUTABLE PLUGIN => Searching for PS1 script(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>

AGENT => Sending Inventory

INVENTORY => Checking last inventory state

INVENTORY => Logical drives inventory state changed

...

INVENTORY => Printers inventory state changed

INVENTORY => Inventory changed since last run

INVENTORY => Generating XML document with Device properties

INVENTORY => XML Update BIOS

INVENTORY => XML Update 2 CPU(s)

...
INVENTORY => XML Update 0 Registry Value(s)

INVENTORY => XML Update Administrative Information(s)

INVENTORY => XML Update common Device properties

COM SERVER => Initializing cURL library for sendRequest

COM SERVER => Using cURL without server authentication

COM SERVER => Disabling cURL proxy support

COM SERVER => Enabling cURL SSL server validation support using CA Bundle <C:\ProgramData\OCS Inventory NG\Agent\cacert.pem>

COM SERVER => Sending HTTP Post request to URL <http://172.16.20.190/ocsinventory>

COM SERVER => HTTP Post response received <HTTP Status Code #500>

COM SERVER => Cleaning cURL library

ERROR *** AGENT => Failed to send Inventory <HTTP Status Code #500>

AGENT => Communication Server ask for Package Download

DOWNLOAD => Package history file successfully cleaned for duplicate IDs

DOWNLOAD => Download disabled by server

AGENT => Unloading communication provider

AGENT => Unloading plug-in(s)

AGENT => Execution duration: 00:00:31.


 

3. In my OCS server :

    • /var/log/apache2/access.log : error 500 appears after code 200 Ok.

172.16.0.68 - - [17/May/2018:16:42:52 +0200] "POST /ocsinventory HTTP/1.1" 200 411 "-""OCS-NG_WINDOWS_AGENT_v2.3.1.1"

172.16.0.68 - - [17/May/2018:16:43:05 +0200] "POST /ocsinventory HTTP/1.1"500 842 "-""OCS-NG_WINDOWS_AGENT_v2.3.1.1"

172.16.0.68 - - [17/May/2018:16:49:49 +0200] "POST /ocsinventory HTTP/1.1" 200 411 "-""OCS-NG_WINDOWS_AGENT_v2.3.1.1"

172.16.0.68 - - [17/May/2018:16:50:20 +0200] "POST /ocsinventory HTTP/1.1"500 842 "-""OCS-NG_WINDOWS_AGENT_v2.3.1.1"

    • /var/log/apache2/error.log : « strange » programming errors in different scripts on lines 38, 48, 66, 74, 103 (in eg. : « Undefined subroutine » =>???). I can’t understand why that kind of errors appear. And how I can solve them ! It is as if some Perl or Php programs were missing... ??? => see BOLD lines ...

[Thu May 17 16:33:17.119893 2018] [:error] [pid 5499] [client 10.10.10.6:53540] PHP Warning: mysqli_real_escape_string() expects parameter 1 to be mysqli, null given in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 66, referer: http://172.16.20.190/ocsreports/

[Thu May 17 16:33:17.119958 2018] [:error] [pid 5499] [client 10.10.10.6:53540] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, null given in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 103, referer: http://172.16.20.190/ocsreports/

[Thu May 17 16:33:17.119975 2018] [:error] [pid 5499] [client 10.10.10.6:53540] PHP Warning: mysqli_fetch_object() expects parameter 1 to be mysqli_result, null given in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 38, referer: http://172.16.20.190/ocsreports/

[Thu May 17 16:33:58.005945 2018] [:error] [pid 5498] [client 10.10.10.6:53548] PHP Warning: mysqli_real_escape_string() expects parameter 1 to be mysqli, null given in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 66, referer: http://172.16.20.190/ocsreports/

[Thu May 17 16:33:58.006004 2018] [:error] [pid 5498] [client 10.10.10.6:53548] PHP Warning: mysqli_query() expects parameter 1 to be mysqli, null given in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 103, referer: http://172.16.20.190/ocsreports/

[Thu May 17 16:33:58.006021 2018] [:error] [pid 5498] [client 10.10.10.6:53548] PHP Warning: mysqli_fetch_object() expects parameter 1 to be mysqli_result, null given in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 38, referer: http://172.16.20.190/ocsreports/

[Thu May 17 16:38:25.929608 2018] [:error] [pid 5504] [client 10.10.10.6:53601] PHP Warning: vsprintf(): Too few arguments in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 74, referer: http://172.16.20.190/ocsreports/index.php

[Thu May 17 16:38:25.929666 2018] [:error] [pid 5504] [client 10.10.10.6:53601] PHP Warning: mysqli_query(): Empty query in /usr/share/ocsinventory-reports/ocsreports/require/function_commun.php on line 103, referer: http://172.16.20.190/ocsreports/index.php

[Thu May 17 16:43:05.450371 2018] [perl:error] [pid 5513] [client 172.16.0.68:64801] Undefined subroutine &Apache::Ocsinventory::Server::Inventory::Update::set_asset_category called at /usr/local/share/perl/5.24.1/Apache/Ocsinventory/Server/Inventory/Update.pm line 48.\n

[Thu May 17 16:50:20.146113 2018] [perl:error] [pid 5516] [client 172.16.0.68:64833] Undefined subroutine &Apache::Ocsinventory::Server::Inventory::Update::set_asset_category called at /usr/local/share/perl/5.24.1/Apache/Ocsinventory/Server/Inventory/Update.pm line 48.


 

My question is : Would you have an idea to solve that kind of problem, please ?


 

Thanks for your advises or solutions.

Best regards.


 


 

Answered: configuracion

$
0
0
Hello frank, thank you for responding.

Of course every time I make a change I restart Apache like mariadb, but that error does not disappear, at first when I just started the installation that problem did not appear, now I can not correct it.

Answered: Plugin install ocsreports

Answered: Install unix plugins on OCSversion 2.3


Answered: How to install self-created plugin on OCS 2.4?

Answered: Plugin OCS 2.2 (EON 5.1)

Is there any documentation on the Rest API for OCS

$
0
0
I'm looking to pull out information about a specific computer using its serial number?

Answered: Is there any documentation on the Rest API for OCS

$
0
0
Hi,

The documentation is under writing.
Regards

Frank

Answered: Plugin data not obtained from the clients/agents

$
0
0

Hello,

I found a similar issue using a custom powershell plugin and OCS Inventory Agent (the latest version 2.3.1.1).

I build a powershell plugin to get version of Microsoft App Package.

The plugin is based on Get-AppxPackage powershell function (example (Get-AppxPackage -name "Microsoft.MSPaint").Version") to get the version and then extend the XML for software.

The final output is:

Write-Host '<SOFTWARES>'

Write-Host '<PUBLISHER>' $appeditor '</PUBLISHER>'

Write-Host '<VERSION>' $version '</VERSION>'

Write-Host '<NAME>' $appname '</NAME>'

Write-Host '</SOFTWARES>'

I've copied the .ps1 scripts on the client and tested it. Executing this:

OCSInventory.exe /local="D:\test" /force /xml="D:\test"

It works. I'm able to get an XLM file with proper data and in the XML there are informations with the software App version.

Using debug I also found this section;

AGENT =>  Communication Server ask for Registry QueryREGISTRY => Executing query asked by serverREGISTRY => 13 query successfully executedEXECUTABLE PLUGIN => Searching for VBS script(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>EXECUTABLE PLUGIN => Searching for PS1 script(s) in folder <C:\Program Files (x86)\OCS Inventory Agent\plugins>EXECUTABLE PLUGIN => Found executable plugin <plugin.ps1>================= TRACE START ================================ TRACE STOP ===============EXECUTABLE PLUGIN => Plugin <plugin.ps1> executed successfullyAGENT => Sending Inventory

But if I proceed with a standard installation I'm able to check that plugin is in the right place, BUT seems those informations are not sent or parsed server-side.

How can I debug it?

Thanks,

invalid default OCS_DB_LOCAL name

$
0
0

when the package is installed, incorrect name of some variables by default in the files:

1. /etc/httpd/conf.d/z-ocsinventory-server.conf

PerlSetEnv OCS_DB_NAME ocsweb //(corretc 'ocs')

PerlSetEnv OCS_DB_LOCAL ocsweb //(corretc 'ocs')

2. /etc/httpd/conf.d/zz-ocsinventory-restapi.conf

$ENV{OCS_DB_LOCAL} = 'ocsweb'; //(corretc 'ocs')

Answered: ERREUR: Fichier manquant runningDatabaseinstances


Warning: PERL module Apache2::SOAP

$
0
0

Lors de l'installation d'OCSNG UNIX SERVER 2.4.1, j'ai le message d'erreur ci-dessous car je n'arrive pas à installer le package sur ma VM sous Debian 9.4.

Checking for Apache2::SOAP PERL module...
*** Warning: PERL module Apache2::SOAP is not installed !
This module is only required by OCS Inventory NG SOAP Web Service.

root@OCSInventory-NG:~# perl -MCPAN -e shell
Terminal does not support AddHistory.

cpan shell -- CPAN exploration and modules installation (v2.16)
Enter 'h' for help.

cpan[1]> install Apache2::SOAP
Reading '/root/.cpan/Metadata'
  Database was generated on Mon, 14 May 2018 20:54:15 GMT
Fetching with LWP:
http://www.cpan.org/authors/01mailrc.txt.gz
Reading '/root/.cpan/sources/authors/01mailrc.txt.gz'
............................................................................DONE
Fetching with LWP:
http://www.cpan.org/modules/02packages.details.txt.gz
Reading '/root/.cpan/sources/modules/02packages.details.txt.gz'
  Database was generated on Sun, 20 May 2018 16:41:03 GMT
............................................................................DONE
Fetching with LWP:
http://www.cpan.org/modules/03modlist.data.gz
Reading '/root/.cpan/sources/modules/03modlist.data.gz'
DONE
Writing /root/.cpan/Metadata
Running install for module 'Apache2::SOAP'
Checksum for /root/.cpan/sources/authors/id/R/RK/RKOBES/Apache2-SOAP-0.73.tar.gz ok
Scanning cache /root/.cpan/build for sizes
Use of uninitialized value $newdir in substitution (s///) at /usr/lib/x86_64-linux-gnu/perl/5.24/Cwd.pm line 368.
Use of uninitialized value $newdir in chdir at /usr/lib/x86_64-linux-gnu/perl/5.24/Cwd.pm line 377.
Use of uninitialized value $cwd in concatenation (.) or string at /usr/local/share/perl/5.24.1/CPAN/CacheMgr.pm line 81.
Catching error: "Can't chdir to : No such file or directory at /usr/local/share/perl/5.24.1/CPAN/Distribution.pm line 469.\cJ" at /usr/local/share/perl/5.24.1/CPAN.pm line 392.
        CPAN::shell() called at -e line 1
 

Merci de votre aide.

Answered: ERREUR: Fichier manquant runningDatabaseinstances

$
0
0
Effectivement, il manque des fichiers dans la v. 1.0

> Prenez le contenu de la v. 1.2 sur GitHub et ça fonctionnera.

Answered: ERREUR: Fichier manquant runningDatabaseinstances

$
0
0
D'accord merci pour votre aide :)

Configuration Vmware Vcenter Inventory

$
0
0
Bonjour,

Après avoir installer le plugin Vmware Vcenter, je n'arrive pas à avoir la remonter des données.

J'ai configurer celui-ci dans Vmware.pm en mettant mon url ainsi que mes ID et MDP en base 64 mais toujours rien. Pour info je les ai écrit comme ceci: nom@domaine + mdp

Groupe dynamique et télédeploiement - OCS V2.4.1

$
0
0
Bonjour,

Au lancement de la version serveur 2.4, il est indiqué que : "À partir de maintenant, vous pouvez affecter des paquets de redistribution aux machines à partir d’un groupe dynamique et de groupes statiques"

J'ai installé cette version pour la tester. La fonctionnalité qui vise à attribuer un paquet sur un groupe dynamique a particulièrement retenu mon attention.
Cependant, lorsque j'ajoute un paquet à un groupe, toutes les machines présentes dans le cache du groupe se voient affecter le paquet. Lorsque le cache est regénéré et que d'autres machines sont ajoutées automatiquement au groupe, ces machines ne bénéficient pas du paquet.

Est ce une mauvaise compréhension de ma part ou il y aurait il une configuration à faire en plus ?
Je pensais que l'attribution des paquets à un groupe dynamique était également dynamique pour toutes les machines qui sont rajoutées après que le cache n'expire et que la requête soit rejouée.

D'avance merci pour vos réponses
Viewing all 7071 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>