Bug #12599
closedRudder agent 4.3 needs libxml-treepp-perl on debian
Description
We should just add a dependency there
Error message is
Version: 4.3.0~rc2~git201803160036-stretch0 Can't locate XML/TreePP.pm in @INC (you may need to install the XML::TreePP module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.24.1 /usr/local/share/perl/5.24.1 /usr/lib/x86_64-linux-gnu/perl5/5.24 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.24 /usr/share/perl/5.24 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl line 5. BEGIN failed--compilation aborted at /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl line 5.
For reference, this is hard to reproduce and it may be due to a change in perl dependencies between debian 8 and debian 9.
We are not sure what leads to that problem, nor what exact version of debian/ubuntu are impacted. For example, it's possible to install a debian 9, install rudder agent, force remove treepp (
dpkg -r --force-depends libxml-treepp-perl), and still get a working inventory.
Updated by Vincent MEMBRÉ over 6 years ago
- Target version changed from 4.3.2 to 410
Updated by Benoît PECCATTE over 6 years ago
- Severity set to Major - prevents use of part of Rudder | no simple workaround
- User visibility set to Getting started - demo | first install | level 1 Techniques
- Priority changed from 0 to 70
Updated by Benoît PECCATTE over 6 years ago
- Target version changed from 410 to 4.3.2
Updated by François ARMAND over 6 years ago
- Related to Bug #7758: When several directives value have a CFEngine var, we get "unexpected" due to bad regex matching added
Updated by François ARMAND over 6 years ago
- Related to deleted (Bug #7758: When several directives value have a CFEngine var, we get "unexpected" due to bad regex matching)
Updated by Alexis Mousset about 6 years ago
- Status changed from Rejected to New
- Target version changed from 4.3.2 to 4.3.6
- Priority changed from 70 to 65
Reopening, it has been seen again
Updated by Alexis Mousset about 6 years ago
- Related to Bug #12235: Inventory failed on debian 9 on relay only added
Updated by Vincent MEMBRÉ about 6 years ago
- Target version changed from 4.3.6 to 4.3.7
- Priority changed from 65 to 64
Updated by François ARMAND about 6 years ago
- Effort required set to Very Small
- Priority changed from 64 to 91
Updated by Nicolas CHARLES about 6 years ago
I got it when upgrading from 4.1 to 5.0 on Debian9.1
Updated by François ARMAND about 6 years ago
- Translation missing: en.field_tag_list set to Sponsored, community
- Priority changed from 91 to 0
Updated by François ARMAND about 6 years ago
- User visibility changed from Getting started - demo | first install | level 1 Techniques to Getting started - demo | first install | Technique editor and level 1 Techniques
- Priority changed from 0 to 121
Updated by Nicolas CHARLES about 6 years ago
- Description updated (diff)
- Priority changed from 121 to 120
Updated by Vincent MEMBRÉ about 6 years ago
- Status changed from New to In progress
- Assignee changed from Benoît PECCATTE to Vincent MEMBRÉ
Updated by Vincent MEMBRÉ about 6 years ago
- Status changed from In progress to Pending technical review
- Assignee changed from Vincent MEMBRÉ to Alexis Mousset
- Pull Request set to https://github.com/Normation/rudder-packages/pull/1732
Updated by Vincent MEMBRÉ about 6 years ago
- Status changed from Pending technical review to Pending release
Applied in changeset rudder-packages|d86e75d7cb1d0392c7bf811e1f0672b912c153a3.
Updated by Vincent MEMBRÉ almost 6 years ago
- Status changed from Pending release to Released
Updated by François ARMAND almost 6 years ago
- Description updated (diff)
- Priority changed from 119 to 115
Updated by Florian Heigl over 4 years ago
- Priority changed from 115 to 109
Morning.
same on 5.0 in buster:
Updated the agent from an old 4.1 using:
curl https://repository.rudder.io/tools/rudder-setup | bash -s setup-agent 5.0 192.168.10.210
There was a few hickups but none related to this.
@root@sshsvc:~# rudder agent inventory
Rudder agent 5.0.17-debian10
Node uuid: a6a16d3b-b87b-4346-82a0-ec5a48477eae
rudder agent updaStart execution with config [20180420-000021-a0c8b742]
M| State Technique Component Key Message
E| error Inventory inventory Generated inventory has been detected as invalid
info Rudder agent was run on a subset of policies - not all policies were checked
- Summary #####################################################################
1 components verified in 3 directives
=> 1 components in Enforce mode
-> 1 error
Execution time: 5.78s ################################################################################
root@sshsvc:~# rudder agent inventory -i
Rudder agent 5.0.17-debian10
Node uuid: a6a16d3b-b87b-4346-82a0-ec5a48477eae
Can't locate XML/TreePP.pm in @INC (you may need to install the XML::TreePP module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.28.1 /usr/local/share/perl/5.28.1 /usr/lib/x86_64-linux-gnu/perl5/5.28 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.28 /usr/share/perl/5.28 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl line 5.
BEGIN failed--compilation aborted at /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl line 5.
rudder info: Using command line specified bundlesequence
rudder info: Executing 'no timeout' ... '/usr/bin/curl -L -k -1 -s -f --proxy '' -o "/var/rudder/cfengine-community/rudder-server-uuid.txt" https://192.168.10.210/uuid'
rudder info: Completed execution of '/usr/bin/curl -L -k -1 -s -f --proxy '' -o "/var/rudder/cfengine-community/rudder-server-uuid.txt" https://192.168.10.210/uuid'
rudder info: Executing 'no timeout' ... '/opt/rudder/bin/run-inventory --local=/var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs'
notice: Q: "...-inventory --lo": [info] FusionInventory instance: builtin - Perl instance: system
Q: "...-inventory --lo": File::Glob::glob() will disappear in perl 5.30. Use File::Glob::bsd_glob() instead. at /opt/rudder/share/fusioninventory/lib/FusionInventory/Agent.pm line 512.
Q: "...-inventory --lo": [info] running task Inventory
Q: "...-inventory --lo": [info] Inventory saved in /var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs
rudder info: Last 4 quoted lines were generated by promiser '/opt/rudder/bin/run-inventory --local=/var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs'
rudder info: Completed execution of '/opt/rudder/bin/run-inventory --local=/var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs'
Start execution with config [20180420-000021-a0c8b742]
M| State Technique Component Key Message
info Inventory inventory Running inventory
info Inventory inventory Curl installed
rudder info: Executing 'no timeout' ... '/var/rudder/tools/cpuid-linux-V1.0.sh > /var/rudder/tmp/cpuid.arc'
rudder info: Completed execution of '/var/rudder/tools/cpuid-linux-V1.0.sh > /var/rudder/tmp/cpuid.arc'
info Inventory inventory Generated the CPUID
info Inventory inventory User list generation tool is not present yet. Skipping...
rudder info: Edit file '/var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs'
rudder info: Edit file '/var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs'
E| error Inventory inventory Generated inventory has been detected as invalid
R: ************************************************************************
- WARNING Generated inventory is not valid, as it is missing mandatory fields. *
- Not sending it to the Rudder Server *
- You can get a full error message by running: /usr/bin/perl /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl /var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs
************************************************************************
info Rudder agent was run on a subset of policies - not all policies were checked
- Summary #####################################################################
1 components verified in 3 directives
=> 1 components in Enforce mode
-> 1 error
Execution time: 3.78s ################################################################################
root@sshsvc:~# /usr/bin/perl /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl /var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs
Can't locate XML/TreePP.pm in @INC (you may need to install the XML::TreePP module) (@INC contains: /etc/perl /usr/local/lib/x86_64-linux-gnu/perl/5.28.1 /usr/local/share/perl/5.28.1 /usr/lib/x86_64-linux-gnu/perl5/5.28 /usr/share/perl5 /usr/lib/x86_64-linux-gnu/perl/5.28 /usr/share/perl/5.28 /usr/local/lib/site_perl /usr/lib/x86_64-linux-gnu/perl-base) at /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl line 5.
BEGIN failed--compilation aborted at /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl line 5.
root@sshsvc:~# apt search xml-tree
Sorting... Done
Full Text Search... Done
libxml-treebuilder-perl/stable 5.4-2 all
XML parser providing XML::Elements DOM similar to HTML::Element
libxml-treepp-perl/stable 0.43-1 all
Pure Perl module for parsing/writing XML files
libxml-treepuller-perl/stable 0.1.2-1 all
pull interface to work with XML document fragments
root@sshsvc:~# apt install libxml-treepp-perl
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages were automatically installed and are no longer required:
gnupg-agent libbind9-140 libblas-common libboost-filesystem1.62.0 libboost-iostreams1.62.0 libboost-system1.62.0 libdns-export162 libdns162 libgfortran3 libgmime-2.6-0 libisc-export160
libisc160 libisccc140 libisccfg140 liblvm2app2.2 liblvm2cmd2.02 liblwres141 libnotmuch4 libperl5.24 libprocps6 libpython3.5-minimal libpython3.5-stdlib libruby2.3 libssl1.0.2 libtalloc2
libunistring0 linux-image-3.16.0-10-amd64 linux-image-4.9.0-11-amd64 python-httplib2 python-jinja2 python-kerberos python-markupsafe python-netaddr python-selinux python-xmltodict python3.5
python3.5-minimal rename rsync ruby2.3
Use 'apt autoremove' to remove them.
The following NEW packages will be installed:
libxml-treepp-perl
0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded.
Need to get 21.7 kB of archives.
After this operation, 65.5 kB of additional disk space will be used.
Get:1 http://cdn-fastly.deb.debian.org/debian buster/main amd64 libxml-treepp-perl all 0.43-1 [21.7 kB]
Fetched 21.7 kB in 0s (63.3 kB/s)
Selecting previously unselected package libxml-treepp-perl.
(Reading database ... 85779 files and directories currently installed.)
Preparing to unpack .../libxml-treepp-perl_0.43-1_all.deb ...
Unpacking libxml-treepp-perl (0.43-1) ...
Setting up libxml-treepp-perl (0.43-1) ...
Processing triggers for man-db (2.8.5-2) ...
root@sshsvc:~# rudder agent info
Hostname: sshsvc.intern.blutmeer.de
UUID: a6a16d3b-b87b-4346-82a0-ec5a48477eae
Key Hash: f394f4eb94584b027344e2e239300ae164878988
Policy server: 192.168.10.210
Roles: rudder-agent
Report mode: full-compliance
Run interval: 5 min
Agent is enabled
Configuration id: 20180420-000021-a0c8b742
Policy updated: 2019-08-24 00:11:21
Inventory sent: 2019-08-23 23:17:19
Version: Rudder agent 5.0.17-debian10
root@sshsvc:~# /usr/bin/perl /var/rudder/cfengine-community/inputs/inventory/1.0/test-inventory.pl /var/rudder/tmp/inventory/sshsvc-a6a16d3b-b87b-4346-82a0-ec5a48477eae.ocs @
As you can see I needed to manually install the package to generate a valid inventory on most recent 5.x.
Seems the xml-tree-pp thing is not in the dependencies always.
Greetings,
Flo
Updated by Nicolas CHARLES over 4 years ago
- Related to Bug #18132: Agent 5.0 on Debian Buster needs xml-tree-pp added