Project

General

Profile

Actions

Bug #17893

closed

Intermittent permission denied using kernel client with mds path cap

Added by John Spray over 7 years ago. Updated over 7 years ago.

Status:
Duplicate
Priority:
Normal
Category:
-
Target version:
-
% Done:

0%

Source:
Community (user)
Tags:
Backport:
Regression:
No
Severity:
3 - minor
Reviewed:
Affected Versions:
ceph-qa-suite:
Component(FS):
MDS
Labels (FS):
Pull request ID:
Crash signature (v1):
Crash signature (v2):

Description

See this mailing list thread:
http://www.spinics.net/lists/ceph-users/msg32314.html

It is reported that when using path-restricted auth caps with the kernel client, userspace is intermittently getting EPERMs on file creations.


Related issues 1 (0 open1 closed)

Is duplicate of CephFS - Bug #17858: Cannot create deep directories when caps contain "path=/somepath"ResolvedPatrick Donnelly11/10/2016

Actions
Actions #1

Updated by Zheng Yan over 7 years ago

dup of #17858

Actions #2

Updated by Patrick Donnelly over 7 years ago

  • Project changed from Linux kernel client to CephFS
  • Category deleted (fs/ceph)
  • Status changed from New to Duplicate
  • Assignee changed from Zheng Yan to Patrick Donnelly
  • Source set to Community (user)
  • Component(FS) MDS added
Actions #3

Updated by Patrick Donnelly over 7 years ago

  • Is duplicate of Bug #17858: Cannot create deep directories when caps contain "path=/somepath" added
Actions #4

Updated by Patrick Donnelly over 7 years ago

I agree with Zheng but I can't be 100% sure this is the same issue because the pasted log doesn't have the "SessionMap check_access path ..." line. It does show the wrong paths in other debug messages though, like this one:

2016-11-10 15:13:51.775292 7f1ec17f2700 10 mds.0.server prepare_null_dentry added [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 inode=0 state=new 0x7f1ee00eca40]

Original pasted log for posterity:

[15:50][root@cephdwightmds0 (production:ceph/dwight/mds*1) ~]# grep akebono.txt /var/log/ceph/ceph-mds.cephdwightmds0.log
2016-11-10 15:13:51.775252 7f1ec17f2700  4 mds.0.server handle_client_request client_request(client.310140372:21057 create #10000003e08/akebono.txt 2016-11-10 15:13:51.774734) v2
2016-11-10 15:13:51.775261 7f1ec17f2700  7 mds.0.server dispatch_client_request client_request(client.310140372:21057 create #10000003e08/akebono.txt 2016-11-10 15:13:51.774734) v2
2016-11-10 15:13:51.775264 7f1ec17f2700  7 mds.0.server open w/ O_CREAT on #10000003e08/akebono.txt
2016-11-10 15:13:51.775265 7f1ec17f2700 10 mds.0.server rdlock_path_xlock_dentry request(client.310140372:21057 cr=0x7f1ee045e3c0) #10000003e08/akebono.txt
2016-11-10 15:13:51.775267 7f1ec17f2700 10 mds.0.server traverse_to_auth_dir dirpath #10000003e08 dname akebono.txt
2016-11-10 15:13:51.775281 7f1ec17f2700 10 mds.0.server prepare_null_dentry akebono.txt in [dir 10000003e08 {#10000003e08 #10000003e07/4xx}/ [2,head] auth v=1 cv=0/0 state=1073741826|complete f() n() hs=0+0,ss=0+0 0x7f1ed2e8bf00]
2016-11-10 15:13:51.775288 7f1ec17f2700 10 mds.0.cache.den(10000003e08 akebono.txt)  mark_new [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 inode=0 0x7f1ee00eca40]
2016-11-10 15:13:51.775292 7f1ec17f2700 10 mds.0.server prepare_null_dentry added [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 inode=0 state=new 0x7f1ee00eca40]
2016-11-10 15:13:51.775365 7f1ec17f2700 10 mds.0.locker  must authpin [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 inode=0 state=new 0x7f1ee00eca40]
2016-11-10 15:13:51.775555 7f1ec17f2700 10 mds.0.locker  auth_pinning [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 inode=0 state=new 0x7f1ee00eca40]
2016-11-10 15:13:51.775559 7f1ec17f2700 10 mds.0.cache.den(10000003e08 akebono.txt) auth_pin by 0x7f1ee24eca00 on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 ap=1+0 inode=0 state=new | authpin=1 0x7f1ee00eca40] now 1+0
2016-11-10 15:13:51.775702 7f1ec17f2700  7 mds.0.locker local_wrlock_start  on (dversion lock) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 ap=1+0 inode=0 state=new | authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.775706 7f1ec17f2700 10 mds.0.locker  got wrlock on (dversion lock w=1 last_client=310140372) [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.775710 7f1ec17f2700  7 mds.0.locker xlock_start on (dn sync) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.775713 7f1ec17f2700  7 mds.0.locker simple_lock on (dn sync) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.775718 7f1ec17f2700  7 mds.0.locker simple_xlock on (dn lock) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn lock) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.775722 7f1ec17f2700 10 mds.0.cache.den(10000003e08 akebono.txt) auth_pin by 0x7f1ee00ecb48 on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn lock) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40] now 2+0
2016-11-10 15:13:51.775726 7f1ec17f2700 10 mds.0.locker  got xlock on (dn xlock x=1 by 0x7f1ee24eca00) [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock x=1 by 0x7f1ee24eca00) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=2 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.778717 7f1ec17f2700  7 mds.0.server dispatch_client_request client_request(client.310140372:21057 create #10000003e08/akebono.txt 2016-11-10 15:13:51.774734) v2
2016-11-10 15:13:51.778722 7f1ec17f2700  7 mds.0.server open w/ O_CREAT on #10000003e08/akebono.txt
2016-11-10 15:13:51.778724 7f1ec17f2700 10 mds.0.server rdlock_path_xlock_dentry request(client.310140372:21057 cr=0x7f1ee045e3c0) #10000003e08/akebono.txt
2016-11-10 15:13:51.778726 7f1ec17f2700 10 mds.0.server traverse_to_auth_dir dirpath #10000003e08 dname akebono.txt
2016-11-10 15:13:51.778740 7f1ec17f2700 10 mds.0.server prepare_null_dentry akebono.txt in [dir 10000003e08 {#10000003e08 #10000003e07/4xx}/ [2,head] auth v=1 cv=0/0 ap=0+2+2 state=1073741826|complete f() n() hs=0+1,ss=0+0 | child=1 0x7f1ed2e8bf00]
2016-11-10 15:13:51.778816 7f1ec17f2700 10 mds.0.locker  must authpin [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock x=1 by 0x7f1ee24eca00) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=2 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.778959 7f1ec17f2700 10 mds.0.locker  already auth_pinned [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock x=1 by 0x7f1ee24eca00) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=2 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779028 7f1ec17f2700 10 mds.0.locker  already wrlocked (dversion lock w=1 last_client=310140372) [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock x=1 by 0x7f1ee24eca00) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=2 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779033 7f1ec17f2700 10 mds.0.locker  already xlocked (dn xlock x=1 by 0x7f1ee24eca00) [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock x=1 by 0x7f1ee24eca00) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=2 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779325 7f1ec17f2700 10 mds.0.server reply_client_request -13 ((13) Permission denied) client_request(client.310140372:21057 create #10000003e08/akebono.txt 2016-11-10 15:13:51.774734) v2
2016-11-10 15:13:51.779339 7f1ec17f2700 10 mds.0.locker xlock_finish on (dn xlock x=1 by 0x7f1ee24eca00) [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock x=1 by 0x7f1ee24eca00) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=2 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779365 7f1ec17f2700 10 mds.0.locker eval_gather (dn xlock) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779371 7f1ec17f2700  7 mds.0.locker eval_gather finished gather on (dn xlock) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dn xlock) (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=2+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779382 7f1ec17f2700 10 mds.0.cache.den(10000003e08 akebono.txt) auth_unpin by 0x7f1ee00ecb48 on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40] now 1+0
2016-11-10 15:13:51.779388 7f1ec17f2700 10 mds.0.locker simple_eval (dn sync) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779391 7f1ec17f2700  7 mds.0.locker local_wrlock_finish  on (dversion lock w=1 last_client=310140372) on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock w=1 last_client=310140372) pv=0 v=1 ap=1+0 inode=0 state=new | request=1 lock=1 authpin=1 0x7f1ee00eca40]
2016-11-10 15:13:51.779964 7f1ec17f2700 10 mds.0.cache.den(10000003e08 akebono.txt) auth_unpin by 0x7f1ee24eca00 on [dentry #10000003e08/akebono.txt [2,head] auth NULL (dversion lock) pv=0 v=1 inode=0 state=new | request=1 lock=0 authpin=0 0x7f1ee00eca40] now 0+0
Actions

Also available in: Atom PDF