forked from hwameistor/hwameistor
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request hwameistor#130 from alexzhc/main
[doc] update "configure storage pool"
- Loading branch information
Showing
27 changed files
with
1,007 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
--- | ||
sidebar_position: 4 | ||
sidebar_label: "Configure Storage Pool" | ||
--- | ||
|
||
# Configure Storage Pool | ||
|
||
## Step 1: Create LocalDiskClaim objects | ||
|
||
HwameiStor sets up storage pools by creating `LocalDiskClaim` objects according to the storage media types. To create an HDD pool on all kubernetes worker nodes: | ||
|
||
```bash | ||
$ helm template helm/hwameistor \ | ||
-s templates/post-install-claim-disks.yaml \ | ||
--set storageNodes='{k8s-worker-1,k8s-worker-2,k8s-worker-3}' \ | ||
| kubectl apply -f - | ||
``` | ||
|
||
## Step 2: Verify LocalDiskClaim objects | ||
|
||
```bash | ||
$ kubectl get ldc | ||
NAME NODEMATCH PHASE | ||
k8s-worker-1 k8s-worker-1 Bound | ||
k8s-worker-2 k8s-worker-2 Bound | ||
k8s-worker-3 k8s-worker-3 Bound | ||
``` | ||
|
||
## Step 3: Verify StorageClass | ||
|
||
```bash | ||
$ kubectl get sc hwameistor-storage-lvm-hdd | ||
NAME PROVISIONER RECLAIMPOLICY VOLUMEBINDINGMODE ALLOWVOLUMEEXPANSION AGE | ||
hwameistor-storage-lvm-hdd lvm.hwameistor.io Delete WaitForFirstConsumer true 114s | ||
``` | ||
|
||
## Step 4: Verify LocalDisk objects | ||
|
||
```bash | ||
$ kubectl get ld | ||
NAME NODEMATCH CLAIM PHASE | ||
k8s-worker-1-sda k8s-worker-1 Inuse | ||
k8s-worker-1-sdb k8s-worker-1 k8s-worker-1 Claimed | ||
k8s-worker-1-sdc k8s-worker-1 k8s-worker-1 Claimed | ||
k8s-worker-1-sdd k8s-worker-1 Inuse | ||
k8s-worker-1-sde k8s-worker-1 Inuse | ||
k8s-worker-2-sda k8s-worker-2 Inuse | ||
k8s-worker-2-sdb k8s-worker-2 k8s-worker-2 Claimed | ||
k8s-worker-2-sdc k8s-worker-2 k8s-worker-2 Claimed | ||
k8s-worker-2-sdd k8s-worker-2 Inuse | ||
k8s-worker-2-sde k8s-worker-2 Inuse | ||
k8s-worker-3-sda k8s-worker-3 Inuse | ||
k8s-worker-3-sdb k8s-worker-3 k8s-worker-3 Claimed | ||
k8s-worker-3-sdc k8s-worker-3 k8s-worker-3 Claimed | ||
k8s-worker-3-sdd k8s-worker-3 Inuse | ||
k8s-worker-3-sde k8s-worker-3 Inuse | ||
``` | ||
|
||
## Step 5 (Optional): Observe VG | ||
|
||
On a kubernetes worker node, observe a `VG` is created for an `LocalDiskClaim` object | ||
|
||
```bash | ||
root@k8s-worker-1:~$ vgdisplay LocalStorage_PoolHDD | ||
--- Volume group --- | ||
VG Name LocalStorage_PoolHDD | ||
System ID | ||
Format lvm2 | ||
Metadata Areas 2 | ||
Metadata Sequence No 1 | ||
VG Access read/write | ||
VG Status resizable | ||
MAX LV 0 | ||
Cur LV 0 | ||
Open LV 0 | ||
Max PV 0 | ||
Cur PV 2 | ||
Act PV 2 | ||
VG Size 199.99 GiB | ||
PE Size 4.00 MiB | ||
Total PE 51198 | ||
Alloc PE / Size 0 / 0 | ||
Free PE / Size 51198 / 199.99 GiB | ||
VG UUID jJ3s7g-iyoJ-c4zr-3Avc-3K4K-BrJb-A5A5Oe | ||
``` | ||
|
||
## Set up storage pool during deployment | ||
|
||
A storage pool can be configured during HwameiStor deployment by helm command: | ||
|
||
```bash | ||
$ helm install \ | ||
--namespace hwameistor \ | ||
--create-namespace \ | ||
hwameistor \ | ||
helm/hwameistor \ | ||
--set storageNodes='{k8s-worker-1,k8s-worker-2,k8s-worker-3}' | ||
``` |
2 changes: 1 addition & 1 deletion
2
docs/docs/01.installation/03.upgrade.md → docs/docs/01.installation/04.upgrade.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
sidebar_position: 4 | ||
sidebar_position: 5 | ||
sidebar_label: "Upgrade" | ||
--- | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"label": "Modules", | ||
"position": 5 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
98 changes: 98 additions & 0 deletions
98
...18n/cn/docusaurus-plugin-content-docs/current/01.installation/03.config-pool.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,98 @@ | ||
--- | ||
sidebar_position: 4 | ||
sidebar_label: "配置存储池" | ||
--- | ||
|
||
# Configure Storage Pool | ||
|
||
## Step 1: Create LocalDiskClaim objects | ||
|
||
HwameiStor sets up storage pools by creating `LocalDiskClaim` objects according to the storage media types. To create an HDD pool on all kubernetes worker nodes: | ||
|
||
```bash | ||
$ helm template helm/hwameistor \ | ||
-s templates/post-install-claim-disks.yaml \ | ||
--set storageNodes='{k8s-worker-1,k8s-worker-2,k8s-worker-3}' \ | ||
| kubectl apply -f - | ||
``` | ||
|
||
## Step 2: Verify LocalDiskClaim objects | ||
|
||
```bash | ||
$ kubectl get ldc | ||
NAME NODEMATCH PHASE | ||
k8s-worker-1 k8s-worker-1 Bound | ||
k8s-worker-2 k8s-worker-2 Bound | ||
k8s-worker-3 k8s-worker-3 Bound | ||
``` | ||
|
||
## Step 3: Verify StorageClass | ||
|
||
```bash | ||
$ kubectl get sc hwameistor-storage-lvm-hdd | ||
NAME PROVISIONER RECLAIMPOLICY VOLUMEBINDINGMODE ALLOWVOLUMEEXPANSION AGE | ||
hwameistor-storage-lvm-hdd lvm.hwameistor.io Delete WaitForFirstConsumer true 114s | ||
``` | ||
|
||
## Step 4: Verify LocalDisk objects | ||
|
||
```bash | ||
$ kubectl get ld | ||
NAME NODEMATCH CLAIM PHASE | ||
k8s-worker-1-sda k8s-worker-1 Inuse | ||
k8s-worker-1-sdb k8s-worker-1 k8s-worker-1 Claimed | ||
k8s-worker-1-sdc k8s-worker-1 k8s-worker-1 Claimed | ||
k8s-worker-1-sdd k8s-worker-1 Inuse | ||
k8s-worker-1-sde k8s-worker-1 Inuse | ||
k8s-worker-2-sda k8s-worker-2 Inuse | ||
k8s-worker-2-sdb k8s-worker-2 k8s-worker-2 Claimed | ||
k8s-worker-2-sdc k8s-worker-2 k8s-worker-2 Claimed | ||
k8s-worker-2-sdd k8s-worker-2 Inuse | ||
k8s-worker-2-sde k8s-worker-2 Inuse | ||
k8s-worker-3-sda k8s-worker-3 Inuse | ||
k8s-worker-3-sdb k8s-worker-3 k8s-worker-3 Claimed | ||
k8s-worker-3-sdc k8s-worker-3 k8s-worker-3 Claimed | ||
k8s-worker-3-sdd k8s-worker-3 Inuse | ||
k8s-worker-3-sde k8s-worker-3 Inuse | ||
``` | ||
|
||
## Step 5 (Optional): Observe VG | ||
|
||
On a kubernetes worker node, observe a `VG` is created for an `LocalDiskClaim` object | ||
|
||
```bash | ||
root@k8s-worker-1:~$ vgdisplay LocalStorage_PoolHDD | ||
--- Volume group --- | ||
VG Name LocalStorage_PoolHDD | ||
System ID | ||
Format lvm2 | ||
Metadata Areas 2 | ||
Metadata Sequence No 1 | ||
VG Access read/write | ||
VG Status resizable | ||
MAX LV 0 | ||
Cur LV 0 | ||
Open LV 0 | ||
Max PV 0 | ||
Cur PV 2 | ||
Act PV 2 | ||
VG Size 199.99 GiB | ||
PE Size 4.00 MiB | ||
Total PE 51198 | ||
Alloc PE / Size 0 / 0 | ||
Free PE / Size 51198 / 199.99 GiB | ||
VG UUID jJ3s7g-iyoJ-c4zr-3Avc-3K4K-BrJb-A5A5Oe | ||
``` | ||
|
||
## Configure storage pool during deployment | ||
|
||
A storage pool can be configured during HwameiStor deployment by helm command: | ||
|
||
```bash | ||
$ helm install \ | ||
--namespace hwameistor \ | ||
--create-namespace \ | ||
hwameistor \ | ||
helm/hwameistor \ | ||
--set storageNodes='{k8s-worker-1,k8s-worker-2,k8s-worker-3}' | ||
``` |
2 changes: 1 addition & 1 deletion
2
...ocs/current/01.installation/03.upgrade.md → ...ocs/current/01.installation/04.upgrade.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
sidebar_position: 4 | ||
sidebar_position: 5 | ||
sidebar_label: "升级" | ||
--- | ||
|
||
|
2 changes: 1 addition & 1 deletion
2
...s/current/01.installation/04.uninstall.md → ...s/current/01.installation/05.uninstall.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
--- | ||
sidebar_position: 5 | ||
sidebar_position: 6 | ||
sidebar_label: "卸载" | ||
--- | ||
|
||
|
4 changes: 0 additions & 4 deletions
4
docs/i18n/cn/docusaurus-plugin-content-docs/current/04.components/_category_.json
This file was deleted.
Oops, something went wrong.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 4 additions & 0 deletions
4
docs/i18n/cn/docusaurus-plugin-content-docs/current/04.modules/_category_.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
{ | ||
"label": "模块", | ||
"position": 5 | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,19 @@ | ||
{{- if .Values.storageclass.enabled -}} | ||
{{- if .Values.storageClass.enabled -}} | ||
apiVersion: storage.k8s.io/v1 | ||
kind: StorageClass | ||
metadata: | ||
annotations: | ||
storageclass.kubernetes.io/is-default-class: {{ .Values.storageclass.default | quote }} | ||
name: hwameistor-storage-lvm-{{ .Values.storageclass.diskType | lower}} | ||
storageClass.kubernetes.io/is-default-class: {{ .Values.storageClass.default | quote }} | ||
name: hwameistor-storage-lvm-{{ .Values.storageClass.diskType | lower}} | ||
provisioner: lvm.hwameistor.io | ||
volumeBindingMode: WaitForFirstConsumer | ||
allowVolumeExpansion: {{ .Values.storageclass.allowVolumeExpansion }} | ||
reclaimPolicy: {{ .Values.storageclass.reclaimPolicy }} | ||
allowVolumeExpansion: {{ .Values.storageClass.allowVolumeExpansion }} | ||
reclaimPolicy: {{ .Values.storageClass.reclaimPolicy }} | ||
parameters: | ||
replicaNumber: {{ .Values.storageclass.replicaNumber | quote}} | ||
poolClass: {{ .Values.storageclass.diskType | quote}} | ||
replicaNumber: {{ .Values.storageClass.replicaNumber | quote}} | ||
poolClass: {{ .Values.storageClass.diskType | quote}} | ||
poolType: "REGULAR" | ||
volumeKind: "LVM" | ||
striped: "true" | ||
csi.storage.k8s.io/fstype: {{ .Values.storageclass.fsType | quote}} | ||
csi.storage.k8s.io/fstype: {{ .Values.storageClass.fsType | quote}} | ||
{{- end }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.