Project

General

Profile

Bug #12661

Updated by François ARMAND almost 6 years ago

The migration script seems to modify rudder-web.properties after Rudder reboot. So Rudder doesn't find the new `rudder.batch.reportscleaner.compliancelevels.delete.TTL` property and fails to boot with exception:  

 <pre> 
 [2018-05-19 11:45:59] ERROR application - Fatal error during boot, Rudder will stop now 
 java.lang.ExceptionInInitializerError: null 
 >-at bootstrap.liftweb.LiftInitContextListener.contextInitialized(LiftInitContextListener.scala:109) 
 >-at org.eclipse.jetty.server.handler.ContextHandler.startContext(ContextHandler.java:746) 
 >-at org.eclipse.jetty.servlet.ServletContextHandler.startContext(ServletContextHandler.java:238) 
 ... 
 Caused by: com.typesafe.config.ConfigException$Missing: No configuration setting found for key 'rudder.batch.reportscleaner.compliancelevels' 
 >-at com.typesafe.config.impl.SimpleConfig.findKeyOrNull(SimpleConfig.java:152) 
 </pre> 

 Upgrade log is:  

 <pre> 
 Setting up rudder-jetty (4.1.12-xenial0) ... 
 Setting up ncf (4.1.12-xenial0) ... 
 Setting up rudder-techniques (4.1.12-xenial0) ... 
 Setting up rudder-agent (4.1.12-xenial0) ... 
 ok: Rudder agent is now disabled. 
 ok: stop service rudder-agent succeeded 
 INFO: Ensuring correct permissions on the keys directory... Done. 
 ok: Rudder agent has been enabled but not started, wait for next cron run. 
 ok: start service rudder-agent succeeded 
 INFO: Scheduling an inventory during next run... 
 Setting up rudder-server-relay (4.1.12-xenial0) ... 
 INFO: Restarting Apache HTTPd... Done 
 INFO: rudder-server-relay setup complete. 
 Setting up ncf-api-virtualenv (4.1.12-xenial0) ... 
 Conf ncf-api-virtualenv already enabled 
 INFO: Restarting Apache HTTPd... Done 
 Setting up rudder-webapp (4.1.12-xenial0) ... 

 Configuration file '/opt/rudder/etc/rudder-web.properties' 
  ==> Modified (by you or by a script) since installation. 
  ==> Package distributor has shipped an updated version. 
    What would you like to do about it ?    Your options are: 
     Y or I    : install the package maintainer's version 
     N or O    : keep your currently-installed version 
       D       : show the differences between the versions 
       Z       : start a shell to examine the situation 
  The default action is to keep your current version. 
 *** rudder-web.properties (Y/I/N/O/D/Z) [default=N] ? 
 INFO: Restarting syslog...Done 
 INFO: Restarting Apache HTTPd... Done 
 INFO: Launching script to check if a migration is needed 
 INFO: Checking if rudder-web.properties database access credentials are all right... LDAP OK,    SQL OK 
 INFO: Checking if inventory-web.properties database access credentials are all right... LDAP OK,    SQL skipped 
 INFO: A Technique library reload is needed and has been scheduled. 
 INFO: The /var/rudder/configuration-repository/techniques/ncf_techniques/category.xml file already exists. Not updating. 
 INFO: Alternative source path added: /var/rudder/configuration-repository/ncf 
 INFO: New configuration property rudder.batch.reportscleaner.compliancelevels.delete.TTL added to /opt/rudder/etc/rudder-web.properties 
 INFO: Checking PostgreSQL service status... OK 
 INFO: Adding new 'compliance levels' table Done 
 INFO: Checking LDAP service status... OK 

 INFO: The migration has completed successfully. 
 INFO: End of migration script 
 [master 80ed429] Add ncf hooks to repository 
 INFO: Restarting Rudder webapp and inventory-endpoint... Done 
 Setting up rudder-inventory-ldap (4.1.12-xenial0) ... 
 INFO: Restarting syslogd... Done 
 INFO: Restarting rudder-slapd... Done 
 Setting up rudder-inventory-endpoint (4.1.12-xenial0) ... 
 INFO: Launching script to check if a migration is needed 
 INFO: End of migration script 
 Setting up rudder-reports (4.1.12-xenial0) ... 
 INFO: Waiting for PostgreSQL to be up... Done 
 Setting up rudder-server-root (4.1.12-xenial0) ... 
 Processing triggers for libc-bin (2.23-0ubuntu10) ... 
 root@server:/var/rudder/share# vi /opt/rudder/etc/rudder-web.properties 
 </pre> 

Back