Bug 850578 - forcegid documented in man page but not supported by mount.cifs
Summary: forcegid documented in man page but not supported by mount.cifs
Keywords:
Status: CLOSED UPSTREAM
Alias: None
Product: Fedora
Classification: Fedora
Component: kernel
Version: 17
Hardware: x86_64
OS: Linux
unspecified
low
Target Milestone: ---
Assignee: Jeff Layton
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-08-21 21:02 UTC by Gregory Lee Bartholomew
Modified: 2014-06-18 07:42 UTC (History)
9 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-10-05 17:29:21 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Gregory Lee Bartholomew 2012-08-21 21:02:36 UTC
Description of problem:

The following command fails:

[root@node-02 ~]# /sbin/mount.cifs //smb.server.domain/share/homedir /mnt -o "noperm,mapchars,dir_mode=0750,file_mode=0640,uid=myusername,forceuid,gid=root,forcegid,domain=server.domain,user=myusername"
Password for myusername@//smb.server.domain/share/homedir:  ********
mount error(22): Invalid argument
Refer to the mount.cifs(8) manual page (e.g. man mount.cifs)

/var/log/messages reports that the "forcegid" option is unknown:

[root@node-02 ~]# grep forcegid /var/log/messages
Aug 21 15:30:40 node-02 kernel: [693888.328908] CIFS: Unknown mount option "forcegid"

The man page indicates that the option should be known:

[root@node-02 ~]# man --pager=cat mount.cifs | grep -B 1 -A 3 forcegid

       forcegid
           instructs the client to ignore any gid provided by the server for files and directories and to
           always assign the owner to be the value of the gid= option. See the section on FILE AND DIRECTORY
           OWNERSHIP AND PERMISSIONS below for more information.
--

       If the uid´s and gid´s being used do not match on the client and server, the forceuid and forcegid
       options may be helpful. Note however, that there is no corresponding option to override the mode.
       Permissions assigned to a file when forceuid or forcegid are in effect may not reflect the the real
       permissions.

The command succeeds if I simply remove the "forcegid" parameter.

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

5.6-1

How reproducible:

Always

Steps to Reproduce:

See Description.
  
Actual results:

Invalid argument

Expected results:

Successful mount

Additional info:

I don't personally need this flag.  This bug report is just FYI.

Comment 1 Jeff Layton 2012-10-03 19:31:03 UTC
This is a kernel bug actually. When the mount option parser was converted to use the standard parsing code, this option got dropped. I have a patch that I'll send upstream after some testing.

Comment 2 Jeff Layton 2012-10-05 17:29:21 UTC
Patch has been merged upstream. I'll go ahead and close this with a resolution of UPSTREAM. It should eventually show up in stable kernels too so f17 will get it at that point.


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