Symptoms
When a host is linked to a host category, the update fails with the following error in the logs:
[ERROR] Rollback of 'PartialUpdateHost' transaction {"custom":{"trace":"#0 /usr/share/centreon/src/Core/Host/Application/UseCase/PartialUpdateHost/PartialUpdateHostValidation.php(258): Core\\Host\\Application\\Exception\\HostException::idsDoNotExist()\n#1 /usr/share/centreon/src/Core/Host/Application/UseCase/PartialUpdateHost/PartialUpdateHost.php(438): Core\\Host\\Application\\UseCase\\PartialUpdateHost\\PartialUpdateHostValidation->assertAreValidCategories()\n#2 /usr/share/centreon/src/Core/Host/Application/UseCase/PartialUpdateHost/PartialUpdateHost.php(183): Core\\Host\\Application\\UseCase\\PartialUpdateHost\\PartialUpdateHost->updateHostCategories()\n#3 /usr/share/centreon/src/Core/Host/Application/UseCase/PartialUpdateHost/PartialUpdateHost.php(152): Core\\Host\\Application\\UseCase\\PartialUpdateHost\\PartialUpdateHost->updatePropertiesInTransaction()\n#4 /usr/share/centreon/src/Core/Host/Infrastructure/API/PartialUpdateHost/PartialUpdateHostController.php(65): Core\\Host\\Application\\UseCase\\PartialUpdateHost\\PartialUpdateHost->__invoke()\n#5 /usr/share/centreon/vendor/symfony/http-kernel/HttpKernel.php(183): Core\\Host\\Infrastructure\\API\\PartialUpdateHost\\PartialUpdateHostController->__invoke()\n#6 /usr/share/centreon/vendor/symfony/http-kernel/HttpKernel.php(76): Symfony\\Component\\HttpKernel\\HttpKernel->handleRaw()\n#7 /usr/share/centreon/vendor/symfony/http-kernel/Kernel.php(182): Symfony\\Component\\HttpKernel\\HttpKernel->handle()\n#8 /usr/share/centreon/src/App/Shared/Infrastructure/Legacy/LegacyKernelWrapper.php(55): Symfony\\Component\\HttpKernel\\Kernel->handle()\n#9 /usr/share/centreon/src/App/Shared/Infrastructure/Legacy/ForwardLegacyRoutesListener.php(52): App\\Shared\\Infrastructure\\Legacy\\LegacyKernelWrapper->handle()\n#10 /usr/share/centreon/vendor/symfony/event-dispatcher/EventDispatcher.php(246): App\\Shared\\Infrastructure\\Legacy\\ForwardLegacyRoutesListener->__invoke()\n#11 /usr/share/centreon/vendor/symfony/event-dispatcher/EventDispatcher.php(206): Symfony\\Component\\EventDispatcher\\EventDispatcher::Symfony\\Component\\EventDispatcher\\{closure}()\n#12 /usr/share/centreon/vendor/symfony/event-dispatcher/EventDispatcher.php(56): Symfony\\Component\\EventDispatcher\\EventDispatcher->callListeners()\n#13 /usr/share/centreon/vendor/symfony/http-kernel/HttpKernel.php(159): Symfony\\Component\\EventDispatcher\\EventDispatcher->dispatch()\n#14 /usr/share/centreon/vendor/symfony/http-kernel/HttpKernel.php(76): Symfony\\Component\\HttpKernel\\HttpKernel->handleRaw()\n#15 /usr/share/centreon/vendor/symfony/http-kernel/Kernel.php(182): Symfony\\Component\\HttpKernel\\HttpKernel->handle()\n#16 /usr/share/centreon/vendor/symfony/runtime/Runner/Symfony/HttpKernelRunner.php(35): Symfony\\Component\\HttpKernel\\Kernel->handle()\n#17 /usr/share/centreon/vendor/autoload_runtime.php(29): Symfony\\Component\\Runtime\\Runner\\Symfony\\HttpKernelRunner->run()\n#18 /usr/share/centreon/api/index.php(24): require_once('...')\n#19 {main}"},"exception":null,"default":{"request_infos":{"uri":"/centreon/api/latest/configuration/hosts/1836","http_method":"PATCH","server":"centreon.domain.net"}}}
Checks already done
- SQL verification confirms that category x exists in
hostcategories - Removing the category allows the host update to succeed
- This seems to be related to host category validation in
PartialUpdateHost
Impact
We are unable to modify any host as long as it is linked to a host category.
Question
Has anyone already faced this issue on Centreon 25.10?
Is there a known bug, fix, or workaround for host category validation through the /configuration/hosts/{id} API?
Only with admin user i can moify but all my other_ users with ACL have the same problem with all hosts linked to a catégory host
Thanks in avance for your help
