Bug 609097 - mount -o remount <cifs> creates additional entries in /etc/mtab
Summary: mount -o remount <cifs> creates additional entries in /etc/mtab
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 4
Classification: Red Hat
Component: samba   
(Show other bugs)
Version: 4.8
Hardware: All
OS: Linux
low
medium
Target Milestone: rc
: ---
Assignee: Jeff Layton
QA Contact: qe-baseos-daemons
URL:
Whiteboard:
Keywords:
Depends On:
Blocks: 770004 1109448
TreeView+ depends on / blocked
 
Reported: 2010-06-29 12:32 UTC by Brett Maton
Modified: 2014-06-18 07:40 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 770004 (view as bug list)
Environment:
Last Closed: 2012-01-10 20:22:07 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description Brett Maton 2010-06-29 12:32:44 UTC
Description of problem:

If you remount a cifs file share an additional entry is added to /etc/mtab instead of updating the existing entry. 

/proc/mounts is correct however. 
  

The problem/confusion is that if you run mount -v to view current mounted volumes you'll get the extras from /etc/mtab displayed. 

If you try to umount these spurious volumes you'll get an error something like: 

This utility only unmounts cifs filesystems. 
This utility only unmounts cifs filesystems. 

Version-Release number of selected component (if applicable):

util-linux-2.12a-24.el4_8.1 


How reproducible:
Every time

Steps to Reproduce:
1. mount -v
...
//cifs_server/my_share  /mnt/my_share

2. mount -o remount /mnt/my_share

3. mount -v
...
//cifs_server/my_share  /mnt/my_share
//cifs_server/my_share  /mnt/my_share
  
Actual results:

Additional entry added to /etc/mtab

Expected results:

Existing entry should have been updated

Additional info:

/proc/mounts  contains correct mount information.

Comment 1 Karel Zak 2010-06-29 13:14:22 UTC
Reassigning to samba, mount(8) does not update the mtab file, it calls /sbin/mount.cifs.

Comment 2 Brett Maton 2010-07-08 11:45:47 UTC
This is causing automated tools that check the output of mount -v to fail.

Severity raised from low ot medium.

Comment 3 Brett Maton 2010-08-06 07:58:56 UTC
Anything happening with regards to this bug?

Comment 4 Jeff Layton 2010-08-06 11:18:25 UTC
FWIW, -o remount is a noop for CIFS. In fact, this command probably ought to return an error. I'll see about pushing something upstream when I have time.

Comment 5 Brett Maton 2010-08-09 12:20:13 UTC
This issue also occurs on Red Hat Enterprise Linux Server release 5.5 (Tikanga)

Comment 6 Tru Huynh 2010-10-06 13:12:45 UTC
http://bugs.centos.org/view.php?id=4535

Comment 7 Jeff Layton 2012-01-10 20:22:07 UTC
There's a patch in progress for this upstream by Carlos Maolino, but I don't think this is probably going to meet the criticality threshold for RHEL4. I'm going to close this WONTFIX. If you want to make a case for backporting this to RHEL4, then please open a RH support case and request that this be reopened.


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