centos安装nfs服务

发表于 LINUX 分类,标签:


yum -y install nfs-utils



vim /etc/exports

/data/k8s/es0    10.10.0.0/16(insecure,rw,async,no_root_squash) 172.16.5.1/24(insecure,rw,async,no_root_squash)

/data/k8s/es1    10.10.0.0/16(insecure,rw,async,no_root_squash) 172.16.5.1/24(insecure,rw,async,no_root_squash)

/data/k8s/es2    10.10.0.0/16(insecure,rw,async,no_root_squash) 172.16.5.1/24(insecure,rw,async,no_root_squash)


systemctl start nfs


netstat -ultnp | grep 2049


showmount -e 172.16.5.178




如果是已经启动之后,修改了 /etc/exports 


执行exportfs -arv

这样的话就无需重启nfs服务






helm repo add nfs-subdir-external-provisioner https://kubernetes-sigs.github.io/nfs-subdir-external-provisioner


helm install nfs-subdir-external-provisioner nfs-subdir-external-provisioner/nfs-subdir-external-provisioner \

    --set storageClass.name=nfs-sc-default

    --set nfs.server=172.16.1.249 \

    --set nfs.path=/data/tekton \

    --set storageClass.defaultClass=true \

    -n nfs




https://www.cnblogs.com/cerberus43/p/15880234.html


0 篇评论

发表我的评论