RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 2210916 - [RHEL9] Failed to commit changes to disk: Failed to format device: Input/output error
Summary: [RHEL9] Failed to commit changes to disk: Failed to format device: Input/out...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 9
Classification: Red Hat
Component: rhel-system-roles
Version: 9.3
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: 9.3
Assignee: Rich Megginson
QA Contact: guazhang@redhat.com
URL:
Whiteboard: role:storage
Depends On:
Blocks: 2211247
TreeView+ depends on / blocked
 
Reported: 2023-05-30 03:43 UTC by guazhang@redhat.com
Modified: 2023-11-07 09:32 UTC (History)
2 users (show)

Fixed In Version: rhel-system-roles-1.22.0-0.9.el9
Doc Type: No Doc Update
Doc Text:
Clone Of:
: 2211247 (view as bug list)
Environment:
Last Closed: 2023-11-07 08:29:47 UTC
Type: Bug
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Github linux-system-roles storage pull 358 0 None Merged fix: add back systemd refresh after remove obsolete mounts 2023-05-30 14:59:41 UTC
Github linux-system-roles storage pull 361 0 None open test: enable FIPS testing; configurable LUKS cipher 2023-06-01 01:38:23 UTC
Red Hat Issue Tracker RHELPLAN-158481 0 None None None 2023-05-30 03:43:28 UTC
Red Hat Product Errata RHEA-2023:6390 0 None None None 2023-11-07 08:30:09 UTC

Description guazhang@redhat.com 2023-05-30 03:43:03 UTC
Description of problem:
storage role testing found the error, please have a look

Version-Release number of selected component (if applicable):
ansible-core-2.15.0-1.el9.x86_64 
rhel-system-roles-1.22.0-0.6.el9.noarch
python3-blivet-1:3.6.0-5.el9.noarch

How reproducible:


Steps to Reproduce:
1. enable fips
2. ansible-playbook -vv -i host tests_luks.yml
3.

Actual results:


Expected results:


Additional info:

ok: [localhost] => {
    "storage_pools": [
        {
            "disks": [
                "sdb"
            ],
            "encryption": true,
            "encryption_cipher": "serpent-xts-plain64",
            "encryption_key_size": 512,
            "encryption_luks_version": "luks1",
            "encryption_password": "yabbadabbadoo",
            "name": "foo",
            "type": "lvm",
            "volumes": [
                {
                    "mount_point": "/opt/test1",
                    "name": "test1",
                    "size": "4g"
                }
            ]
        }
    ]
}


TASK [rhel-system-roles.storage : Failed message] ******************************
task path: /usr/share/ansible/roles/rhel-system-roles.storage/tasks/main-blivet.yml:95
fatal: [localhost]: FAILED! => {"changed": false, "msg": {"actions": [], "changed": false, "crypts": [], "failed": true, "invocation": {"module_args": {"disklabel_type": null, "diskvolume_mkfs_option_map": {}, "packages_only": false, "pool_defaults": {"disks": [], "encryption": false, "encryption_cipher": null, "encryption_key": null, "encryption_key_size": null, "encryption_luks_version": null, "encryption_password": null, "raid_chunk_size": null, "raid_device_count": null, "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "state": "present", "type": "lvm", "volumes": []}, "pools": [{"disks": ["sdb"], "encryption": true, "encryption_cipher": "serpent-xts-plain64", "encryption_key": null, "encryption_key_size": 512, "encryption_luks_version": "luks1", "encryption_password": "yabbadabbadoo", "name": "foo", "raid_chunk_size": null, "raid_device_count": null, "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "state": "present", "type": "lvm", "volumes": [{"_device": "/dev/mapper/foo-test1", "_mount_id": "/dev/mapper/foo-test1", "_raw_device": "/dev/mapper/foo-test1", "cache_devices": [], "cache_mode": null, "cache_size": 0, "cached": false, "compression": null, "deduplication": null, "disks": [], "encryption": false, "encryption_cipher": null, "encryption_key": null, "encryption_key_size": null, "encryption_luks_version": null, "encryption_password": null, "fs_create_options": "", "fs_label": "", "fs_overwrite_existing": true, "fs_type": "xfs", "mount_check": 0, "mount_device_identifier": "uuid", "mount_options": "defaults", "mount_passno": 0, "mount_point": "/opt/test1", "name": "test1", "raid_chunk_size": null, "raid_device_count": null, "raid_disks": [], "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "size": "4g", "state": "present", "thin": false, "thin_pool_name": null, "thin_pool_size": null, "type": "lvm", "vdo_pool_size": null}]}], "safe_mode": false, "use_partitions": null, "volume_defaults": {"cache_devices": [], "cache_mode": null, "cache_size": 0, "cached": false, "compression": null, "deduplication": null, "disks": [], "encryption": false, "encryption_cipher": null, "encryption_key": null, "encryption_key_size": null, "encryption_luks_version": null, "encryption_password": null, "fs_create_options": "", "fs_label": "", "fs_overwrite_existing": true, "fs_type": "xfs", "mount_check": 0, "mount_device_identifier": "uuid", "mount_options": "defaults", "mount_passno": 0, "mount_point": "", "raid_chunk_size": null, "raid_device_count": null, "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "size": 0, "state": "present", "thin": null, "thin_pool_name": null, "thin_pool_size": null, "type": "lvm", "vdo_pool_size": null}, "volumes": []}}, "leaves": [], "mounts": [], "msg": "Failed to commit changes to disk: Failed to format device: Input/output error", "packages": ["cryptsetup", "lvm2", "xfsprogs"], "pools": [], "volumes": []}}

TASK [rhel-system-roles.storage : Unmask the systemd cryptsetup services] ******
task path: /usr/share/ansible/roles/rhel-system-roles.storage/tasks/main-blivet.yml:99
skipping: [localhost] => {"changed": false, "skipped_reason": "No items in the list"}

PLAY RECAP *********************************************************************
localhost                  : ok=290  changed=9    unreachable=0    failed=1    skipped=205  rescued=7    ignored=0   
STDERR:
RETURN:2


https://beaker.engineering.redhat.com/recipes/13967235#task160735701

reproduce with rhel9.2
https://beaker.engineering.redhat.com/recipes/13967195#task160734998

Comment 5 guazhang@redhat.com 2023-05-31 03:50:43 UTC
still hit the bug with rhel-system-roles-1.22.0-0.8.el9.noarch 

https://beaker.engineering.redhat.com/recipes/14000454#task161033679



TASK [rhel-system-roles.storage : Failed message] ******************************
task path: /usr/share/ansible/roles/rhel-system-roles.storage/tasks/main-blivet.yml:95
fatal: [localhost]: FAILED! => {"changed": false, "msg": {"actions": [], "changed": false, "crypts": [], "failed": true, "invocation": {"module_args": {"disklabel_type": null, "diskvolume_mkfs_option_map": {}, "packages_only": false, "pool_defaults": {"disks": [], "encryption": false, "encryption_cipher": null, "encryption_key": null, "encryption_key_size": null, "encryption_luks_version": null, "encryption_password": null, "raid_chunk_size": null, "raid_device_count": null, "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "state": "present", "type": "lvm", "volumes": []}, "pools": [{"disks": ["sda"], "encryption": false, "encryption_cipher": null, "encryption_key": null, "encryption_key_size": null, "encryption_luks_version": null, "encryption_password": null, "name": "foo", "raid_chunk_size": null, "raid_device_count": null, "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "state": "present", "type": "lvm", "volumes": [{"_device": "/dev/mapper/luks-test1", "_mount_id": "/dev/mapper/luks-test1", "_raw_device": "/dev/mapper/foo-test1", "cache_devices": [], "cache_mode": null, "cache_size": 0, "cached": false, "compression": null, "deduplication": null, "disks": [], "encryption": true, "encryption_cipher": "serpent-xts-plain64", "encryption_key": null, "encryption_key_size": 512, "encryption_luks_version": "luks1", "encryption_password": "yabbadabbadoo", "fs_create_options": "", "fs_label": "", "fs_overwrite_existing": true, "fs_type": "xfs", "mount_check": 0, "mount_device_identifier": "uuid", "mount_group": null, "mount_mode": null, "mount_options": "defaults", "mount_passno": 0, "mount_point": "/opt/test1", "mount_user": null, "name": "test1", "raid_chunk_size": null, "raid_device_count": null, "raid_disks": [], "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "size": "4g", "state": "present", "thin": false, "thin_pool_name": null, "thin_pool_size": null, "type": "lvm", "vdo_pool_size": null}]}], "safe_mode": false, "use_partitions": null, "volume_defaults": {"cache_devices": [], "cache_mode": null, "cache_size": 0, "cached": false, "compression": null, "deduplication": null, "disks": [], "encryption": false, "encryption_cipher": null, "encryption_key": null, "encryption_key_size": null, "encryption_luks_version": null, "encryption_password": null, "fs_create_options": "", "fs_label": "", "fs_overwrite_existing": true, "fs_type": "xfs", "mount_check": 0, "mount_device_identifier": "uuid", "mount_options": "defaults", "mount_passno": 0, "mount_point": "", "raid_chunk_size": null, "raid_device_count": null, "raid_level": null, "raid_metadata_version": null, "raid_spare_count": null, "size": 0, "state": "present", "thin": null, "thin_pool_name": null, "thin_pool_size": null, "type": "lvm", "vdo_pool_size": null}, "volumes": []}}, "leaves": [], "mounts": [], "msg": "Failed to commit changes to disk: Failed to format device: Input/output error", "packages": ["cryptsetup", "xfsprogs", "lvm2"], "pools": [], "volumes": []}}

Comment 6 Rich Megginson 2023-05-31 14:55:04 UTC
Cannot reproduce - https://beaker.engineering.redhat.com/recipes/14004781#task161062076

wow rhel-9.3 --ignore-panic --arch x86_64 --taskparam=VERSIONLOCK=true --brew-task 52982920 --taskparam=SYSTEM_ROLES_ONLY_TESTS=storage/tests_luks.yml --taskparam=ANSIBLE_VER=2 --fips --brew-method=multi --task 'git://pkgs.devel.redhat.com/tests/rhel-system-roles?master#Sanity/basic-smoke-test' --reservesys-if-warn --whiteboard 'System Roles testing build task 52982920 storage/tests_luks.yml legacy role ansible 2 FIPS'

One difference is that the system roles basic-smoke-test uses an inventory file that contains the following:

myself ansible_connection=local storage_udevadm_trigger=true

e.g. if this is in a file called /tmp/inventory, it does ansible-playbook -vv -i inventory tests/tests_luks.yml

Does your test pass if you use an inventory like this?

Comment 7 Rich Megginson 2023-05-31 15:10:46 UTC
I am now able to reproduce - https://beaker.engineering.redhat.com/recipes/14004781#task161062076 - investigating

Comment 8 Rich Megginson 2023-06-01 01:38:24 UTC
Looks like the problem is that the LUKS encryption cipher used by the test is not supported - changing to a supported cipher makes it work - https://github.com/linux-system-roles/storage/pull/361

Comment 10 guazhang@redhat.com 2023-06-13 08:51:43 UTC
can not reproduce the bug, but hit other bug bz2213691

Comment 12 errata-xmlrpc 2023-11-07 08:29:47 UTC
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 (rhel-system-roles bug fix and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHEA-2023:6390


Note You need to log in before you can comment on or make changes to this bug.