iso9660 not supported on 4k devices for config drives
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Ironic |
Fix Released
|
Undecided
|
Unassigned |
Bug Description
A downstream reporter has attempted to use ironic to deploy a running OS with shiny new 4k IO devices.
The deployment of the OS image works just fine. The issue is the creation and write-out of the configuration drive.
Specifically, when they attempt to boot a machine, they get the following kernel error log attempting to access the iso9660 filesystem from a 4k device.
[ 82.511907] isofs_fill_super: bread failed, dev=sda2, iso_blknum=17, block=-2147483648
cloud-init, when it is running logs the following:
2023-07-11 05:42:14,601 - subp.py[DEBUG]: Running command ['mount', '-o', 'ro', '-t', 'auto', '/dev/sda2', '/run/cloud-
2023-07-11 05:42:14,621 - util.py[DEBUG]: Failed mount of '/dev/sda2' as 'auto': Unexpected error while running command.
Command: ['mount', '-o', 'ro', '-t', 'auto', '/dev/sda2', '/run/cloud-
Exit code: 32
Reason: -
Stdout:
Stderr: mount: /run/cloud-
2023-07-11 05:42:14,621 - __init__.py[DEBUG]: Datasource DataSourceConfi
2023-07-11 05:42:14,622 - handlers.py[DEBUG]: finish: init-local/
Examining the cloud-init source code[0], it appears the rules constraint has been:
* an iso9660 or vfat filesystem
OR
* A file system with a config-2/CONFIG-2 label.
That basic logic[0] has been present since 2014.
The original strict constraint seems largely rooted in nova, which also appears like it had deprecated the vfat option. And, it is sort of a reasonable constraint in the virtualized context.
So I think the option forward is to update ironic-python-agent to handle this gracefully.
Two options:
1) Attempt to remount the device, and if fails, reformat, extract, and copy the config content to the new filesystem. This can inherently help create a security issue, so we might need to make the filesystem configurable.
2) Identify the device is a 4k IO device (how?!?) and then base the steps on that.
One issue to consider is if someone starts adding a lot of content into their configuration drive, since a larger block size could mean many smaller files won't be able to fit in the same space potentially. But... that shouldn't be an issue for the 99% of operators out there using configuration drives, and those doing embedded contents can likely just easily ship a different filesystem anyhow.
Changed in ironic: | |
status: | New → In Progress |
Originally reported in https:/ /bugzilla. redhat. com/show_ bug.cgi? id=2222981.