![](https://img-blog.csdnimg.cn/25941515384348da9684892f2eca3242.jpeg?x-oss-process=image/resize,m_fixed,h_224,w_224)
k8s
文章平均质量分 56
k8s
王Sir_yt
静以修身,俭以养德。
展开
-
KubeSphere金丝雀发布流量分布调节不生效(将所有流量按比例分配给灰度发布版本)
如题 金丝雀发布按照流量比例访问不能生效。原创 2023-12-22 09:28:47 · 407 阅读 · 0 评论 -
记录k8s kube-controller-manager-k8s-master kube-scheduler-k8s-master重启
Name:kube-controller-manager,Attempt"caller":"etcdserver/util.go:170","msg":"apply request took too long","took""retry-timeout":"500ms"原创 2023-05-29 10:19:03 · 1950 阅读 · 0 评论 -
k8s安装top命令,kubectl top node,试过很多,这个一次性过。
1,cat components.yamlapiVersion: v1kind: ServiceAccountmetadata: labels: k8s-app: metrics-server name: metrics-server namespace: kube-system---apiVersion: rbac.authorization.k8s.io/v1kind: ClusterRolemetadata: labels: k8s-app: metr原创 2021-12-07 11:53:24 · 4347 阅读 · 5 评论 -
Docker Registry搭建私有镜像仓库(干货)http/https
########先安装docker,此处不做叙述#########1、docker pull registry2、docker run -d -v /opt/registry:/var/lib/registry -p 5000:5000 --restart=always --name registry registry:latest参数说明 -d:在后台运行; -v:把宿主机的/opt/registry目录绑到容器/var/lib/registry目录(这个目录是registry容器中.原创 2021-05-26 18:48:29 · 1016 阅读 · 0 评论 -
K8s版本升级
k8s升級 1.14.1>>>>>>1.15.3配置yum源[root@master images]# cat /etc/yum.repos.d/kubernetes.repo[kubernetes]name=Kubernetesbaseurl=https://mirrors.aliyun.com/kubernetes/yum/repos/kubernetes-el7-x86_64/enabled=1gpgcheck=0repo_gpgc.原创 2020-12-30 10:24:54 · 1558 阅读 · 0 评论 -
k8s高可用多节点master搭建
建议master数量为奇数个(本章以测试为主,双节点测试,可以加相应IP)搭建环境请参照之前文章架构:master1 10.194.28.104master2 10.194.28.110虚拟ip 10.194.28.222A <1>节点安装 keepalivedyum install -y socat keepalived ipvsadm conntrack<2> 配置[root@master1 ~]# cat /etc...原创 2020-06-05 10:08:15 · 2040 阅读 · 0 评论 -
k8s中使用rsync同步备份目录(本文旨在了解,建议使用nfs定期备份)
两台安装yum -y install rsync 测试备份/var/lib/kubelet目录(此方法为两目录一定时间同步,建议使用脚本定期复制到nfs,可参考之前文章 k8s的备份与还原里面的手动备份。)a 1 cat /etc/rsyncd.confpid file=/var/run/rsyncd.pidport=873address=10.194.28.104uid=rootgid=rootread only=yeshosts allow=10.194.28.110hosts .原创 2020-05-24 08:07:46 · 838 阅读 · 0 评论 -
K8s rbac namespace权限设置
在K8S master节点上创建Role和RoleBinding的yaml文件#vi role-username.yamlkind: RoleapiVersion: rbac.authorization.k8s.io/v1metadata: namespace: default name: pod-readerrules:- apiGroups: [""] resources: ["pods"] verbs: ["get", "watch", "list","...原创 2020-05-24 07:36:50 · 1185 阅读 · 0 评论 -
k8s中docker设置代理
mkdir -p /etc/systemd/system/docker.service.dvi /etc/systemd/system/docker.service.d/http-proxy.conf[Service]Environment="HTTP_PROXY=http://10.194.*.*:808" "NO_PROXY=localhost,127.0.0.1,10.192.*.1*"systemctl daemon-reloadsystemctl restart dockersys原创 2020-05-14 10:41:50 · 1476 阅读 · 0 评论 -
k8s单节点备份及还原
A、yum –y install etcd etcdctl –v 查看etc版本建議备份 /var/lib/etcd /etc/kubernetes/查看文件位置及Livenesskubectl describe pod etcd-master-test –n kube-system > etcd.txt ETCDCTL_API=3 etcdctl –endpoin...原创 2020-05-06 08:31:48 · 618 阅读 · 0 评论 -
K8s nfs挂载 PV PVC
apiVersion: v1kind: Podmetadata: name: httpdspec: containers: - image: httpd name: httpd volumeMounts: - name: httpd-data mountPath: /nfs/httpd/data ports: - contain...原创 2020-04-11 11:35:32 · 1240 阅读 · 0 评论 -
k8s安裝dashboard
官方參考https://kubernetes.io/docs/tasks/access-application-cluster/web-ui-dashboard/wget https://raw.githubusercontent.com/kubernetes/dashboard/v2.0.0-beta8/aio/deploy/recommended.yaml修改Servicespec...原创 2020-03-30 11:46:23 · 425 阅读 · 0 评论 -
docker 搭建 harbor私有库
1、安装python-pipyum-yinstallepel-releaseyum-yinstallpython-pip2、安装docker-composeyum -y install epel-releaseyum -y install python-pippip install --upgrade pipyum -y install gccyum i...原创 2020-03-30 08:45:11 · 158 阅读 · 0 评论 -
K8s现有集群新增node节点
node节点前期部署环境略过,从kubectl join开始#kubeadm token create token 在master上重新获取token(原token失效)#openssl x509 -pubkey -in /etc/kubernetes/pki/ca.crt | openssl rsa -pubin -outform der 2>/dev/null | openssl...原创 2020-03-28 15:42:50 · 600 阅读 · 0 评论 -
k8s搭建整理------从零到整 docker代理
参考网址,感谢Centoshttps://blog.csdn.net/wo18237095579/article/details/89638901docker添加网络代理(node节点也要添加)Centos7https://blog.csdn.net/MaxWoods/article/details/89464002...原创 2019-11-30 14:54:13 · 198 阅读 · 0 评论