Bug 1717435
| Summary: | Uncaught assertion error when given too small physical size in dmsetup table | ||
|---|---|---|---|
| Product: | Red Hat Enterprise Linux 8 | Reporter: | Jakub Krysl <jkrysl> |
| Component: | kmod-kvdo | Assignee: | sclafani |
| Status: | CLOSED ERRATA | QA Contact: | vdo-qe |
| Severity: | unspecified | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 8.0 | CC: | awalsh, bgurney, jkrysl |
| Target Milestone: | rc | Flags: | pm-rhel:
mirror+
|
| Target Release: | 8.0 | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Whiteboard: | |||
| Fixed In Version: | 6.2.1.129 | Doc Type: | If docs needed, set a value |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2019-11-05 22:12:41 UTC | Type: | Bug |
| Regression: | --- | Mount Type: | --- |
| Documentation: | --- | CRM: | |
| Verified Versions: | Category: | --- | |
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
| Cloudforms Team: | --- | Target Upstream Version: | |
| Embargoed: | |||
|
Description
Jakub Krysl
2019-06-05 13:18:17 UTC
I was able to reproduce the scenario on my test system: $ sudo vdoformat /dev/sdb Logical blocks defaulted to 120879344 blocks 120979344 4096-byte blocks is equivalent to 967034752 512-byte sectors; this will be needed for the "dmsetup table" entry. To find the proper physical size, use "vdodumpconfig <device>" to read the VDO config from the superblock: $ sudo vdodumpconfig /dev/sdb VDOConfig: blockSize: 4096 logicalBlocks: 120879344 physicalBlocks: 122096646 ... Using these parameters, construct the device-mapper table entry: $ sudo modprobe kvdo $ sudo dmsetup create vdo0 --table '0 967034752 vdo V2 /dev/sdb 122096646 4096 32768 16380 off auto vdo0 hash 1 logical 3 physical 2' This completes successfully: Jun 05 09:36:14 localhost.localdomain kernel: kvdo0:dmsetup: starting device 'vdo0' Jun 05 09:36:14 localhost.localdomain kernel: kvdo0:dmsetup: zones: 3 logical, 2 physical, 1 hash; base threads: 8 Jun 05 09:36:14 localhost.localdomain kernel: kvdo0:journalQ: VDO commencing normal operation But if I "accidentally" divide the physical size by 100, I can see the error: $ sudo dmsetup create vdo0 --table '0 967034752 vdo V2 /dev/sdb 1220966 4096 32768 16380 off auto vdo0 hash 1 logical 3 physical 2' device-mapper: reload ioctl on vdo0 failed: Input/output error Command failed. Jun 05 10:00:02 localhost.localdomain kernel: kvdo1:dmsetup: starting device 'vdo0' Jun 05 10:00:02 localhost.localdomain kernel: kvdo1:dmsetup: zones: 3 logical, 2 physical, 1 hash; base threads: 8 Jun 05 10:00:02 localhost.localdomain kernel: uds: kvdo1:journalQ: assertion "Physical size 122096646 in super block smaller than expected size 1220966" (config->physicalBlocks <= blockCount) failed at /builddir/build/BUILD/kvdo-8df6805f0c4eddae59c9edcebeeab885c835f93c/obj/./vdo/base/vdo.c:629 Jun 05 10:00:02 localhost.localdomain kernel: uds: kvdo1:journalQ: [backtrace] Jun 05 10:00:02 localhost.localdomain kernel: CPU: 9 PID: 11293 Comm: kvdo1:journalQ Kdump: loaded Tainted: G O ---------r- - 4.18.0-80.1.2.el8_0.x86_64 #1 Jun 05 10:00:02 localhost.localdomain kernel: Hardware name: Supermicro X9DR3-F/X9DR3-F, BIOS 3.2a 07/09/2015 Jun 05 10:00:02 localhost.localdomain kernel: Call Trace: Jun 05 10:00:02 localhost.localdomain kernel: dump_stack+0x5c/0x80 Jun 05 10:00:02 localhost.localdomain kernel: assertionFailed+0x4f/0x70 [uds] Jun 05 10:00:02 localhost.localdomain kernel: ? decodeVersionNumber+0x12/0x30 [kvdo] Jun 05 10:00:02 localhost.localdomain kernel: ? decodeVDOComponent+0x15d/0x200 [kvdo] Jun 05 10:00:02 localhost.localdomain kernel: validateVDOConfig+0x28a/0x3d0 [kvdo] Jun 05 10:00:02 localhost.localdomain kernel: loadVDOComponents+0x40/0x3d0 [kvdo] Jun 05 10:00:02 localhost.localdomain kernel: workQueueRunner+0x1b9/0x660 [kvdo] Jun 05 10:00:02 localhost.localdomain kernel: ? finish_wait+0x80/0x80 Jun 05 10:00:02 localhost.localdomain kernel: ? initKernelVDOOnce+0x20/0x20 [kvdo] Jun 05 10:00:02 localhost.localdomain kernel: kthread+0x112/0x130 Jun 05 10:00:02 localhost.localdomain kernel: ? kthread_bind+0x30/0x30 Jun 05 10:00:02 localhost.localdomain kernel: ret_from_fork+0x35/0x40 Jun 05 10:00:02 localhost.localdomain kernel: kvdo1:journalQ: aborting load: kvdo: Parameters have conflicting values (2060) Jun 05 10:00:02 localhost.localdomain kernel: kvdo1:dmsetup: Could not start kernel physical layer. (VDO error 2060, message Cannot load metadata from device) Jun 05 10:00:02 localhost.localdomain kernel: kvdo1:dmsetup: mapToSystemError: mapping internal status code 2060 (kvdo: VDO_PARAMETER_MISMATCH: kvdo: Parameters have conflicting values) to EIO Jun 05 10:00:02 localhost.localdomain kernel: device-mapper: table: 253:3: vdo: Cannot load metadata from device Jun 05 10:00:02 localhost.localdomain kernel: device-mapper: ioctl: error adding target to table Eliminated the backtrace and improved the wording of the log message. kmod-kvdo-6.2.1.134-56.el8 Aug 21 09:32:15 storageqe-90 kernel: kvdo792:dmsetup: underlying device, REQ_FLUSH: supported, REQ_FUA: supported Aug 21 09:32:15 storageqe-90 kernel: kvdo792:dmsetup: Using write policy async automatically. Aug 21 09:32:15 storageqe-90 kernel: kvdo792:dmsetup: loading device 'vdo0' Aug 21 09:32:15 storageqe-90 kernel: kvdo792:dmsetup: zones: 3 logical, 2 physical, 1 hash; base threads: 8 Aug 21 09:32:15 storageqe-90 kernel: kvdo792:journal: A physical size of 23592704 blocks was specified, but that is smaller than the 2441609216 blocks configured in the VDO super block Aug 21 09:32:15 storageqe-90 kernel: kvdo792:journal: aborting load: kvdo: Parameters have conflicting values (2060) Aug 21 09:32:15 storageqe-90 kernel: kvdo792:dmsetup: Could not start kernel physical layer. (VDO error 2060, message Cannot load metadata from device) Aug 21 09:32:15 storageqe-90 kernel: kvdo792:dmsetup: mapToSystemError: mapping internal status code 2060 (kvdo: VDO_PARAMETER_MISMATCH: kvdo: Parameters have conflicting values) to EIO Aug 21 09:32:15 storageqe-90 kernel: device-mapper: table: 253:0: vdo: Cannot load metadata from device Aug 21 09:32:15 storageqe-90 kernel: device-mapper: ioctl: error adding target to table 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, 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/RHBA-2019:3548 |