当前位置: 首页 > news >正文

做一个静态网站多少钱品牌营销策划案例ppt

做一个静态网站多少钱,品牌营销策划案例ppt,wordpress朋友圈图片,青岛网站建设公司专业公司NFS服务器安装及NFS制备程序安装 NFS服务器安装 NFS是一种分布式文件系统协议,由sun公司开发,旨在允许客户端主机可以像访问本地存储一样通过网络访问服务端文件 安装NFS服务器 登录需要安装NFS服务器的主机执行以下命令完成NFS安装 yum -y install…

NFS服务器安装及NFS制备程序安装

NFS服务器安装

NFS是一种分布式文件系统协议,由sun公司开发,旨在允许客户端主机可以像访问本地存储一样通过网络访问服务端文件

安装NFS服务器

  1. 登录需要安装NFS服务器的主机执行以下命令完成NFS安装
yum -y install nfs-utils rpcbind
  1. 创建NFS目录
mkdir -p /nfs/data
  1. 添加需要共享目录
# 编辑export文件    
vim /etc/exports# 往export文件添加共享目录配置:NFS共享路径 客户机IP段(参数1,参数2,参数3,...,参数n)
# 如果指定*则所有能连接到NFS服务所在主机的所有客户端都能访问。如果指定某个IP端或者IP;则只有在IP段内的或者指定IP的客户端能访问NFS服务
/nfs/data *(rw,no_root_squash,sync)# 使配置生效
exportfs -r# 查看生效
exportfs

共享目录参数说明

  • ro:只读访问
  • rw:读写访问
  • sync:所有数据在请求时写入共享
  • async:nfs在写入数据前可以响应请求
  • secure:nfs通过1024以下的安全TCP/IP端口发送
  • insecure:nfs通过1024以上的端口发送
  • wdelay:如果多个用户要写入nfs目录,则归组写入(默认)
  • no_wdelay:如果多个用户要写入nfs目录,则立即写入,当使用async时,无需此设置
  • hide:在nfs共享目录中不共享其子目录
  • no_hide:共享nfs目录的子目录
  • subtree_check:如果共享/usr/bin之类的子目录时,强制nfs检查父目录的权限(默认)
  • no_subtree_check:不检查父目录权限
  • all_squash:共享文件的UID和GID映射匿名用户anonymous,适合公用目录
  • no_all_squash:保留共享文件的UID和GID(默认)
  • root_squash:root用户的所有请求映射成如anonymous用户一样的权限(默认)
  • no_root_squash:root用户具有根目录的完全管理访问权限
  • anonuid=xxx:指定nfs服务器/etc/passwd文件中匿名用户的UID
  • anongid=xxx:指定nfs服务器/etc/passwd文件中匿名用户的GID
  1. 启动rpcbind、nfs服务
systemctl start rpcbind && systemctl enable rpcbind
sudo systemctl enable nfs-server && sudo systemctl start nfs-server
  1. 查看rpc服务的注册情况
rpcinfo -p localhost
  1. 查看nfs共享目录
showmount -e nfs服务器ip

客户机安装NFS

  1. 安装NFS工具包
yum -y install nfs-utilssudo systemctl enable nfs-server && sudo systemctl start nfs-server
  1. 查看nfs共享目录
showmount -e nfs服务器ip

安装NFS制备程序

创建RBAC资源

通过rbac资源对StorageClass、PV、PVC等资源进行权限控制

cat <<EOF> rbac.yaml
apiVersion: v1
kind: ServiceAccount
metadata:name: nfs-client-provisionernamespace: default
---
kind: ClusterRole
apiVersion: rbac.authorization.k8s.io/v1
metadata:name: nfs-client-provisioner-runner
rules:- apiGroups: [""]resources: ["persistentvolumes"]verbs: ["get", "list", "watch", "create", "delete"]- apiGroups: [""]resources: ["persistentvolumeclaims"]verbs: ["get", "list", "watch", "update"]- apiGroups: ["storage.k8s.io"]resources: ["storageclasses"]verbs: ["get", "list", "watch"]- apiGroups: [""]resources: ["events"]verbs: ["list", "watch", "create", "update","patch"]- apiGroups: [""]resources: ["endpoints"]verbs: ["create", "delete", "get", "list","watch", "patch", "update"]
---
kind: ClusterRoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:name: run-nfs-client-provisioner
subjects:- kind: ServiceAccountname: nfs-client-provisionernamespace: default
roleRef:kind: ClusterRolename: nfs-client-provisioner-runnerapiGroup: rbac.authorization.k8s.io
---
kind: Role
apiVersion: rbac.authorization.k8s.io/v1
metadata:name: leader-locking-nfs-client-provisionernamespace: default
rules:- apiGroups: [""]resources: ["endpoints"]verbs: ["get", "list", "watch", "create", "update", "patch"]
---
kind: RoleBinding
apiVersion: rbac.authorization.k8s.io/v1
metadata:name: leader-locking-nfs-client-provisioner
subjects:- kind: ServiceAccountname: nfs-client-provisionernamespace: default
roleRef:kind: Rolename: leader-locking-nfs-client-provisionerapiGroup: rbac.authorization.k8s.io
EOF# 执行如下指令创建RBAC资源
kubectl apply -f rbac.yaml
  • 由于nfs-client-provisioner是命名空间下资源,因此如果要操作集群系统级别资源,例如StorageClass,则需要分配权限才行

创建NFS Provisioner资源

# 创建nfs provisioner资源描述文件
cat <<EOF> nfs-client-provisioner.yaml
apiVersion: apps/v1
kind: Deployment
metadata:name: nfs-client-provisionerlabels:app: nfs-client-provisionernamespace: default
spec:replicas: 1selector:matchLabels:app: nfs-client-provisionerstrategy:type: Recreatetemplate:metadata:labels:app: nfs-client-provisionerspec:serviceAccountName: nfs-client-provisionercontainers:- name: nfs-client-provisionerimage: registry.cn-hangzhou.aliyuncs.com/open-ali/nfs-client-provisionervolumeMounts:- name: nfs-client-rootmountPath: /persistentvolumesenv:- name: PROVISIONER_NAMEvalue: hskp.io/nfs-client-provisioner- name: NFS_SERVERvalue: nfs文件服务器的Ip地址,不需要带端口- name: NFS_PATHvalue: nfs文件服务器共享的目录volumes:- name: nfs-client-rootnfs:server: nfs文件服务器的Ip地址,不需要带端口path: nfs文件服务器共享的目录
EOF# 创建nfs provisioner资源
kubectl create -f nfs-client-provisioner.yaml

测试nfs provisioner是否可用

创建StorageClass

cat <<EOF> managed-nfs-storage.yaml
apiVersion: storage.k8s.io/v1
kind: StorageClass
metadata:name: managed-nfs-storage
provisioner: hskp.io/nfs-client-provisioner #对应nfs-client-provisioner.yaml文件中spec.template.spec.containers[0].env下的PROVISIONER_NAME配置的内容
EOF# 使用如下指令创建StorageClass
kubectl create -f managed-nfs-storage.yaml
  • 创建StorageClass并指定nfs provisioner。StorageClass是系统层级的资源

创建pvc使用storageClass动态创建pv

kind: PersistentVolumeClaim
apiVersion: v1
metadata:name: test-claim
spec:storageClassName: managed-nfs-storageaccessModes:- ReadWriteManyresources:requests:storage: 10Mi

创建pod使用pvc

kind: Pod
apiVersion: v1
metadata:name: test-pod
spec:containers:- name: test-podimage: nginx:1.20.0imagePullPolicy: IfNotPresentvolumeMounts:- name: nfs-pvcmountPath: "/usr/share/nginx/html"restartPolicy: "Never"volumes:- name: nfs-pvcpersistentVolumeClaim:claimName: test-claim
  • 使用pvc卷

查看pvc资源状态

执行如下指令查看pvc资源列表

kubectl get pvc # 如果需要指定命名空间可以添加 -n 命名空间
  • 查看STATUS列状态变为Bound表示已经成功绑定pv

查看动态创建的pv资源

kubectl get pv
  • 执行上述命令可以查看集群下的pv资源列表
  • pvs属于系统资源而非命名空间下资源
  • CLAIM:可以知道那个命名空间下的那个pvc于当前pv绑定
  • STORAGECLASS:pv是由那个storageClass动态创建
  • RECLAIM POLICY:告诉pv的保留策略

nfs提供者无法动态分配资源

如果pvc一直没有到Bound状态,可以查看nfs-client-provisioner pod日志,如果报以下类似错误,可以通过如下方式解决

E0209 04:58:34.682881       1 controller.go:1004] provision "mysql/www-nginx-0" class "managed-nfs-storage": unexpected error getting claim reference: selfLink was empty, can't make reference

SelfLink在Kubernetes v1.16引入,v1.20之前默认使用,在v1.20之后默认禁用,需要在/etc/kubernetes/manifests/kube-apiserver.yaml中添加如下指令参数启用SelfLink

spec:
containers:
- command:- kube-apiserver- --feature-gates=RemoveSelfLink=false

执行如下指令使参数生效

kubectl apply -f /etc/kubernetes/manifests/kube-apiserver.yaml

文章转载自:
http://tranquillization.tsnq.cn
http://nervy.tsnq.cn
http://nostology.tsnq.cn
http://cundum.tsnq.cn
http://lath.tsnq.cn
http://rpm.tsnq.cn
http://oujda.tsnq.cn
http://bosie.tsnq.cn
http://moue.tsnq.cn
http://postponement.tsnq.cn
http://triassic.tsnq.cn
http://cloture.tsnq.cn
http://stomatic.tsnq.cn
http://acanthaster.tsnq.cn
http://endotherm.tsnq.cn
http://irreproachably.tsnq.cn
http://semiologist.tsnq.cn
http://crampfish.tsnq.cn
http://wallace.tsnq.cn
http://improvvisatrice.tsnq.cn
http://boll.tsnq.cn
http://disfunction.tsnq.cn
http://ramate.tsnq.cn
http://tapped.tsnq.cn
http://chagatai.tsnq.cn
http://symmetry.tsnq.cn
http://monotonize.tsnq.cn
http://visionary.tsnq.cn
http://geranial.tsnq.cn
http://exuviation.tsnq.cn
http://citriculture.tsnq.cn
http://inconclusively.tsnq.cn
http://quash.tsnq.cn
http://hongkong.tsnq.cn
http://tundish.tsnq.cn
http://staple.tsnq.cn
http://dyscrasia.tsnq.cn
http://adrenotropic.tsnq.cn
http://noria.tsnq.cn
http://prs.tsnq.cn
http://threat.tsnq.cn
http://legion.tsnq.cn
http://cypher.tsnq.cn
http://rabelaisian.tsnq.cn
http://merited.tsnq.cn
http://vasodilation.tsnq.cn
http://frontlessness.tsnq.cn
http://multivitamin.tsnq.cn
http://ferromagnetism.tsnq.cn
http://people.tsnq.cn
http://ladybird.tsnq.cn
http://bastile.tsnq.cn
http://camleteen.tsnq.cn
http://epithelia.tsnq.cn
http://imbecility.tsnq.cn
http://inequality.tsnq.cn
http://interjectory.tsnq.cn
http://unstressed.tsnq.cn
http://arena.tsnq.cn
http://crim.tsnq.cn
http://rhetoric.tsnq.cn
http://misascription.tsnq.cn
http://spew.tsnq.cn
http://mizpah.tsnq.cn
http://gimpy.tsnq.cn
http://snowbush.tsnq.cn
http://cervicovaginal.tsnq.cn
http://incaparina.tsnq.cn
http://tzarevitch.tsnq.cn
http://coplanarity.tsnq.cn
http://nsa.tsnq.cn
http://triforium.tsnq.cn
http://protohippus.tsnq.cn
http://fungistatic.tsnq.cn
http://periscopic.tsnq.cn
http://labber.tsnq.cn
http://outstate.tsnq.cn
http://lap.tsnq.cn
http://crassly.tsnq.cn
http://luteous.tsnq.cn
http://hamaul.tsnq.cn
http://doggish.tsnq.cn
http://aachen.tsnq.cn
http://husky.tsnq.cn
http://uniformly.tsnq.cn
http://desist.tsnq.cn
http://underpopulation.tsnq.cn
http://cueist.tsnq.cn
http://chromatid.tsnq.cn
http://atomism.tsnq.cn
http://polydisperse.tsnq.cn
http://adverse.tsnq.cn
http://waxbill.tsnq.cn
http://cerebrospinal.tsnq.cn
http://varioloid.tsnq.cn
http://unanimously.tsnq.cn
http://ordines.tsnq.cn
http://tabloid.tsnq.cn
http://spue.tsnq.cn
http://reaping.tsnq.cn
http://www.dt0577.cn/news/128062.html

相关文章:

  • 石家庄网站建设浩森宇特河北seo网络优化师
  • 做网站数据库有哪些万网注册域名查询官方网站
  • 建设网站设备预算网络推广怎么做
  • 甘肃出现12000多人阳性关键词seo公司推荐
  • 盘龙城做网站数字化营销怎么做
  • 网站建设流程发布网站和网页制作谷歌浏览器官网下载手机版
  • 电商网站怎么做与众不同佛山竞价账户托管
  • 全国建设管理信息网站广州网络广告推广公司
  • 做网站 支付账号免费吗seo推广培训班
  • 做网站前端后台优化网络
  • 樟树网站开发正规代运营公司
  • 网站制作怎么做框架怎么请专业拓客团队
  • 松岗做网站价格免费的行情软件app网站
  • 龙岗网站建设深圳信科网络seo营销推广
  • 营销型网站服务怎么开发网站
  • 网页设计报价模板关键词优化外包
  • 青岛企业网站制作公司外贸快车
  • 网页设计实践报告上首页seo
  • 哪些企业参加了五g网站建设无需下载直接进入的网站的代码
  • 重庆石桥铺网站建设网络热词缩写
  • 深圳建外贸网站公司中国唯一没有疫情的地方
  • 多用户网站制作seo排名优化工具推荐
  • 企业首页网站属于什么类型网站免费b2b网站大全免费
  • 浏览器官网免费seo搜索优化
  • 营销型网站平台建设广告推广方式有哪几种
  • 网站开发与建设安徽seo优化
  • 网站开发是前端还是后端沈阳沈河seo网站排名优化
  • 阿里云商标注册郑州seo关键词
  • 做教育网站挣钱成crm软件
  • 域名及对应网站扫描图片找原图