Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be unavailable on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 654756 - "xm block-detach 0" does not work for extended-ID devices
Summary: "xm block-detach 0" does not work for extended-ID devices
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: xen
Version: 5.5
Hardware: Unspecified
OS: Unspecified
low
medium
Target Milestone: rc
: ---
Assignee: Paolo Bonzini
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks: 514500
TreeView+ depends on / blocked
 
Reported: 2010-11-18 18:32 UTC by Paolo Bonzini
Modified: 2011-01-17 10:51 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2011-01-12 08:47:17 UTC
Target Upstream Version:


Attachments (Terms of Use)

Description Paolo Bonzini 2010-11-18 18:32:19 UTC
Description of problem:
Simply taking stat()'s st_rdev doesn't work here, as the minor is
split into two parts, the major is present, and the "extended" bit
isn't set.

Version-Release number of selected component (if applicable):
3.0.3-115.el5

How reproducible:
100%

Steps to Reproduce:
1. Create a PV guest with an xvdaa disk
2. Try to unplug it
  
Actual results:
Doesn't work.

Expected results:
Should work.

Additional info:
Patch at http://permalink.gmane.org/gmane.comp.emulators.xen.devel/93790

Comment 2 Paolo Bonzini 2010-12-02 20:02:20 UTC
Aha, got it.  This is for devices that are hotplugged/hotunplugged to dom0.  A bit weird, but I think you can do it even in RHEL5 (if it works it can be useful as a quick way to mount a device as loopback and see its partitions.

Comment 3 Michal Novotny 2010-12-06 07:50:35 UTC
(In reply to comment #2)
> Aha, got it.  This is for devices that are hotplugged/hotunplugged to dom0.  A
> bit weird, but I think you can do it even in RHEL5 (if it works it can be
> useful as a quick way to mount a device as loopback and see its partitions.

Ok, do you mean something like `xm block-attach 0 /path/to/image xvdaa w` and `xm block-detach 0 xvdaa` or something else? If my procedure is correct those are the test results:

# xm block-attach 0 /home2/test.img xvdaa w
# ls /dev/xvdaa
ls: /dev/xvdaa: No such file or directory
# xm block-list 0
Vdev  BE handle state evt-ch ring-ref BE-path
268442112    0    0     1      -1     -1    /local/domain/0/backend/vbd/0/268442112
# xm block-detach 0 xvdaa
# ls /dev/xvdaa
ls: /dev/xvdaa: No such file or directory
# xm block-list 0
Vdev  BE handle state evt-ch ring-ref BE-path
268442112    0    0     1      -1     -1    /local/domain/0/backend/vbd/0/268442112

So I guess this is not working in RHEL-5 guest or my procedure is not correct and you meant something else.

Could you please give me more information about this?

Thanks,
Michal

Comment 4 Paolo Bonzini 2010-12-06 12:49:47 UTC
Assigning to myself for triaging.

Comment 5 RHEL Program Management 2011-01-11 20:13:32 UTC
This request was evaluated by Red Hat Product Management for
inclusion in the current release of Red Hat Enterprise Linux.
Because the affected component is not scheduled to be updated in the
current release, Red Hat is unfortunately unable to address this
request at this time. Red Hat invites you to ask your support
representative to propose this request, if appropriate and relevant,
in the next release of Red Hat Enterprise Linux.

Comment 6 RHEL Program Management 2011-01-12 15:22:22 UTC
This request was erroneously denied for the current release of
Red Hat Enterprise Linux.  The error has been fixed and this
request has been re-proposed for the current release.

Comment 8 Paolo Bonzini 2011-01-17 10:51:21 UTC
The bug is there from inspecting the code, but I couldn't make the testcase work in general (i.e. I could not even attach, see comment #2).


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