When installing the 'Neutron Networker' role on a system with multiple interfaces, it is likely that only the provisioning interface has an address assigned when the kickstart is running.
This means that Puppet manifests that rely on facts like "ipaddress_eth1" to determine the ip address of an interface will fail, leading to errors such as:
Could not retrieve catalog from remote server: Error 400 on SERVER: Local ip for ovs agent must be set when tunneling is enabled at /etc/puppet/environments/production/modules/neutron/manifests/agents/ovs.pp:32 on node mac52540036b16c.localdomain
This error *only* manifests during kickstart, because once the system boots for real all the interfaces are brought up and the appropriate facts are available.
Unfortunately, the error that crops during kickstart causes the deployment to fail. So there are two problems here:
- Should we bring up interfaces before running puppet? Or should we simply not run puppet in the kickstart?
- Should errors cause the deployment to *stop*, or should the deployment remain active and waiting for a successful puppet run? In which case, the puppet run after the system boots should correct the error and allow the deploy to continue.
I have confirmed that during the kickstart install, only the provisioning interface has an address.
pchalupa proposed the following patch:
diff --git a/app/lib/actions/staypuft/host/wait_until_host_ready.rb b/app/lib/actions/staypuft/host/wait_until_host_ready.rb
index 5fb3b86..8d755fb 100644
-59,7 +59,7 @@ module Actions
host = ::Host.find(host_id)
- host.reports.order('reported_at DESC').any? do |report|
+ host.reports.order('reported_at DESC')[0..-2].any? do |report|
This causes the workflow engine to ignore the first report from Puppet, so errors encountered during Kickstart are ignored. I have tried this in my test environments and it appears to work as advertised.
fixed in https://github.com/theforeman/staypuft/pull/242
Works properly in ruby193-rubygem-staypuft-0.1.22.el6ost
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory, and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.