Skip to content

Commit c97c4e0

Browse files
Merge pull request #121 from Manimaran-MM/pynfs-01122025
[Enhancement] Fix delegation issues for Ceph and VFS backend
2 parents 46f0f50 + 2a201ee commit c97c4e0

File tree

3 files changed

+24
-16
lines changed

3 files changed

+24
-16
lines changed

ci_utils/nfs_ganesha/nfs_ganesha_setup.py

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ class GaneshaManager:
99
"""
1010
NFS-Ganesha Setup and Management for CephFS
1111
"""
12-
def __init__(self, session, subvol_path, cephfs_name="cephfs", export_id=101):
12+
def __init__(self, session, subvol_path, cephfs_name="cephfs", export_id=101, test_type=None):
1313
"""
1414
Manage NFS-Ganesha setup on a remote session.
1515
@@ -22,11 +22,18 @@ def __init__(self, session, subvol_path, cephfs_name="cephfs", export_id=101):
2222
self.subvol_path = subvol_path
2323
self.cephfs_name = cephfs_name
2424
self.export_id = export_id
25+
self.test_type = test_type
2526

2627
# ------------------------
2728
# Internal helpers
2829
# ------------------------
2930
def _generate_conf(self):
31+
delegations_v4 = ""
32+
delegations_export = ""
33+
34+
if self.test_type == "pynfs":
35+
delegations_v4 = " Delegations = true;"
36+
delegations_export = " delegations = readwrite;"
3037
return f"""NFS_CORE_PARAM {{
3138
Enable_NLM = false;
3239
Enable_RQUOTA = false;
@@ -35,6 +42,7 @@ def _generate_conf(self):
3542
3643
NFSv4 {{
3744
Enforce_UTF8_Validation = true;
45+
{delegations_v4}
3846
}}
3947
4048
EXPORT_DEFAULTS {{
@@ -49,6 +57,7 @@ def _generate_conf(self):
4957
Transports = TCP;
5058
Access_Type = RW;
5159
Squash = None;
60+
{delegations_export}
5261
FSAL {{
5362
Name = "CEPH";
5463
}}

ci_utils/pynfs/pynfs_setup.py

Lines changed: 12 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ def run_test(
6464
)
6565

6666
if self.backend_type == "ceph":
67+
# BZ-2415387
6768
known_failures = [
6869
"WRT17",
6970
"MKLINK",
@@ -73,6 +74,7 @@ def run_test(
7374
"RNM20"
7475
]
7576
elif self.backend_type == "acl_vfs":
77+
# BZ-2415390
7678
known_failures = [
7779
"WRT17",
7880
"WRT16",
@@ -83,6 +85,7 @@ def run_test(
8385
"LOCK20",
8486
]
8587
elif self.backend_type == "gpfs":
88+
# BZ-2416755
8689
known_failures = [
8790
"WRT17",
8891
"WRT16",
@@ -98,28 +101,32 @@ def run_test(
98101
)
99102

100103
if self.backend_type == "ceph":
104+
# BZ-2415388
101105
known_failures = [
102106
"ALLOC1",
103107
"ALLOC2",
104108
"ALLOC3",
105109
"RNM20",
106110
"DELEG2",
107111
"DELEG23",
108-
"DELEG1",
109112
"DELEG8",
110113
"DELEG25",
111114
"DELEG24",
112-
"DELEG6",
113115
"DELEG7",
114-
"DELEG5",
115-
"DELEG3",
116116
"SEQ6",
117117
"CSESS21",
118118
"CSESS20",
119119
"COMP3",
120120
"EID9",
121+
"EID4",
121122
]
122123
elif self.backend_type == "acl_vfs":
124+
## Adding no-deleg option to skip delegation tests for VFS backends BZ-2415392
125+
cmd = (
126+
f"cd {self.repo_dir}/nfs4.1 && "
127+
f"./testserver.py {server}:{export} all ganesha nodeleg"
128+
f" --secure --verbose --maketree --showomit --rundeps"
129+
)
123130
known_failures = [
124131
"PUTFH1c",
125132
"PUTFH1b",
@@ -131,22 +138,13 @@ def run_test(
131138
"RNM3b",
132139
"LKPP1c",
133140
"LKPP1b",
134-
"DELEG2",
135-
"DELEG23",
136-
"DELEG1",
137-
"DELEG8",
138-
"DELEG25",
139-
"DELEG24",
140-
"DELEG6",
141-
"DELEG7",
142-
"DELEG5",
143-
"DELEG3",
144141
"SEQ6",
145142
"CSESS21",
146143
"CSESS20",
147144
"EID9"
148145
]
149146
elif self.backend_type == "gpfs":
147+
# BZ-2416757
150148
known_failures = [
151149
"XATT5",
152150
"XATT7",

tests/test_pynfs_cthon.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,8 @@ def test_pynfs_cephfs(create_session):
199199
ganesha_setup = GaneshaManager(
200200
session=server_session,
201201
subvol_path=subvol_path,
202-
cephfs_name=ceph_setup.cephfs_name
202+
cephfs_name=ceph_setup.cephfs_name,
203+
test_type="pynfs"
203204
)
204205
ganesha_setup.setup()
205206

0 commit comments

Comments
 (0)