安装使用流程
1. 创建命名空间
$ kubectl create ns fluid-system
2. 下载 fluid
3. 使用 Helm 安装 Fluid
$ helm install --set runtime.goosefs.enabled=true fluid fluid-0.8.0.tgz
4. 查看 Fluid 的运行状态
$ kubectl get pod -n fluid-systemNAME READY STATUS RESTARTS AGEcsi-nodeplugin-fluid-2mfcr 2/2 Running 0 108scsi-nodeplugin-fluid-l7lv6 2/2 Running 0 108sdataset-controller-5465c4bbf9-5ds5p 1/1 Running 0 108sgoosefsruntime-controller-654fb74447-cldsv 1/1 Running 0 108s
其中,csi-nodeplugin-fluid-xx 的数量应该与 k8s 集群中节点 node 的数量相同。
到此 Fluid 已成功安装,如需自定义镜像和升级系统 crd 请参考如下说明(可选)。
5. 自定义镜像
解压
fluid-0.8.0.tgz
,修改默认values.yaml
文件:runtime:mountRoot: /runtime-mntgoosefs:runtimeWorkers: 3portRange: 26000-32000enabled: falseinit:image: fluidcloudnative/init-users:v0.8.0-116a5becontroller:image: fluidcloudnative/goosefsruntime-controller:v0.8.0-116a5beruntime:image: ccr.ccs.tencentyun.com/qcloud/goosefs:v1.2.0fuse:image: ccr.ccs.tencentyun.com/qcloud/goosefs:v1.2.0
您可以修改
goosefs
相关的默认 image
内容,如放到自己的 repo
上。待修改完成后,重新使用 helm package fluid
打包,并使用如下命令,更新fluid
版本。helm upgrade --install fluid fluid-0.8.0.tgz
6. 更新 crd
$ kubectl get crdNAME CREATED ATdatabackups.data.fluid.io 2021-03-02T13:12:31Zdataloads.data.fluid.io 2021-04-14T11:14:58Zdatasets.data.fluid.io 2021-03-02T13:12:31Zgoosefsruntimes.data.fluid.io 2021-04-13T13:31:38Z
例如,更新系统中已有的
goosefsruntime
的 crd。首先删除已有的 crd:
kubectl delete crd goosefsruntimes.data.fluid.io
然后解压
fluid-0.8.0.tgz
:$ ls -l fluid/total 32total 32-rw-r--r-- 1 xieydd staff 489 5 15 16:14 CHANGELOG.md-rw-r--r-- 1 xieydd staff 1061 7 22 00:08 Chart.yaml-rw-r--r-- 1 xieydd staff 2560 5 15 16:14 VERSIONdrwxr-xr-x 8 xieydd staff 256 7 20 15:06 crdsdrwxr-xr-x 7 xieydd staff 224 5 24 14:18 templates-rw-r--r-- 1 xieydd staff 1665 7 22 00:08 values.yaml
最后创建新的 crd:
kubectl apply -f crds/data.fluid.io_goosefsruntimes.yaml
?