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 1597890 - vdo growPhysical of a volume resized offline reports new physical block count as old physical block count
Summary: vdo growPhysical of a volume resized offline reports new physical block count...
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: kmod-kvdo
Version: 7.6
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: rc
: ---
Assignee: Matthew Sakai
QA Contact: Jakub Krysl
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-07-03 20:24 UTC by Bryan Gurney
Modified: 2021-09-03 12:07 UTC (History)
2 users (show)

Fixed In Version: 6.1.1.107
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-10-30 09:39:49 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2018:3094 0 None None None 2018-10-30 09:40:14 UTC

Description Bryan Gurney 2018-07-03 20:24:41 UTC
Description of problem:
If a VDO volume is stopped, and has its backing device resized offline, the message for the physical block count change will print what should be "Physical block count was <old_size>, now <new_size>", but it was discovered in BZ 1582647 that the message now prints as "Physical block count was <new_size>, now <new_size>".

(This does not occur with a backing device that is resized offline)

Version-Release number of selected component (if applicable):
kmod-kvdo-6.1.1.99-1.el7.x86_64

How reproducible:
100%

Steps to Reproduce:
1. Create a partition on a test device, with ample space for resizing (I used a 50 GiB partition).
2. Create a VDO volume on the test partition.
3. Stop the VDO volume with the "vdo stop" command.
4. Grow the device.
5. Start the VDO volume with the "vdo start" command.
6. Execute a "vdo growPhysical" command.



Actual results:
The growPhysical command executes successfully, but the message printed has an "old size" listed with the value of the new size.

Example: "kvdo7:dmsetup: Physical block count was 26214144, now 26214144"


Expected results:
The growPhysical command executed successfully, and the message indicates the previous physical block count, and the new physical block count after the growPhysical operation.

Example: "kvdo7:dmsetup: Physical block count was 13106944, now 26214144"


Additional info:

Demonstration on a test system:

[root@localhost ~]# parted /dev/nvme0n1 mkpart pri 1MiB 50GiB     
Information: You may need to update /etc/fstab.

[root@localhost ~]# vdo create --name=vdo1 --device=/dev/nvme0n1p1
Creating VDO vdo1
Starting VDO vdo1
Starting compression on VDO vdo1
VDO instance 6 volume is ready at /dev/mapper/vdo1
[root@localhost ~]# vdostats vdo1 --verbose | grep hysical\ blocks
  physical blocks                     : 13106944
[root@localhost ~]# vdo stop --name=vdo1
Stopping VDO vdo1
[root@localhost ~]# parted /dev/nvme0n1 resizepart 1 100GiB
Information: You may need to update /etc/fstab.

[root@localhost ~]# vdo start --name=vdo1                                 
Starting VDO vdo1
Starting compression on VDO vdo1
VDO instance 7 volume is ready at /dev/mapper/vdo1
[root@localhost ~]# vdostats vdo1 --verbose | grep hysical\ blocks
  physical blocks                     : 13106944
[root@localhost ~]# date; vdo growPhysical --name=vdo1
Tue Jul  3 16:10:40 EDT 2018
[root@localhost ~]# vdostats vdo1 --verbose | grep hysical\ blocks
  physical blocks                     : 26214144

Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: Preparing to resize physical to 26214144
Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: Done preparing to resize physical
Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: suspending device 'vdo1'
Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: device 'vdo1' suspended
Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: Physical block count was 26214144, now 26214144
Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: resuming device 'vdo1'
Jul  3 16:10:40 localhost kernel: kvdo7:dmsetup: device 'vdo1' resumed

Comment 2 Jakub Krysl 2018-07-04 06:52:47 UTC
Thanks Bryan for creating the BZ, less work for me. :)
I wanted to create it when I am sure the parent BZ 1582647 does not cause any regressions so it can go in. If any regressions are found, that fix might be completely different and this BZ might not be needed at all.

Comment 4 Jakub Krysl 2018-07-18 11:02:47 UTC
# vdostats vdo --verbose | grep hysical\ blocks
  physical blocks                     : 13106944
# vdo growPhysical --name=vdo --verbose
    dmsetup status vdo
    dmsetup message vdo 0 prepareToGrowPhysical
    vdodmeventd -u vdo
    dmsetup suspend vdo
    dmsetup message vdo 0 growPhysical
    vdodumpconfig /dev/disk/by-id/scsi-3600140550ade793f6124ab5b420f3c20-part1
    dmsetup resume vdo
    vdodmeventd -r vdo
# vdostats vdo --verbose | grep hysical\ blocks
  physical blocks                     : 18349824

/var/log/messages:
[165564.457326] kvdo83:dmsetup: Preparing to resize physical to 18349824
[165564.493024] kvdo83:dmsetup: Done preparing to resize physical
[165564.530973] kvdo83:dmsetup: suspending device 'vdo'
[165564.554436] kvdo83:dmsetup: device 'vdo' suspended
[165564.829926] kvdo83:dmsetup: Physical block count was 13106944, now 18349824
[165564.874701] kvdo83:dmsetup: resuming device 'vdo'
[165564.896901] kvdo83:dmsetup: device 'vdo' resumed

Comment 6 errata-xmlrpc 2018-10-30 09:39:49 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, 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-2018:3094


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