Job release upgrade will trigger recreate vm after bosh upgrade
After upgrading the bosh from version 1.3153.0 to 1.3262.3.0, we try to upgrade cf release version for the deployment. This triggers recreate (delete and create) vm which is not expected.
In the bosh task debug log, it detected networks changed so recreate vm was triggered.
D, [2016-07-20 03:53:48 #26642] [canary_update(ipsec-orchestrator/0 (38b37b1d-a028-4aad-9e54-fc09e9837a92))] DEBUG -- DirectorJobRunner: networks_changed? network settings changed FROM: {"default"=>{"type"=>"dynamic", "cloud_properties"=>{"security_groups"=>["default", "cf"]}, "dns"=>["159.8.180.206", "10.0.80.11", "10.0.80.12"], "default"=>["dns", "gateway"], "dns_record_name"=>"0.ipsec-orchestrator.default.gubin-preyf.microbosh", "ip"=>"169.50.71.93", "netmask"=>"255.255.255.224", "gateway"=>"169.50.71.65"}} TO: {"default"=>{"type"=>"dynamic", "cloud_properties"=>{"security_groups"=>["default", "cf"]}, "dns"=>["159.8.180.206", "10.0.80.11", "10.0.80.12"], "default"=>["dns", "gateway"], "ip"=>"169.50.71.93", "netmask"=>"255.255.255.224", "gateway"=>"169.50.71.65"}} on instance ipsec-orchestrator/0 (38b37b1d-a028-4aad-9e54-fc09e9837a92)
D, [2016-07-20 03:53:48 #26642] [task:207] DEBUG -- DirectorJobRunner: Waiting for tasks to complete
D, [2016-07-20 03:53:48 #26642] [canary_update(ipsec-orchestrator/0 (38b37b1d-a028-4aad-9e54-fc09e9837a92))] DEBUG -- DirectorJobRunner: Networks have changed. Recreating VM
So "dns_record_name"=>"0.ipsec-orchestrator.default.gubin-preyf.microbosh" is removed in the new bosh.
Is there any way to avoid recreate vm in this case? Thanks.
/cc @maximilien @jianqiu @mattcui
@gu-bin yeah we removed 'dns_record_name' since it's not supposed to be sent to the agent. not sure how to avoid it. i think we would be open to the pr to ignore that key in networks_changed? method.
@gu-bin if you and @mattcui work on a PR, please pass it by me and I can review. Update me tonight when we talk. Thx.
Looks like the PR for this issue was merged - I'm going to close the corresponding issue