Skip to content

Commit bcdffd7

Browse files
committed
docs: fix markdown linting issues
- Capitalize 'Mount Pod' and 'Mount Pods' consistently per enhanced-proper-names rule - Fix all occurrences in daemonset-mount.md and mount-pod-configuration.md - Comply with .markdownlint-cli2.jsonc configuration
1 parent ac344f4 commit bcdffd7

File tree

4 files changed

+403
-70
lines changed

4 files changed

+403
-70
lines changed

.markdownlint-cli2.jsonc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,7 @@
4747
},
4848
"link-fragments": false,
4949
"no-trailing-slash-in-links": true,
50+
"MD029": false,
5051
"enhanced-proper-names": {
5152
"code_blocks": false,
5253
"html_elements": false,

docs/en/guide/daemonset-mount.md

Lines changed: 22 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,22 @@
11
# DaemonSet Mount for StorageClass
22

3-
This feature allows JuiceFS CSI Driver to deploy mount pods as DaemonSets instead of individual pods when using StorageClass with mount sharing enabled. This provides better resource management and control over which nodes run mount pods.
3+
This feature allows JuiceFS CSI Driver to deploy Mount Pods as DaemonSets instead of individual Pods when using StorageClass with mount sharing enabled. This provides better resource management and control over which nodes run Mount Pods.
44

55
## Overview
66

7-
When `STORAGE_CLASS_SHARE_MOUNT` is enabled, JuiceFS CSI Driver shares mount pods across multiple PVCs that use the same StorageClass. By default, these are created as individual pods. With the DaemonSet option, mount pods are deployed as DaemonSets, providing:
7+
When `STORAGE_CLASS_SHARE_MOUNT` is enabled, JuiceFS CSI Driver shares Mount Pods across multiple PVCs that use the same StorageClass. By default, these are created as individual Pods. With the DaemonSet option, Mount Pods are deployed as DaemonSets, providing:
88

9-
- **Better resource control**: DaemonSets ensure one mount pod per selected node
10-
- **Node affinity support**: Control which nodes run mount pods using nodeAffinity
11-
- **Automatic lifecycle management**: DaemonSets handle pod creation/deletion automatically
12-
- **Simplified operations**: Easier to manage and monitor mount pods
9+
- **Better resource control**: DaemonSets ensure one Mount Pod per selected node
10+
- **Node affinity support**: Control which nodes run Mount Pods using nodeAffinity
11+
- **Automatic lifecycle management**: DaemonSets handle Pod creation/deletion automatically
12+
- **Simplified operations**: Easier to manage and monitor Mount Pods
1313
- **Works with existing StorageClasses**: No need to modify or recreate StorageClasses
1414

1515
## Configuration
1616

1717
### Enable DaemonSet Mount
1818

19-
To enable DaemonSet mount for StorageClass, set these environment variables in the CSI driver deployment:
19+
To enable DaemonSet mount for StorageClass, set these environment variables in the CSI Driver deployment:
2020

2121
```yaml
2222
env:
@@ -28,7 +28,7 @@ env:
2828
2929
### Configure Node Affinity
3030
31-
There are two ways to configure node affinity for DaemonSet mount pods:
31+
There are two ways to configure node affinity for DaemonSet Mount Pods:
3232
3333
#### Method 1: ConfigMap (Recommended for existing StorageClasses)
3434
@@ -77,7 +77,7 @@ provisioner: csi.juicefs.com
7777
parameters:
7878
# ... other parameters ...
7979
80-
# Node affinity configuration for DaemonSet mount pods
80+
# Node affinity configuration for DaemonSet Mount Pods
8181
nodeAffinity: |
8282
requiredDuringSchedulingIgnoredDuringExecution:
8383
nodeSelectorTerms:
@@ -91,14 +91,14 @@ parameters:
9191
## How It Works
9292

9393
1. When a PVC is created using a StorageClass with DaemonSet mount enabled:
94-
- The CSI driver checks if a DaemonSet for this StorageClass already exists
94+
- The CSI Driver checks if a DaemonSet for this StorageClass already exists
9595
- If not, it looks for node affinity configuration:
9696
- First checks the ConfigMap for StorageClass-specific or default configuration
9797
- Falls back to StorageClass parameters if specified
9898
- Creates a new DaemonSet with the configured node affinity
9999
- If DaemonSet exists, it adds a reference to the existing DaemonSet
100100

101-
2. The DaemonSet ensures mount pods are running on selected nodes:
101+
2. The DaemonSet ensures Mount Pods are running on selected nodes:
102102
- Pods are automatically created on nodes matching the affinity rules
103103
- Mount paths are shared across PVCs using the same StorageClass
104104

@@ -109,6 +109,7 @@ parameters:
109109
## Priority Order
110110

111111
The system checks for node affinity configuration in this order:
112+
112113
1. **StorageClass parameters** (if `nodeAffinity` is specified)
113114
2. **ConfigMap with StorageClass name** as key
114115
3. **ConfigMap default** configuration
@@ -118,7 +119,7 @@ The system checks for node affinity configuration in this order:
118119

119120
### Dedicated Mount Nodes
120121

121-
Label specific nodes for running mount pods:
122+
Label specific nodes for running Mount Pods:
122123

123124
```bash
124125
kubectl label nodes node1 node2 node3 juicefs/mount-node=true
@@ -128,7 +129,7 @@ Then use nodeAffinity in StorageClass to target these nodes.
128129

129130
### High-Performance Nodes
130131

131-
Prefer nodes with better resources for mount pods:
132+
Prefer nodes with better resources for Mount Pods:
132133

133134
```yaml
134135
nodeAffinity: |
@@ -145,7 +146,7 @@ nodeAffinity: |
145146

146147
### Exclude Control Plane
147148

148-
Prevent mount pods from running on control plane nodes:
149+
Prevent Mount Pods from running on control plane nodes:
149150

150151
```yaml
151152
nodeAffinity: |
@@ -158,7 +159,7 @@ nodeAffinity: |
158159

159160
## Monitoring
160161

161-
You can monitor DaemonSet mount pods using standard Kubernetes commands:
162+
You can monitor DaemonSet Mount Pods using standard Kubernetes commands:
162163

163164
```bash
164165
# List all mount DaemonSets
@@ -179,24 +180,24 @@ kubectl get pods -n kube-system -l juicefs.com/mount-by=juicefs-csi-driver
179180

180181
## Migration
181182

182-
To migrate from pod-based mounts to DaemonSet mounts:
183+
To migrate from Pod-based mounts to DaemonSet mounts:
183184

184-
1. Enable the feature flags in CSI driver
185+
1. Enable the feature flags in CSI Driver
185186
2. Create a new StorageClass with desired node affinity
186187
3. Migrate PVCs to the new StorageClass
187-
4. Old mount pods will be replaced by DaemonSet pods
188+
4. Old Mount Pods will be replaced by DaemonSet Pods
188189

189190
## Troubleshooting
190191

191-
### DaemonSet pods not created
192+
### DaemonSet Pods not created
192193

193194
Check if nodes match the affinity rules:
194195

195196
```bash
196197
kubectl get nodes --show-labels | grep <your-label>
197198
```
198199

199-
### Mount pods on unexpected nodes
200+
### Mount Pods on unexpected nodes
200201

201202
Verify the nodeAffinity configuration:
202203

@@ -210,4 +211,4 @@ Check DaemonSet annotations:
210211

211212
```bash
212213
kubectl get daemonset <name> -n kube-system -o jsonpath='{.metadata.annotations}'
213-
```
214+
```

docs/en/guide/mount-pod-configuration.md

Lines changed: 39 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,20 @@
11
# Mount Pod Configuration Guide
22

3-
JuiceFS CSI Driver provides flexible mount pod deployment options that can be configured per StorageClass. This allows you to optimize resource usage and performance based on your specific needs.
3+
JuiceFS CSI Driver provides flexible Mount Pod deployment options that can be configured per StorageClass. This allows you to optimize resource usage and performance based on your specific needs.
44

55
## Overview
66

7-
JuiceFS CSI Driver supports three mount pod deployment modes:
7+
JuiceFS CSI Driver supports three Mount Pod deployment modes:
88

9-
1. **Per-PVC Mode** (`per-pvc`): Creates a separate mount pod for each PVC
10-
2. **Shared Pod Mode** (`shared-pod`): Shares mount pods across PVCs using the same StorageClass
11-
3. **DaemonSet Mode** (`daemonset`): Deploys mount pods as DaemonSets with node affinity support
9+
1. **Per-PVC Mode** (`per-pvc`): Creates a separate Mount Pod for each PVC
10+
2. **Shared Pod Mode** (`shared-pod`): Shares Mount Pods across PVCs using the same StorageClass
11+
3. **DaemonSet Mode** (`daemonset`): Deploys Mount Pods as DaemonSets with node affinity support
1212

1313
## Configuration Methods
1414

1515
### Global Defaults (Environment Variables)
1616

17-
Set default behavior for all StorageClasses via environment variables in the CSI driver:
17+
Set default behavior for all StorageClasses via environment variables in the CSI Driver:
1818

1919
```yaml
2020
env:
@@ -61,59 +61,68 @@ data:
6161
6262
### Per-PVC Mode
6363
64-
Each PVC gets its own dedicated mount pod.
64+
Each PVC gets its own dedicated Mount Pod.
6565
6666
**Advantages:**
67+
6768
- Complete isolation between PVCs
6869
- Simple troubleshooting
6970
- Independent lifecycle management
7071
7172
**Use Cases:**
73+
7274
- Development environments
7375
- Multi-tenant scenarios requiring strict isolation
7476
- Applications with specific mount configurations
7577
7678
**Configuration:**
79+
7780
```yaml
7881
mode: per-pvc
7982
```
8083
8184
### Shared Pod Mode
8285
83-
Multiple PVCs using the same StorageClass share mount pods.
86+
Multiple PVCs using the same StorageClass share Mount Pods.
8487
8588
**Advantages:**
89+
8690
- Reduced resource consumption
87-
- Fewer pods to manage
91+
- Fewer Pods to manage
8892
- Shared cache benefits
8993
9094
**Use Cases:**
95+
9196
- Production environments with many PVCs
9297
- Clusters with resource constraints
9398
- Applications with similar access patterns
9499
95100
**Configuration:**
101+
96102
```yaml
97103
mode: shared-pod
98104
```
99105
100106
### DaemonSet Mode
101107
102-
Mount pods are deployed as DaemonSets across selected nodes.
108+
Mount Pods are deployed as DaemonSets across selected nodes.
103109
104110
**Advantages:**
105-
- Predictable pod placement
111+
112+
- Predictable Pod placement
106113
- Node-level resource optimization
107114
- Automatic scaling with node additions
108115
- Centralized node affinity control
109116
110117
**Use Cases:**
118+
111119
- High-performance computing
112-
- Dedicated mount nodes
120+
- Dedicated Mount nodes
113121
- GPU workloads
114122
- Large-scale deployments
115123
116124
**Configuration:**
125+
117126
```yaml
118127
mode: daemonset
119128
nodeAffinity:
@@ -140,7 +149,7 @@ The ConfigMap approach allows you to change mount behavior **without modifying e
140149
141150
1. Create the ConfigMap with desired configuration
142151
2. New PVCs will use the new mount mode
143-
3. Existing PVCs continue using their current mount pods
152+
3. Existing PVCs continue using their current Mount Pods
144153
145154
## Examples
146155
@@ -202,7 +211,7 @@ data:
202211
203212
### Example 3: Node-Specific DaemonSets
204213
205-
Deploy mount pods on specific node types:
214+
Deploy Mount Pods on specific node types:
206215
207216
```yaml
208217
apiVersion: v1
@@ -264,7 +273,7 @@ kubectl get configmap juicefs-mount-config -n kube-system -o jsonpath='{.data.my
264273

265274
## Best Practices
266275

267-
1. **Start with shared-pod mode** for most workloads
276+
1. **Start with shared-Pod mode** for most workloads
268277
2. **Use DaemonSet mode** for:
269278
- High-performance requirements
270279
- Predictable resource allocation
@@ -279,39 +288,44 @@ kubectl get configmap juicefs-mount-config -n kube-system -o jsonpath='{.data.my
279288

280289
## Troubleshooting
281290

282-
### Mount pods not created as expected
291+
### Mount Pods not created as expected
283292

284293
1. Check ConfigMap exists and is valid:
294+
285295
```bash
286296
kubectl get configmap juicefs-mount-config -n kube-system
287297
```
288298

289-
2. Verify CSI driver can read ConfigMap:
299+
2. Verify CSI Driver can read ConfigMap:
300+
290301
```bash
291302
kubectl logs -n kube-system daemonset/juicefs-csi-node | grep "mount-config"
292303
```
293304

294305
3. Check for syntax errors in ConfigMap:
306+
295307
```bash
296308
kubectl get configmap juicefs-mount-config -n kube-system -o yaml | \
297309
yq eval '.data.default' - | kubectl create --dry-run=client -f -
298310
```
299311

300-
### DaemonSet pods not scheduled
312+
### DaemonSet Pods not scheduled
301313

302314
1. Verify node affinity matches existing nodes:
315+
303316
```bash
304317
kubectl get nodes --show-labels
305318
```
306319

307320
2. Check DaemonSet status:
321+
308322
```bash
309323
kubectl describe daemonset -n kube-system juicefs-<uniqueid>-mount-ds
310324
```
311325

312326
### Switching modes for existing PVCs
313327

314-
Existing PVCs continue using their current mount pods. To switch modes:
328+
Existing PVCs continue using their current Mount Pods. To switch modes:
315329

316330
1. Update ConfigMap with new configuration
317331
2. Delete existing PVCs (ensure data is backed up)
@@ -322,6 +336,7 @@ Existing PVCs continue using their current mount pods. To switch modes:
322336
### From Environment Variables to ConfigMap
323337

324338
1. Create ConfigMap with current behavior:
339+
325340
```yaml
326341
apiVersion: v1
327342
kind: ConfigMap
@@ -334,27 +349,28 @@ data:
334349
```
335350
336351
2. Deploy ConfigMap:
352+
337353
```bash
338354
kubectl apply -f juicefs-mount-config.yaml
339355
```
340356

341357
3. New PVCs will use ConfigMap configuration
342-
4. Optionally remove environment variables from CSI driver
358+
4. Optionally remove environment variables from CSI Driver
343359

344360
### From Per-PVC to Shared/DaemonSet
345361

346362
1. Update ConfigMap for specific StorageClasses
347363
2. New PVCs use new mode automatically
348-
3. Optionally migrate existing PVCs during maintenance windows
364+
3. Optionally migrate existing PVCs during maintenance Windows
349365

350366
## Summary
351367

352-
The mount pod configuration system provides:
368+
The Mount Pod configuration system provides:
353369

354370
- **Flexibility**: Different modes for different workloads
355371
- **Compatibility**: Works with existing StorageClasses
356372
- **Simplicity**: Centralized configuration via ConfigMap
357373
- **Power**: Fine-grained control with node affinity
358374
- **Safety**: Non-disruptive to existing workloads
359375

360-
Choose the appropriate mode based on your workload requirements, resource constraints, and operational preferences.
376+
Choose the appropriate mode based on your workload requirements, resource constraints, and operational preferences.

0 commit comments

Comments
 (0)