Actions
Bug #5419
closedFusionInventory version check not handling version number correctly
Pull Request:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
Name check:
Fix check:
Regression:
Description
This was observed with rudder-agent-thin-2.11.2.release-1.FC.18.i386, but I think is present in all rudder-agent-thin versions.
# cf-agent -KID force_inventory ... 2014-08-25T13:18:02+0000 notice: /default/doInventory/methods/'any'/default/fusionAgent/commands/'/opt/rudder/bin/run-inventory --local=/var/rudder/tmp/inventory --scan-homedirs'[0]: Q: "...-inventory --lo": /opt/rudder/bin/run-inventory: line 35: [: FusionInventory Agent (23101): integer expression expected Q: "...-inventory --lo": [ERROR] The system FusionInventory version is too old to be used. (Found = FusionInventory Agent (2.3.10.1), Expected >= 2.2) ...
# fusioninventory-agent --version FusionInventory Agent (2.3.10.1)
In /opt/rudder/bin/run-inventory, line 34:
SYSTEM_FUSINV_VERSION=$(fusioninventory-agent --version | sed 's%.*(\([0-9]*\)\.\([0-9]*\)\.[0-9]*).*%\1.\2%')
The regex used will only match version number in the form of x.y.z. In our case the version number as a fourth component so the SYSTEM_FUSINV_VERSION variable is not valid and the version check fails.
Actions