Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
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 615389

Summary: Output of "mount" is missing mapping displays for loop-mounts
Product: Red Hat Enterprise Linux 6 Reporter: Alexander Hass <alexander.hass>
Component: util-linux-ngAssignee: Karel Zak <kzak>
Status: CLOSED ERRATA QA Contact: qe-baseos-daemons
Severity: medium Docs Contact:
Priority: medium    
Version: 6.1CC: azelinka, fdanapfe, linux, rdoty, rvokal
Target Milestone: rc   
Target Release: 6.1   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: util-linux-ng-2.17.2-9.el6 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-05-19 14:05:45 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 580566    

Description Alexander Hass 2010-07-16 16:38:17 UTC
The output of "mount" does not display the mapping of <source image> to
<mountpoint> directly in RHEL 6, where RHEL 5 used to display it. E.g.

# mount -o loop,ro /mnt/tmp/rhel/6.0beta2/x86_64/RHEL6.0-20100622.1-Server-x86_64-DVD1.iso /mnt/loop/

RHEL 5.2 (util-linux-2.13-0.47.el5):
# mount | grep iso
/mnt/tmp/rhel/6.0beta2/x86_64/RHEL6.0-20100622.1-Server-x86_64-DVD1.iso on /mnt/loop type iso9660 (ro,loop=/dev/loop0)

RHEL 6 (util-linux-ng-2.17.2-1.el6.x86_64):
# mount | grep iso
/dev/loop0 on /mnt/loop type iso9660 (ro)

Therefore the needed information has to be determined manually, e.g. via
"losetup":

# losetup /dev/loop0
/dev/loop0: [0016]:1519 (/mnt/tmp/rhel/6.0beta2/x86_64/RHEL6.0-20100622.1-Server-x86_64*)

Please adapt "mount" to resolve the mappings directly again.

Comment 2 RHEL Program Management 2010-07-16 16:57:38 UTC
This issue has been proposed when we are only considering blocker
issues in the current Red Hat Enterprise Linux release. It has
been denied for the current Red Hat Enterprise Linux release.

** If you would still like this issue considered for the current
release, ask your support representative to file as a blocker on
your behalf. Otherwise ask that it be considered for the next
Red Hat Enterprise Linux release. **

Comment 3 Karel Zak 2010-07-19 13:04:16 UTC
The Linux kernel (since 2.6.25) supports auto-clear flag for mount
devices. All loop devices with this flag are automatically destroyed
when the device is unmounted. The auto-clear flag allows to remove loop=
mount option from /etc/mtab.

Our long-term goal is to remove /etc/mtab from Linux (and use
/proc/self/mountinfo only), so we want to minimize number of userspace
specific mount options. 

We can revert the auto-clear support in RHEL6 mount(8), but it's not optimal
solution from long-term point of view.

The final solution is to improve losetup(8) to return full path to the
backing file (now the filename is restricted to 64 bytes in
LOOP_GET_STATUS ioctl (the ideal solution is to have the filename in /sys)).

Comment 4 Karel Zak 2010-07-29 11:15:12 UTC
Side effect of this bug is that "mount -a" can mount the same image file twice -- for more details see bug #618957

Comment 10 errata-xmlrpc 2011-05-19 14:05:45 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 therefore 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-2011-0699.html