cloudinit can`t mount configdrive partition

Bug #1712851 reported by fxpester
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
cloud-init
New
Undecided
Unassigned
ironic-python-agent
Incomplete
Undecided
Unassigned

Bug Description

image for Ironic builded that way:
DIB_CLOUD_INIT_DATASOURCES="Ec2, ConfigDrive, OpenStack" disk-image-create -o baremetal-$DISTRO_NAME-$DIB_RELEASE $DISTRO_NAME baremetal bootloader -p linux-image-generic-lts-xenial

config-drive partition is created by default ironic coreos images:
root@ubuntu:~# lsblk -f
NAME FSTYPE LABEL MOUNTPOINT
sda ext4 cloudimg-rootfs
└─sda1 iso9660 config-2

cloudinit.log:
2017-08-24 18:48:50,130 - util.py[DEBUG]: Running command ['mount', '-o', 'ro,sync', '/dev/sda1', '/tmp/tmpN_ixJ1'] with allowed return codes [0] (shell=False, capture=True)
2017-08-24 18:48:50,203 - util.py[DEBUG]: Recursively deleting /tmp/tmpN_ixJ1
2017-08-24 18:48:50,203 - cloud-init[DEBUG]: No local datasource found

I try command by hand:
root@ubuntu:~# mount -o ro,sync /dev/sda1 /mnt
mount: /dev/sda1 already mounted or /mnt busy

I modify command by hand:
root@ubuntu:~# mount -o loop,ro,sync /dev/sda1 /mnt ### mount successful

Revision history for this message
Scott Moser (smoser) wrote :

can you please attach
a.) /var/log/cloud-init.log
b.) a dd of the /dev/sda1 partition, or at very least:
  - blkid output
  - mount /dev/sda1 /mnt && tar -C /mnt -czf contents.tar.gz .

Revision history for this message
fxpester (a-yurtaykin) wrote :

/var/log/cloud-init.log - https://pastebin.com/wbW0VbNf

root@ubuntu:~# blkid
/dev/sda1: LABEL="config-2" TYPE="iso9660"

Revision history for this message
fxpester (a-yurtaykin) wrote :

passwords redacted contents.tar.gz - https://yadi.sk/d/-0IWWRF53MKMCR

Revision history for this message
fxpester (a-yurtaykin) wrote :

workaround: edit cloud-init`s util.py inside image, add `loop` to mount options.

Revision history for this message
Julia Kreger (juliaashleykreger) wrote :

This doesn't seem like an IPA issue. Perhaps ironic-lib. Could you provide detail into the settings used for the deployment. i.e. driver, instance_info, etc?

Also, if you use the vm element, does that change the results?

Changed in ironic-python-agent:
status: New → Incomplete
Revision history for this message
Scott Moser (smoser) wrote :

Hi,
I'm pretty sure this is a duplicate of bug 1707222.

A fix for that issue should land in 16.04 and 17.04 shortly via the SRU bug 1721808.

I'm going to mark this a duplicate of 1707222. If you find out otherwise, please explain and re-set the bug to "New".

Thanks!.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.