pluginsGLPI / ocsinventoryng

Plugin ocsinventoryng for GLPI
GNU General Public License v2.0
68 stars 52 forks source link

Error to synchronize computers already imported #285

Closed allan-altair closed 3 years ago

allan-altair commented 3 years ago

After upgrading the GPLI 9.5.2 to 9.5.4 and the OCS Inventory plugin 1.7.0 to 1.7.3, when synchronize computers already imported in the debug mode show the message below:

PHP Notice (8): Undefined index: max_glpidate in glpi/plugins/ocsinventoryng/inc/ocsserver.class.php at line 2221

Nix-adm commented 3 years ago

After upgrading from GPLI 9.4.6 to 9.5.3 and upgrade the OCS Inventory plugin to 1.7.3. The synchronization has ceased functioning. Error logs :

PHP Notice: Undefined index: COMPUTERS in ocsng_fullsync.php on line 221 PHP Warning: count(): Parameter must be an array or an object that implements Countable in ocsng_fullsync.php on line 221

Thanks for help

abonanni commented 3 years ago

Hello, You can test my pull request : https://github.com/pluginsGLPI/ocsinventoryng/pull/294

Flix886 commented 3 years ago

Hello,

done succesfully, but now i get no longer infomation like software, OS and components. It is only th asset with serialnumber.

2021-06-04 13_54_01-GLPI - Computer - 1191

2021-06-04 13_50_31-GLPI - Computer - 1191

Flix886 commented 3 years ago

Hi, problem is solved. It works now but don`t ask me why :D

allan-altair commented 3 years ago

Hello @abonanni,

I upgraded my plugin for the version that you mentioned, but I have the same problem.

PHP Notice (8): Undefined index: max_glpidate in glpi/plugins/ocsinventoryng/inc/ocsserver.class.php at line 2221

Thanks in advance

allan-altair commented 3 years ago

Hello @abonanni,

I upgraded my plugin for the version that you mentioned, but I have the same problem.

PHP Notice (8): Undefined index: max_glpidate in glpi/plugins/ocsinventoryng/inc/ocsserver.class.php at line 2221

Thanks in advance

abonanni commented 3 years ago

Hello @allan-altair

My commit solve "PHP Notice: Undefined index: COMPUTERS in ocsng_fullsync.php on line 221" problem but not "Undefined index: max_glpidate".

Without copy of your database it will be hard to debug.

allan-altair commented 3 years ago

@abonanni

How can I share my database with you?

Nix-adm commented 3 years ago

My workaround is change 'archive' fields from null to '0' in ocs database. I started with a test from only four servers.