Project

General

Profile

Actions

Bug #7794

closed

rudder-upgrade edits the wrong ncf.conf file causing transitory invalid promises during upgrades

Bug #7794: rudder-upgrade edits the wrong ncf.conf file causing transitory invalid promises during upgrades

Added by Nicolas CHARLES over 10 years ago. Updated over 10 years ago.

Status:
Released
Priority:
N/A
Category:
Packaging
Target version:
Severity:
UX impact:
User visibility:
Effort required:
Priority:
Name check:
Fix check:
Regression:

Description

I upgraded on Centos6 from Rudder 3.1.6 to 3.2, and when I run the agent on the server or the relay, I get the follwing error message:

R: @@server-roles@@result_success@@server-roles@@server-roles-directive@@6@@Check WebDAV credentials@@None@@2016-01-18 10:02:29+00:00##bf63c43b-10bd-4248-8adc-bc56aa3e023d@#The Rudder WebDAV user and password are OK
   error: While constructing scope '_logger_default'
Formal =  {'message','old_class_prefix'}, Actual =  {'Check if the service httpd is started using ps','service_check_running_httpd','','@{args}'}
   error: Fatal CFEngine error: Augment scope, formal and actual parameter mismatch is fatal

It lasts for about 5 minutes after promises regeneration, and then it works again fine


Subtasks 1 (0 open1 closed)

Bug #7809: rudder-upgrade edits the wrong ncf.conf file causing transitory invalid promises during upgrades (3.2 branch)RejectedVincent MEMBRÉActions

Related issues 4 (0 open4 closed)

Related to Rudder - Bug #5937: Enforce the content of the local ncf configuration file from techniquesReleasedJonathan CLARKEActions
Related to Rudder - Bug #7810: initial promises don't create /var/rudder/configuration-repository/ncf/ncf.conf ReleasedVincent MEMBRÉActions
Related to Rudder - Bug #9639: When running rudder-init on a fresh server, we get an error that "/var/rudder/ncf/local/ does not exist"RejectedActions
Related to Rudder - Bug #11128: error: Fatal CFEngine error: Augment scope, formal and actual parameter mismatch is fatalRejectedActions

Updated by Nicolas CHARLES over 10 years ago Actions #1

this is probably because ncf is updated, promises as well, but the ncf used (in /var/rudder/common/ncf) is still not updated

Updated by Vincent MEMBRÉ over 10 years ago Actions #2

I have a suggestion here ... maybe if ncf common (/var/ncf/common) was a symlink to /usr/share/ncf/tree it would be ok stright away, removing a need to copy these promises to /var/rudder/ncf/common

(that idea can also be extended to /var/rudder/ncf/local be a symlink to /var/rudder/conf-repo/ncf)

What do you think of these ??

Updated by Vincent MEMBRÉ over 10 years ago Actions #3

ncf common is updated, but it is still using the old logger (looking for 2 params: Formal = {'message','old_class_prefix'} and it received 4: {'Check if the service httpd is started using ps','service_check_running_httpd','','@{args}'} )

I guess /var/rudder/ncf/common is up to date, but ncf.conf (in /var/rudder/ncf/local is still using the old logger

Updated by Jonathan CLARKE over 10 years ago Actions #4

Exactly, Vincent, ncf.conf is not updated.

The problem comes from rudder-upgrade, that cleverly was configured to change the logger we used... but, not so cleverly, in the wrong config file:

sed -i "s%^loggers=\(.*\)logger_rudder\(.*\)$%loggers=\1log_rudder\2%" ${RUDDER_VAR}/ncf/common/ncf.conf

The config file in ncf/common is never read, so this doesn't do anything.

All file edits on ncf.conf are on the wrong file, and have been since 2.11.

Updated by Jonathan CLARKE over 10 years ago Actions #5

  • Target version changed from 3.2.0 to 2.11.18

Updated by Jonathan CLARKE over 10 years ago Actions #6

  • Subject changed from upgrade from 3.1.6 to 3.2 causes transitory invalid promises to rudder-upgrade edits the wrong ncf.conf file causing transitory invalid promises during upgrades

Updated by Jonathan CLARKE over 10 years ago Actions #7

  • Status changed from New to In progress
  • Assignee set to Jonathan CLARKE

Updated by Jonathan CLARKE over 10 years ago Actions #8

Also, the port number editing was overly naive:

sed -i "s%^cfengine_port=.*%cfengine_port=5309%" ${RUDDER_VAR}/ncf/common/ncf.conf

The problem being that ncf.conf now (as of #5937) contains two lines matching that, that should not both use port 5309:

# Which port should be for CFEngine connections/data transfers
{{#classes.community_edition}}
cfengine_port=5309
{{/classes.community_edition}}
{{#classes.enterprise_edition}}
cfengine_port=5308
{{/classes.enterprise_edition}}

Updated by Jonathan CLARKE over 10 years ago Actions #9

  • Related to Bug #5937: Enforce the content of the local ncf configuration file from techniques added

Updated by Jonathan CLARKE over 10 years ago Actions #10

  • Status changed from In progress to Pending technical review
  • Assignee changed from Jonathan CLARKE to Vincent MEMBRÉ
  • Pull Request set to https://github.com/Normation/rudder-packages/pull/870

Updated by Jonathan CLARKE over 10 years ago Actions #11

  • Related to Bug #7810: initial promises don't create /var/rudder/configuration-repository/ncf/ncf.conf added

Updated by Jonathan CLARKE over 10 years ago Actions #12

  • Status changed from Pending technical review to Pending release
  • % Done changed from 0 to 100

Updated by Vincent MEMBRÉ over 10 years ago Actions #13

  • Status changed from Pending release to Released

This bug has been fixed in Rudder 2.11.18, 3.0.13, 3.1.6 and 3.2.0 which were released today.

Updated by Nicolas CHARLES over 9 years ago Actions #14

  • Related to Bug #9639: When running rudder-init on a fresh server, we get an error that "/var/rudder/ncf/local/ does not exist" added

Updated by François ARMAND almost 9 years ago Actions #15

  • Related to Bug #11128: error: Fatal CFEngine error: Augment scope, formal and actual parameter mismatch is fatal added
Actions

Also available in: PDF Atom