From 7b1fa17c21f1d826937a5079a16ee5c71340e2bf Mon Sep 17 00:00:00 2001 From: Varsha Rao Date: Fri, 26 Apr 2019 23:20:51 +0530 Subject: [PATCH] cephfs-shell: Fix mkdir relative path error Directory is not created for relative path. This patch fixes it. Fixes: https://tracker.ceph.com/issues/39507 Signed-off-by: Varsha Rao (cherry picked from commit e89287673c3470b00125682b1d0bdab6e0e08ef4) --- src/tools/cephfs/cephfs-shell | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/tools/cephfs/cephfs-shell b/src/tools/cephfs/cephfs-shell index 07b5adee9c5f..673bc47db311 100644 --- a/src/tools/cephfs/cephfs-shell +++ b/src/tools/cephfs/cephfs-shell @@ -479,7 +479,8 @@ exists.') Create directory. """ for dir_name in args.dirs: - path = to_bytes('/' + dir_name) + path = to_bytes(dir_name) + if args.mode: permission = int(args.mode, 8) else: -- 2.47.3