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.12.3 available

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

[OCS 2.6] Problem with plugin installation

Hi!

OS Name : Linux x86_64
Version : 4.15.0-72-generic
Distribution : Ubuntu 18.04.3 LTS
PHP Version : 7.2.24
Web Server : Apache/2.4.29 (Ubuntu)
Database Server : (Ubuntu) version 5.7.29-0ubuntu0.18.04.1
Version OCSReports: 2.6

# wget -P /tmp/ https://github.com/PluginsOCSInventory-NG/security/archive/2.0.tar.gz

# sudo tar -xvzf /tmp/2.0.tar.gz -C /usr/share/ocsinventory-reports/ocsreports/extensions/

# rm /tmp/2.0.tar.gz

I'm logging in to the server now and: "Extensions" --> "Extensions manager" --> Install --> Logout --> Login

After that I'm going back to putty:

# sudo python3 /usr/share/ocsinventory-reports/ocsreports/tools/install_plugin.py

Plugin location: [/usr/share/ocsinventory-reports/ocsreports/extensions/]
[0] => security-2.0
Yes, server is installed on the same...
Server location: /etc/ocsinventory-server

And now I have first error (why?):

ERROR: check if Map.pm and security-2.0.conf exist

security-2.0.conf doesn't exist. In /usr/share/ocsinventory-reports/ocsreports/extensions/security-2.0/APACHE/ I have Map.pm and security.conf

 OK I change the name manually:

# sudo cp /usr/share/ocsinventory-reports/ocsreports/extensions/security-2.0/APACHE/security.conf /usr/share/ocsinventory-reports/ocsreports/extensions/security-2.0/APACHE/security-2.0.conf

 And again install_plugin.py - this time:

security-2.0has been successfully installed ! Don't forget to restart your Apache server

OK than... i restart server:

# sudo service apache2 restart

 And second error:

Job for apache2.service failed because the control process exited with error code.
See "systemctl status apache2.service" and "journalctl -xe" for details
.

With status:

[pid 20281] $s->add_config() has failed: Can't locate Apache/Ocsinventory/Plugins/Security/Map.pm in @INC (you may need to install the Apache::Ocsinventory::Plugins::Security::Map module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.26.1 /usr/local/share/perl/5.26.1 /usr/lib/x86_64-linux-gnu/perl5/5.26 /usr/share/perl/5.26 /usr/local/lib/site_perl /etc/apache2 /etc/ocsinventory-server/perl) at (eval 100) line 1.\nCompilation failed in require at (eval 99) line 1.\n

[perl:error] [pid 20281] Can't load Perl module Apache::Ocsinventory::Plugins for server glpi.mydomain:0, exiting...

I can again change it manualy:

sudo mv /etc/ocsinventory-server/perl/Apache/Ocsinventory/Plugins/Security-2.0/ /etc/ocsinventory-server/perl/Apache/Ocsinventory/Plugins/Security/

And apache reset will be OK. But what's the difference? As you can see, the plugin does not install correctly and I only encounter further problems. Why?

in OCS Inventory NG server for Unix by (810 points)

Please log in or register to answer this question.

 
Powered by Question2Answer
...