ironic-python-agent silently fails to write a configdrive if a previous drive is found
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ironic |
Fix Released
|
High
|
Ramakrishnan G (rameshg87) |
Bug Description
When utilizing a standalone ironic install ( via bifrost https:/
This is on ironic master branch as of yesterday afternoon and IPA's master branch as of today. My understanding is cleaning will largely resolve this issue in the case of redeployments, although a node that is added to ironic with a pre-existing configdrive from a previous deployment will fail in this same manor.
Investigation has revealed two things are occurring:
1) CoreOS is auto-mounting the pre-existing configuration drive which prevents the kernel view of the disk devices from being updating after a disk image has been written out, resulting in deployment writing out to an _existing_ configdrive partition that is not in the partition table on disk. Upon reboot, only the original partition from the disk image is present. This can be bypassed by setting the kernel parameter "coreos.
2) The execution of partx in ironic_
Setting coreos.
+------
| Property | Value |
+------
| instance_uuid | None |
| target_power_state | None |
| properties | {u'memory_mb': u'512', u'cpu_arch': u'x86_64', u'local_gb': u'10', |
| | u'cpus': u'1'} |
| maintenance | False |
| driver_info | {u'ssh_port': 22, u'ssh_username': u'ironic', u'deploy_kernel': |
| | u'http://
| | u'deploy_ramdisk': u'http://
| | /coreos_
| | u'/home/
| | u'ssh_virt_type': u'virsh'} |
| extra | {} |
| last_error | None |
| created_at | 2015-03-
| target_
| driver | agent_ssh |
| updated_at | 2015-03-
| maintenance_reason | None |
| instance_info | {u'root_gb': 10, u'image_source': |
| | u'http://
| | u'684649dec72ec
| | u'http://
| | u'image_
| | u'http://
| | 046ebb96ec01.
| driver_
| chassis_uuid | |
| provision_state | deploying |
| reservation | None |
| power_state | power on |
| console_enabled | False |
| uuid | a8cb6624-
+------
Changed in ironic: | |
importance: | Undecided → High |
Changed in ironic: | |
assignee: | Jay Faulkner (jason-oldos) → Lucas Alvares Gomes (lucasagomes) |
Changed in ironic: | |
assignee: | Lucas Alvares Gomes (lucasagomes) → Jay Faulkner (jason-oldos) |
Changed in ironic: | |
assignee: | Jay Faulkner (jason-oldos) → Ramakrishnan G (rameshg87) |
Changed in ironic: | |
status: | In Progress → Fix Committed |
Changed in ironic: | |
milestone: | none → 4.1.0 |
status: | Fix Committed → Fix Released |
After a conversation with Alex Crawford from CoreOS, it sounds like this *is* a race. The ConfigDrive is mounted before oem/cloud- config. yml is processed.
A short-term fix will be to modify the coreos- oem-inject. py script to exclude the mount units causing the problem. CoreOS upstream is working on a longer term fix.