Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Log noyé sous les erreurs ( 1 giga en 1 journée ) #362

Open
jlb5980 opened this issue Jun 23, 2023 · 8 comments
Open

Log noyé sous les erreurs ( 1 giga en 1 journée ) #362

jlb5980 opened this issue Jun 23, 2023 · 8 comments

Comments

@jlb5980
Copy link

jlb5980 commented Jun 23, 2023

Bonjour

A chaque import des machines d'ocs à glpi je recupére dans le log php-error de glpi

2023-06-23 11:53:34] glpiphplog.WARNING: *** PHP User Warning (512): Relation between "glpi_networkports" and "glpi_plugin_ocsinventoryng_networkports" table based on "networkports_id" field cannot be handled automatically as "networkports_id" also corresponds to index field of the target table. in /data/glpiv/src/DbUtils.php at line 2099
Backtrace :
src/DbUtils.php:2099 trigger_error()
inc/db.function.php:585 DbUtils->getDbRelations()
src/CommonDBTM.php:866 getDbRelations()
src/CommonDBTM.php:788 CommonDBTM->cleanRelationData()
src/CommonDBTM.php:2064 CommonDBTM->deleteFromDB()
src/MassiveAction.php:1495 CommonDBTM->delete()
src/MassiveAction.php:1408 MassiveAction::processMassiveActionsForOneItemtype()
src/MassiveAction.php:1386 MassiveAction->processForSeveralItemtypes()
front/massiveaction.php:59 MassiveAction->process()

Cc message je le rencontre également dans le ocsng_fullsync.log qui est d'ailleurs noyer sous les messages d'erreurs de ce type !

Et encore bravo pour le maintien du plugin .
Cordialement

  • The version of the plugin. : ocsinventoryng 2.0.4
  • The version of your GLPI : 10.0.7
  • The steps to reproduce your issue.
@jlb5980 jlb5980 changed the title impossible de supprimer un ordinateur ou un autre objet Log noyé sous les erreurs ( 1 giga en 1 journée ) Jun 30, 2023
@eilkh
Copy link

eilkh commented Aug 1, 2023

Bonjour, même problème de mon coté...

The version of the plugin. : ocsinventoryng 2.0.4
The version of your GLPI : 10.0.9
The steps to reproduce your issue :

  • Launch script manually :
  1. /usr/bin/php /var/www/html/glpi/marketplace/ocsinventoryng/scripts/run.php --thread_nbr=2 --server_id=1
  2. sh /var/www/html/glpi/marketplace/ocsinventoryng/scripts/ocsng_fullsync.sh --thread_nbr=2 --server_id=1

tsmr added a commit that referenced this issue Aug 1, 2023
@ajavor
Copy link

ajavor commented Aug 8, 2023

hurray, @tsmr is back! thanks a lot for this fix, it works :)

@eilkh
Copy link

eilkh commented Aug 8, 2023

Thank you !!

@jlb5980
Copy link
Author

jlb5980 commented Sep 14, 2023

Merci

@hiscorebob
Copy link

Hi
We have noticed the same issue in our setup, with GLPI updated to latest version 10.0.10.
The fixed hook.php doesn't seem to work for this version.

Thank you for any help or idea!

Kind Regards

@blippercop
Copy link

@hiscorebob Can you give more details what is not working?

@hiscorebob
Copy link

@hiscorebob Can you give more details what is not working?

Automated sync with shell scripts are not working.
I see a lot of following errors in glpi/files/_log/php-errors.log:

CRITICAL: *** Uncaught Exception Error: Call to a member function add() on null in /var/www/html/glpi/marketplace/ocsinventoryng/inc/networkport.class.php at line 270

WARNING: *** PHP User Warning (512): Relation between "glpi_networkports" and "glpi_plugin_ocsinventoryng_networkports" table based on "networkports_id" field cannot be handled automatically as "networkports_id" also corresponds to index field of the target table. in /var/www/html/glpi/src/DbUtils.php at line 2131
Backtrace :
src/DbUtils.php:2131 trigger_error()
inc/db.function.php:585 DbUtils->getDbRelations()
src/CommonDBTM.php:866 getDbRelations()
src/CommonDBTM.php:788 CommonDBTM->cleanRelationData()
src/CommonDBTM.php:2068 CommonDBTM->deleteFromDB()
src/CommonDBTM.php:4631 CommonDBTM->delete()
marketplace/ocsinventoryng/inc/os.class.php:254 CommonDBTM->deleteByCriteria()

@roms2000
Copy link

roms2000 commented Apr 14, 2024

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants