Bug 237659 - RFE: add -r option to losetup to create a read-only loop
Summary: RFE: add -r option to losetup to create a read-only loop
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: util-linux
Version: 5.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
: ---
Assignee: Karel Zak
QA Contact: Ben Levenson
URL:
Whiteboard:
Depends On: 211749
Blocks:
TreeView+ depends on / blocked
 
Reported: 2007-04-24 15:30 UTC by Daniel Berrangé
Modified: 2007-11-30 22:07 UTC (History)
1 user (show)

Fixed In Version: RHBA-2007-0561
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2007-11-07 16:37:20 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2007:0561 0 normal SHIPPED_LIVE util-linux bug fix update 2007-10-30 15:11:47 UTC

Description Daniel Berrangé 2007-04-24 15:30:59 UTC
+++ This bug was initially created as a clone of Bug #211749 +++

Current losetup supports creating RO loops: the set_loop has an argument that
requests and returns the open mode, and the function also checks if the
filesystem the file resides on is mounted read-only.

But there is no way to specify the RO mode from the command line. The attached
patch adds a new -r option.

-- Additional comment from l_rocha on 2006-10-21 15:09 EST --
Created an attachment (id=139067)
patch adding -r option to losetup


-- Additional comment from kzak on 2006-11-01 09:11 EST --
FC6 seems like better target for this feature. Thanks for your patch.

Comment 1 Daniel Berrangé 2007-04-24 15:33:46 UTC
The -r  capability is needed by Xen to allow us to attach a read-only ISO image
from a read-write NFS share to a local loop device. Without the -r option,
losetup fails with -EACCESS. The -r flag is already supported in Fedora Core 6 /
Fedora 7 and thus we're using it in Fedora Xen block device hotplug scripts.


Comment 2 Karel Zak 2007-04-24 18:39:38 UTC
The patch is very small and not invasive.

Comment 3 RHEL Program Management 2007-06-05 20:29:54 UTC
This request was evaluated by Red Hat Product Management for
inclusion in a Red Hat Enterprise Linux release.  Since this
bugzilla is in a component that is not approved for the current
release, it has been closed with resolution deferred.  You may
reopen this bugzilla for consideration in the next release.

Comment 4 Daniel Riek 2007-06-05 20:51:43 UTC
Repopening and requesting Exception as this is a dependency for the Xen related
issue in bug 225166.

Comment 9 errata-xmlrpc 2007-11-07 16:37:20 UTC
An advisory has been issued which should help the problem
described in this bug report. This report is therefore being
closed with a resolution of ERRATA. For more information
on the solution and/or where to find the updated files,
please follow the link below. You may reopen this bug report
if the solution does not work for you.

http://rhn.redhat.com/errata/RHBA-2007-0561.html



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