Project

General

Profile

Bug #10493

Updated by François ARMAND over 7 years ago

After running rudder-init, I got a policy error generation on debian 7 
 <pre> 
  Policy update error for process '2' at 2017-03-23 12:14:03 
 ⇨ Exit code=1 for hook: '/opt/rudder/etc/hooks.d/policy-generation-finished/50-reload-policy-file-server' with environment variables: [PATH:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/var/cfengine/bin:/opt/rudder/bin] [NLSPATH:/usr/dt/lib/nls/msg/%L/%N.cat] [OLDPWD:/opt/rudder/jetty7] [TERM:xterm] [XFILESEARCHPATH:/usr/dt/app-defaults/%L/Dt] [PWD:/opt/rudder/jetty7] [SHLVL:2] [_:/sbin/start-stop-daemon] [RUDDER_GENERATION_DATETIME:2017-03-23T12:14:02.985Z] [RUDDER_END_GENERATION_DATETIME:2017-03-23T12:14:03.238Z] [RUDDER_NODEIDS:] [RUDDER_NUMBER_NODES_UPDATED:0] [RUDDER_ROOT_POLICY_SERVER_UPDATED:1]. Stdout: '/usr/bin/killall ' Stderr: 'cf-serverd: no process found ' 
 </pre> 

 Cause is: cf-serverd was not running right at this moment 

 /opt/rudder/bin/rudder-reload-cf-serverd should not fail if cf-serverd is not running (and should not ouput /usr/bin/killall ), and should start cf-serverd if it couldn't send signal -1 


 EDIT: on SLES12, the message is a little different: 

 <pre> 
 [2017-03-29 12:53:24] ERROR com.normation.rudder.batch.AsyncDeploymentAgent - Policy update error for process '2' at 2017-03-29 12:53:24: Exit code=1 for hook: '/opt/rudder/etc/hooks.d/policy-generation-finished/50-reload-policy-file-server' with environment variables: [PATH:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin] [NLSPATH:/usr/dt/lib/nls/msg/%L/%N.cat] [OLDPWD:/] [XFILESEARCHPATH:/usr/dt/app-defaults/%L/Dt] [PWD:/opt/rudder/jetty7] [SHLVL:1] [_:/usr/bin/java] [XDG_SESSION_CLASS:service] [RUDDER_GENERATION_DATETIME:2017-03-29T12:53:23.851Z] [RUDDER_END_GENERATION_DATETIME:2017-03-29T12:53:24.200Z] [RUDDER_NODEIDS:] [RUDDER_NUMBER_NODES_UPDATED:0] [RUDDER_ROOT_POLICY_SERVER_UPDATED:1]. 
   Stdout: '' 
   Stderr: 'which: no killall in (/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin) 
 kill: usage: kill [-s sigspec | -n signum | -sigspec] pid | jobspec ... or kill -l [sigspec] 
 ' 
 </pre> 

 But it is also due to the fact that "/opt/rudder/bin/rudder-reload-cf-serverd" failed because cf-serverd was not up at the moment.

Back