Closed steph461 closed 1 year ago
glpi_networkports.
logical_number = 'gi8' maybe ?
No idea how to reproduce. Please provide information/inventory file so we can reproduce and then fix.
in the file
I got no error using provided file. We need a way to reproduce from a fresh 10.0.5 install; you probably have changed some settings.
I delete the switch I launch a cmd : glpi-netdiscovery.bat --host 10.xx.xx.x..x -i -s c:\folders
1 netdiscovery OK no error
I will try instal in a blank base 10.0.5
[2022-11-07 09:52:49] glpisqllog.WARNING: DBmysql::query() in /var/www/html/glpi/src/DBmysql.php line 404
*** MySQL query warnings:
SQL: SELECT `glpi_computers`.`id`, `glpi_networkports`.`id` AS `portid` FROM `glpi_computers` LEFT JOIN `glpi_networkports` ON (`glpi_computers`.`id` = `glpi_networkports`.`items_id` AND `glpi_networkports`.`itemtype` = 'Computer') WHERE (`glpi_networkports`.`mac` IN ('10:f9:20:d0:4e:7e')) AND (`glpi_networkports`.`logical_number` = 'gi8')
Warnings:
1292: Truncated incorrect DECIMAL value: 'gi8'
Backtrace :
src/DBmysqlIterator.php:112
src/DBmysql.php:1056 DBmysqlIterator->execute()
src/RuleImportAsset.php:538 DBmysql->request()
src/Rule.php:1649 RuleImportAsset->findWithGlobalCriteria()
src/Rule.php:1507 Rule->checkCriterias()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/NetworkPort.php:251 RuleCollection->processAllRules()
src/Inventory/Asset/NetworkPort.php:514 Glpi\Inventory\Asset\NetworkPort->handleLLDPConnection()
src/Inventory/Asset/NetworkPort.php:538 Glpi\Inventory\Asset\NetworkPort->handleConnections()
src/Inventory/Asset/NetworkPort.php:533 Glpi\Inventory\Asset\NetworkPort->portChanged()
src/Inventory/Asset/InventoryNetworkPort.php:615 Glpi\Inventory\Asset\NetworkPort->portCreated()
src/Inventory/Asset/InventoryNetworkPort.php:120 Glpi\Inventory\Asset\NetworkPort->handleCreates()
src/Inventory/Asset/NetworkPort.php:690 Glpi\Inventory\Asset\NetworkPort->handlePortsTrait()
src/Inventory/Asset/NetworkPort.php:523 Glpi\Inventory\Asset\NetworkPort->handlePorts()
src/Inventory/Asset/MainAsset.php:862 Glpi\Inventory\Asset\NetworkPort->handle()
src/Inventory/Asset/MainAsset.php:782 Glpi\Inventory\Asset\MainAsset->handleAssets()
src/Inventory/Asset/NetworkEquipment.php:222 Glpi\Inventory\Asset\MainAsset->rulepassed()
src/RuleImportAsset.php:950 Glpi\Inventory\Asset\NetworkEquipment->rulepassed()
src/Rule.php:1510 RuleImportAsset->executeActions()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/MainAsset.php:564 RuleCollection->processAllRules()
src/Inventory/Inventory.php:702 Glpi\Inventory\Asset\MainAsset->handle()
src/Inventory/Inventory.php:337 Glpi\Inventory\Inventory->handleItem()
src/Inventory/Request.php:360 Glpi\Inventory\Inventory->doInventory()
src/Inventory/Request.php:283 Glpi\Inventory\Request->inventory()
src/Inventory/Request.php:250 Glpi\Inventory\Request->network()
src/Inventory/Request.php:98 Glpi\Inventory\Request->networkInventory()
src/Agent/Communication/AbstractRequest.php:305 Glpi\Inventory\Request->handleAction()
src/Agent/Communication/AbstractRequest.php:242 Glpi\Agent\Communication\AbstractRequest->handleXMLRequest()
src/Inventory/Conf.php:252 Glpi\Agent\Communication\AbstractRequest->handleRequest()
src/Inventory/Conf.php:193 Glpi\Inventory\Conf->importContentFile()
front/inventory.conf.php:47 Glpi\Inventory\Conf->importFile()
{"user":"7@srv-glpi"}
[2022-11-07 09:52:49] glpisqllog.WARNING: DBmysql::query() in /var/www/html/glpi/src/DBmysql.php line 404
*** MySQL query warnings:
SQL: SELECT `glpi_networkequipments`.`id`, `glpi_networkports`.`id` AS `portid` FROM `glpi_networkequipments` LEFT JOIN `glpi_networkports` ON (`glpi_networkequipments`.`id` = `glpi_networkports`.`items_id` AND `glpi_networkports`.`itemtype` = 'NetworkEquipment') WHERE (`glpi_networkports`.`mac` IN ('10:f9:20:d0:4e:7e')) AND (`glpi_networkports`.`logical_number` = 'gi8')
Warnings:
1292: Truncated incorrect DECIMAL value: 'gi8'
Backtrace :
src/DBmysqlIterator.php:112
src/DBmysql.php:1056 DBmysqlIterator->execute()
src/RuleImportAsset.php:538 DBmysql->request()
src/Rule.php:1649 RuleImportAsset->findWithGlobalCriteria()
src/Rule.php:1507 Rule->checkCriterias()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/NetworkPort.php:251 RuleCollection->processAllRules()
src/Inventory/Asset/NetworkPort.php:514 Glpi\Inventory\Asset\NetworkPort->handleLLDPConnection()
src/Inventory/Asset/NetworkPort.php:538 Glpi\Inventory\Asset\NetworkPort->handleConnections()
src/Inventory/Asset/NetworkPort.php:533 Glpi\Inventory\Asset\NetworkPort->portChanged()
src/Inventory/Asset/InventoryNetworkPort.php:615 Glpi\Inventory\Asset\NetworkPort->portCreated()
src/Inventory/Asset/InventoryNetworkPort.php:120 Glpi\Inventory\Asset\NetworkPort->handleCreates()
src/Inventory/Asset/NetworkPort.php:690 Glpi\Inventory\Asset\NetworkPort->handlePortsTrait()
src/Inventory/Asset/NetworkPort.php:523 Glpi\Inventory\Asset\NetworkPort->handlePorts()
src/Inventory/Asset/MainAsset.php:862 Glpi\Inventory\Asset\NetworkPort->handle()
src/Inventory/Asset/MainAsset.php:782 Glpi\Inventory\Asset\MainAsset->handleAssets()
src/Inventory/Asset/NetworkEquipment.php:222 Glpi\Inventory\Asset\MainAsset->rulepassed()
src/RuleImportAsset.php:950 Glpi\Inventory\Asset\NetworkEquipment->rulepassed()
src/Rule.php:1510 RuleImportAsset->executeActions()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/MainAsset.php:564 RuleCollection->processAllRules()
src/Inventory/Inventory.php:702 Glpi\Inventory\Asset\MainAsset->handle()
src/Inventory/Inventory.php:337 Glpi\Inventory\Inventory->handleItem()
src/Inventory/Request.php:360 Glpi\Inventory\Inventory->doInventory()
src/Inventory/Request.php:283 Glpi\Inventory\Request->inventory()
src/Inventory/Request.php:250 Glpi\Inventory\Request->network()
src/Inventory/Request.php:98 Glpi\Inventory\Request->networkInventory()
src/Agent/Communication/AbstractRequest.php:305 Glpi\Inventory\Request->handleAction()
src/Agent/Communication/AbstractRequest.php:242 Glpi\Agent\Communication\AbstractRequest->handleXMLRequest()
src/Inventory/Conf.php:252 Glpi\Agent\Communication\AbstractRequest->handleRequest()
src/Inventory/Conf.php:193 Glpi\Inventory\Conf->importContentFile()
front/inventory.conf.php:47 Glpi\Inventory\Conf->importFile()
{"user":"7@srv-glpi","mem_usage":"0.001\", 10.08Mio)"}
[2022-11-07 09:52:49] glpisqllog.WARNING: DBmysql::query() in /var/www/html/glpi/src/DBmysql.php line 404
*** MySQL query warnings:
SQL: SELECT `glpi_phones`.`id`, `glpi_networkports`.`id` AS `portid` FROM `glpi_phones` LEFT JOIN `glpi_networkports` ON (`glpi_phones`.`id` = `glpi_networkports`.`items_id` AND `glpi_networkports`.`itemtype` = 'Phone') WHERE (`glpi_networkports`.`mac` IN ('10:f9:20:d0:4e:7e')) AND (`glpi_networkports`.`logical_number` = 'gi8')
Warnings:
1292: Truncated incorrect DECIMAL value: 'gi8'
Backtrace :
src/DBmysqlIterator.php:112
src/DBmysql.php:1056 DBmysqlIterator->execute()
src/RuleImportAsset.php:538 DBmysql->request()
src/Rule.php:1649 RuleImportAsset->findWithGlobalCriteria()
src/Rule.php:1507 Rule->checkCriterias()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/NetworkPort.php:251 RuleCollection->processAllRules()
src/Inventory/Asset/NetworkPort.php:514 Glpi\Inventory\Asset\NetworkPort->handleLLDPConnection()
src/Inventory/Asset/NetworkPort.php:538 Glpi\Inventory\Asset\NetworkPort->handleConnections()
src/Inventory/Asset/NetworkPort.php:533 Glpi\Inventory\Asset\NetworkPort->portChanged()
src/Inventory/Asset/InventoryNetworkPort.php:615 Glpi\Inventory\Asset\NetworkPort->portCreated()
src/Inventory/Asset/InventoryNetworkPort.php:120 Glpi\Inventory\Asset\NetworkPort->handleCreates()
src/Inventory/Asset/NetworkPort.php:690 Glpi\Inventory\Asset\NetworkPort->handlePortsTrait()
src/Inventory/Asset/NetworkPort.php:523 Glpi\Inventory\Asset\NetworkPort->handlePorts()
src/Inventory/Asset/MainAsset.php:862 Glpi\Inventory\Asset\NetworkPort->handle()
src/Inventory/Asset/MainAsset.php:782 Glpi\Inventory\Asset\MainAsset->handleAssets()
src/Inventory/Asset/NetworkEquipment.php:222 Glpi\Inventory\Asset\MainAsset->rulepassed()
src/RuleImportAsset.php:950 Glpi\Inventory\Asset\NetworkEquipment->rulepassed()
src/Rule.php:1510 RuleImportAsset->executeActions()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/MainAsset.php:564 RuleCollection->processAllRules()
src/Inventory/Inventory.php:702 Glpi\Inventory\Asset\MainAsset->handle()
src/Inventory/Inventory.php:337 Glpi\Inventory\Inventory->handleItem()
src/Inventory/Request.php:360 Glpi\Inventory\Inventory->doInventory()
src/Inventory/Request.php:283 Glpi\Inventory\Request->inventory()
src/Inventory/Request.php:250 Glpi\Inventory\Request->network()
src/Inventory/Request.php:98 Glpi\Inventory\Request->networkInventory()
src/Agent/Communication/AbstractRequest.php:305 Glpi\Inventory\Request->handleAction()
src/Agent/Communication/AbstractRequest.php:242 Glpi\Agent\Communication\AbstractRequest->handleXMLRequest()
src/Inventory/Conf.php:252 Glpi\Agent\Communication\AbstractRequest->handleRequest()
src/Inventory/Conf.php:193 Glpi\Inventory\Conf->importContentFile()
front/inventory.conf.php:47 Glpi\Inventory\Conf->importFile()
{"user":"7@srv-glpi","mem_usage":"0.001\", 10.08Mio)"}
[2022-11-07 09:52:49] glpisqllog.WARNING: DBmysql::query() in /var/www/html/glpi/src/DBmysql.php line 404
*** MySQL query warnings:
SQL: SELECT `glpi_printers`.`id`, `glpi_networkports`.`id` AS `portid` FROM `glpi_printers` LEFT JOIN `glpi_networkports` ON (`glpi_printers`.`id` = `glpi_networkports`.`items_id` AND `glpi_networkports`.`itemtype` = 'Printer') WHERE (`glpi_networkports`.`mac` IN ('10:f9:20:d0:4e:7e')) AND (`glpi_networkports`.`logical_number` = 'gi8')
Warnings:
1292: Truncated incorrect DECIMAL value: 'gi8'
Backtrace :
src/DBmysqlIterator.php:112
src/DBmysql.php:1056 DBmysqlIterator->execute()
src/RuleImportAsset.php:538 DBmysql->request()
src/Rule.php:1649 RuleImportAsset->findWithGlobalCriteria()
src/Rule.php:1507 Rule->checkCriterias()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/NetworkPort.php:251 RuleCollection->processAllRules()
src/Inventory/Asset/NetworkPort.php:514 Glpi\Inventory\Asset\NetworkPort->handleLLDPConnection()
src/Inventory/Asset/NetworkPort.php:538 Glpi\Inventory\Asset\NetworkPort->handleConnections()
src/Inventory/Asset/NetworkPort.php:533 Glpi\Inventory\Asset\NetworkPort->portChanged()
src/Inventory/Asset/InventoryNetworkPort.php:615 Glpi\Inventory\Asset\NetworkPort->portCreated()
src/Inventory/Asset/InventoryNetworkPort.php:120 Glpi\Inventory\Asset\NetworkPort->handleCreates()
src/Inventory/Asset/NetworkPort.php:690 Glpi\Inventory\Asset\NetworkPort->handlePortsTrait()
src/Inventory/Asset/NetworkPort.php:523 Glpi\Inventory\Asset\NetworkPort->handlePorts()
src/Inventory/Asset/MainAsset.php:862 Glpi\Inventory\Asset\NetworkPort->handle()
src/Inventory/Asset/MainAsset.php:782 Glpi\Inventory\Asset\MainAsset->handleAssets()
src/Inventory/Asset/NetworkEquipment.php:222 Glpi\Inventory\Asset\MainAsset->rulepassed()
src/RuleImportAsset.php:950 Glpi\Inventory\Asset\NetworkEquipment->rulepassed()
src/Rule.php:1510 RuleImportAsset->executeActions()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/MainAsset.php:564 RuleCollection->processAllRules()
src/Inventory/Inventory.php:702 Glpi\Inventory\Asset\MainAsset->handle()
src/Inventory/Inventory.php:337 Glpi\Inventory\Inventory->handleItem()
src/Inventory/Request.php:360 Glpi\Inventory\Inventory->doInventory()
src/Inventory/Request.php:283 Glpi\Inventory\Request->inventory()
src/Inventory/Request.php:250 Glpi\Inventory\Request->network()
src/Inventory/Request.php:98 Glpi\Inventory\Request->networkInventory()
src/Agent/Communication/AbstractRequest.php:305 Glpi\Inventory\Request->handleAction()
src/Agent/Communication/AbstractRequest.php:242 Glpi\Agent\Communication\AbstractRequest->handleXMLRequest()
src/Inventory/Conf.php:252 Glpi\Agent\Communication\AbstractRequest->handleRequest()
src/Inventory/Conf.php:193 Glpi\Inventory\Conf->importContentFile()
front/inventory.conf.php:47 Glpi\Inventory\Conf->importFile()
{"user":"7@srv-glpi","mem_usage":"0.000\", 10.08Mio)"}
[2022-11-07 09:52:49] glpisqllog.WARNING: DBmysql::query() in /var/www/html/glpi/src/DBmysql.php line 404
*** MySQL query warnings:
SQL: SELECT `glpi_unmanageds`.`id`, `glpi_networkports`.`id` AS `portid` FROM `glpi_unmanageds` LEFT JOIN `glpi_networkports` ON (`glpi_unmanageds`.`id` = `glpi_networkports`.`items_id` AND `glpi_networkports`.`itemtype` = 'Unmanaged') WHERE (`glpi_networkports`.`mac` IN ('10:f9:20:d0:4e:7e')) AND (`glpi_networkports`.`logical_number` = 'gi8')
Warnings:
1292: Truncated incorrect DECIMAL value: 'gi8'
Backtrace :
src/DBmysqlIterator.php:112
src/DBmysql.php:1056 DBmysqlIterator->execute()
src/RuleImportAsset.php:538 DBmysql->request()
src/Rule.php:1649 RuleImportAsset->findWithGlobalCriteria()
src/Rule.php:1507 Rule->checkCriterias()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/NetworkPort.php:251 RuleCollection->processAllRules()
src/Inventory/Asset/NetworkPort.php:514 Glpi\Inventory\Asset\NetworkPort->handleLLDPConnection()
src/Inventory/Asset/NetworkPort.php:538 Glpi\Inventory\Asset\NetworkPort->handleConnections()
src/Inventory/Asset/NetworkPort.php:533 Glpi\Inventory\Asset\NetworkPort->portChanged()
src/Inventory/Asset/InventoryNetworkPort.php:615 Glpi\Inventory\Asset\NetworkPort->portCreated()
src/Inventory/Asset/InventoryNetworkPort.php:120 Glpi\Inventory\Asset\NetworkPort->handleCreates()
src/Inventory/Asset/NetworkPort.php:690 Glpi\Inventory\Asset\NetworkPort->handlePortsTrait()
src/Inventory/Asset/NetworkPort.php:523 Glpi\Inventory\Asset\NetworkPort->handlePorts()
src/Inventory/Asset/MainAsset.php:862 Glpi\Inventory\Asset\NetworkPort->handle()
src/Inventory/Asset/MainAsset.php:782 Glpi\Inventory\Asset\MainAsset->handleAssets()
src/Inventory/Asset/NetworkEquipment.php:222 Glpi\Inventory\Asset\MainAsset->rulepassed()
src/RuleImportAsset.php:950 Glpi\Inventory\Asset\NetworkEquipment->rulepassed()
src/Rule.php:1510 RuleImportAsset->executeActions()
src/RuleCollection.php:1591 Rule->process()
src/Inventory/Asset/MainAsset.php:564 RuleCollection->processAllRules()
src/Inventory/Inventory.php:702 Glpi\Inventory\Asset\MainAsset->handle()
src/Inventory/Inventory.php:337 Glpi\Inventory\Inventory->handleItem()
src/Inventory/Request.php:360 Glpi\Inventory\Inventory->doInventory()
src/Inventory/Request.php:283 Glpi\Inventory\Request->inventory()
src/Inventory/Request.php:250 Glpi\Inventory\Request->network()
src/Inventory/Request.php:98 Glpi\Inventory\Request->networkInventory()
src/Agent/Communication/AbstractRequest.php:305 Glpi\Inventory\Request->handleAction()
src/Agent/Communication/AbstractRequest.php:242 Glpi\Agent\Communication\AbstractRequest->handleXMLRequest()
src/Inventory/Conf.php:252 Glpi\Agent\Communication\AbstractRequest->handleRequest()
src/Inventory/Conf.php:193 Glpi\Inventory\Conf->importContentFile()
front/inventory.conf.php:47 Glpi\Inventory\Conf->importFile()
{"user":"7@srv-glpi","mem_usage":"0.000\", 10.08Mio)"}
I found there was a link on another switch, I removed the problematic line in the XML file and it works. delete all lines Its OK
I close this issue
its not just this, there are multiple "decimal" errors.
[2022-11-21 09:16:09] glpisqllog.WARNING: DBmysql::query() in /usr/share/glpi/src/DBmysql.php line 404 *** MySQL query warnings: SQL: SELECT * FROM
glpi_lockedfieldsWHERE
itemtype= 'Item_DevicePowerSupply' AND ((
items_id= '' OR
is_global= '1')) Warnings: 1292: Truncated incorrect DECIMAL value: ''
@we-sell-bags
This is not the same error, please open a new issue.
Code of Conduct
Is there an existing issue for this?
Version
10.0.5
Bug description
After Start a inventory task (snmp for example), There are several error messages on tables in the log SQL. the same message Truncated incorrect DECIMAL value: 'gi8' is displayed.
glpi_computers
.
id glpi_networkequipments.
id glpi_phones.
idglpi_unmanageds
.id
all table *.id maybe ....
Relevant log output
Page URL
glpi/marketplace/glpiinventory/front/task.php
Steps To reproduce
Start an inventory task with the plugin glpiinventory
Your GLPI setup information
Informations sur le système, l'installation et la configuration
Server
GLPI constants
Libraries
SQL replicas
Plugins list
Anything else?
No response