Bug #12883
closedpolicy generation error "Conflicting arity in calling bundle log_rudder"
Description
Environment:
centOS 7.5
rudder server 4.3.2
Because of problems with reporting I upgraded from 4.1.12 to 4.3.2
I followed the upgrade instructions but now I get error:
Policy update error for process '3140' at 2018-07-04 12:16:50
⇨ Cannot write configuration node
⇨ Exit code=1 for hook: '/opt/rudder/etc/hooks.d/policy-generation-node-ready/10-cf-promise-check'. stdout: stderr: '/var/rudder/share/681525d5-2318-4e3f-9a66-d9bf64fca2ca/rules.new/cfengine-community/system_logrotate/1.1/rudder_reporting.cf:12:0: error: Conflicting arity in calling bundle log_rudder, expected 5 arguments, 4 given
Policy generation is not possible but problem should be fixed wuith this version
https://www.rudder-project.org/redmine/issues/12759
How can I fix this?
Updated by Alexis Mousset over 6 years ago
Could you check if the ncf-api-virtualenv package is in 4.3.2 too?
It may be https://www.rudder-project.org/redmine/issues/12634.
Could you send the output of "ls -l /usr/share/ncf/tools/*.pyc" to see if it really this one?
Then you can delete /usr/share/ncf/tools/*.pyc, restart the apache service and regenerat policies, it should fix this problem.
Updated by Tobias Ell over 6 years ago
Hello Alexis,
installed packages are
ncf-4.3.2.release-1.EL.7.noarch
ncf-api-virtualenv-4.3.2.release-1.EL.7.noarch
rudder-jetty-4.3.2.release-1.EL.7.noarch
rudder-server-relay-4.3.2.release-1.EL.7.x86_64
rudder-reports-4.3.2.release-1.EL.7.noarch
rudder-agent-4.3.2.release-1.EL.7.x86_64
rudder-server-root-4.3.2.release-1.EL.7.noarch
rudder-techniques-4.3.2.release-1.EL.7.noarch
rudder-inventory-ldap-4.3.2.release-1.EL.7.x86_64
rudder-webapp-4.3.2.release-1.EL.7.noarch
rudder-inventory-endpoint-4.3.2.release-1.EL.7.noarch
output of ls l /usr/share/ncf/tools/*.pyc is 2 root root 513 Jun 12 12:38 /usr/share/ncf/tools/get_promises.pyc
-rw-r--r-rw-r--r- 2 root root 4541 Jun 12 12:38 /usr/share/ncf/tools/ncf_constraints.pycrw-r--r- 2 root root 2411 Jun 12 12:38 /usr/share/ncf/tools/ncf_doc.pycrw-r--r- 2 root root 23471 Jun 12 12:38 /usr/share/ncf/tools/ncf.pycrw-r--r- 2 root root 9932 Jun 12 12:38 /usr/share/ncf/tools/ncf_rudder.pyc
shall I delete them?
Updated by Alexis Mousset over 6 years ago
- Category set to Packaging
- Target version set to 4.3.3
- User visibility set to Operational - other Techniques | Technique editor | Rudder settings
- Priority changed from 0 to 52
Yes, you should remove all .pyc files and restart the apache2 service. https://www.rudder-project.org/redmine/issues/12634 should have fixed this.
Updated by Alexis Mousset over 6 years ago
- Related to Bug #12634: .pyc file are not cleand up during postinst added
Updated by Tobias Ell over 6 years ago
Hello Alexis,
I am so sorry - while waiting for your answer I kept clicking around in the GUI and noticed several directives
with an orange arrow indicating deprecated versions. I migrated them and now policy generation works.
Maybe the upgrade documentation should include a hint to check for old directives.
Updated by Alexis Mousset over 6 years ago
Did you remove the .pyc files before it worked?
Updated by Tobias Ell over 6 years ago
Alexis,
I will remove the .pyc files as well - thanks
Updated by Tobias Ell over 6 years ago
No - it already worked before I removed the files.
I only migrated the deprecated directives which seems to have help.
Updated by Alexis Mousset over 6 years ago
Migrating the directives triggered a new policy generation, which probably worked then because post-install scripts and first agent run on the server had finished in the meantime.
Updated by Vincent MEMBRÉ about 6 years ago
- Target version changed from 4.3.3 to 4.3.4
Updated by Benoît PECCATTE about 6 years ago
- Target version changed from 4.3.4 to 4.3.5
Updated by François ARMAND about 6 years ago
- Status changed from New to Rejected
- Priority changed from 52 to 50
I propose to close that one since it seems to be non reproducible and (now) working.
Tobias, please reopened it if you encouter it again!