{"id":6068,"date":"2024-08-01T22:47:40","date_gmt":"2024-08-01T14:47:40","guid":{"rendered":"https:\/\/xinchewhd.com.cn\/?p=6068"},"modified":"2024-08-01T22:47:40","modified_gmt":"2024-08-01T14:47:40","slug":"k8s%e5%8d%95%e6%9c%ba%e6%9e%b6%e6%9e%84%e9%83%a8%e7%bd%b2","status":"publish","type":"post","link":"https:\/\/xinchewhd.com.cn\/index.php\/k8s\/k8s%e5%8d%95%e6%9c%ba%e6%9e%b6%e6%9e%84%e9%83%a8%e7%bd%b2\/","title":{"rendered":"K8s\u5355\u673a\u67b6\u6784\u90e8\u7f72"},"content":{"rendered":"<div class='wxsyncmain'>\n<p cid=\"n0\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\"> \u8fd9\u662f\u6211\u505a\u4e86\u5f88\u591a\u904d\uff0c\u53c2\u8003\u5f88\u591a\u6587\u7ae0\u5f97\u5230\u7684\uff0c\u4e3a\u4e86\u4fbf\u4e8e\u5927\u5bb6\u53c2\u8003\u548c\u5b66\u4e60\uff0c\u6211\u5df2\u7ecf\u628a\u6bcf\u4e00\u6b65\u90fd\u6574\u7406\u51fa\u6765\u4e86\uff0c\u6b65\u9aa4\u548c\u63d0\u793a\u90fd\u5f88\u6e05\u6670\u3002<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\"> \u540e\u7eed\u6587\u6863\u6709\u4ec0\u4e48\u95ee\u9898\u90a3\u4e2a\u5730\u65b9\u5199\u9519\u4e86\uff0c\u5927\u5bb6\u90fd\u53ef\u4ee5\u63d0\u51fa\u6765\u3002<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\"> <\/span><\/p>\n<p cid=\"n0\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\"><\/span><\/p>\n<hr style=\"border-style: solid;border-width: 1px 0 0;border-color: rgba(0,0,0,0.1);-webkit-transform-origin: 0 0;-webkit-transform: scale(1, 0.5);transform-origin: 0 0;transform: scale(1, 0.5);\"  \/>\n<p cid=\"n0\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\"><\/span><\/p>\n<h1 cid=\"n3\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 2.25em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.2;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u4e00\u3001 \u51c6\u5907\u5de5\u4f5c<\/span><\/h1>\n<h2 cid=\"n4\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">1. \u786e\u8ba4\u73af\u5883<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"powershell\" cid=\"n5\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\">swapoff <span style=\"color: rgb(152, 26, 26);\">-<\/span>a <span style=\"color: rgb(152, 26, 26);\">\/\/<\/span><span style=\"color: red;\">\u5173\u95ed<\/span>swap<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">setenforce <span style=\"color: rgb(17, 102, 68);\">0<\/span> <span style=\"color: rgb(152, 26, 26);\">\/\/<\/span><span style=\"color: red;\">\u4e34\u65f6\u5173\u95ed<\/span>selinux<\/span><\/pre>\n<p cid=\"n6\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u6bcf\u53f0\u673a\u5668\u7684ip\u548cuuid\u4e0d\u80fd\u4e00\u6837<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"powershell\" cid=\"n7\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(51, 0, 170);\">cat<\/span> <span style=\"color: rgb(152, 26, 26);\">\/<\/span>sys<span style=\"color: rgb(152, 26, 26);\">\/<\/span>class<span style=\"color: rgb(152, 26, 26);\">\/<\/span>dmi<span style=\"color: rgb(152, 26, 26);\">\/<\/span>id<span style=\"color: rgb(152, 26, 26);\">\/<\/span>product_uuid    <span style=\"color: rgb(152, 26, 26);\">\/\/<\/span><span style=\"color: red;\">\u6bcf\u53f0\u673a\u5668\u7684<\/span>uuid<span style=\"color: red;\">\u4e0d\u80fd\u76f8\u540c<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">ifconfig <span style=\"color: rgb(152, 26, 26);\">-<\/span>a  <span style=\"color: rgb(152, 26, 26);\">\/\/<\/span>ip<span style=\"color: red;\">\u4e0d\u80fd\u76f8\u540c<\/span><\/span><\/pre>\n<h2 cid=\"n8\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">2.\u5f00\u653e\u7aef\u53e3<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"bash\" cid=\"n9\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\">\u534f\u8bae<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span>\u65b9\u5411<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span>\u7aef\u53e3\u8303\u56f4<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">    <\/span>\u4f5c\u7528<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span>\u4f7f\u7528\u8005<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">6443<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">    <\/span>Kubernetes API\u670d\u52a1\u5668<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">   <\/span>\u6240\u6709\u7ec4\u4ef6<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">2379<\/span><span style=\"color: rgb(0, 0, 204);\">-2380<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">   <\/span>etcd \u670d\u52a1\u5668\u5ba2\u6237\u7aefAPI<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span>Kube-apiserver,etcd<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">10250<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">   <\/span>Kubelet APT<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>Kubelet\u81ea\u8eab\uff0c\u63a7\u5236\u5e73\u9762\u7ec4\u4ef6<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">10251<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">   <\/span>Kube-scheduler<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span>Kube-scheduler\u81ea\u8eab<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">10252<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">   <\/span>Kube-controller-manager<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>Kube-controller-manager\u81ea\u8eab<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">8080<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">    <\/span>kubelet<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>Kubelet\u81ea\u8eab<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">TCP<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>\u5165\u7ad9<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">  <\/span><span style=\"color: rgb(17, 102, 68);\">30000<\/span><span style=\"color: rgb(0, 0, 204);\">-32767<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span>Node Port\u670d\u52a1\u5668<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">    <\/span>\u6240\u6709\u7ec4\u4ef6<\/span><\/pre>\n<blockquote cid=\"n10\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n11\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u7aef\u53e3\u53f7\u4e00\u5b9a\u8981\u5b89\u6392\u660e\u767d\uff01\uff01\uff01\uff01\u5426\u8005\u4f1a\u51fa\u73b0\u7c7b\u4f3cdial tcp 10.96.0.1:443: connect: no route to<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\">host\u9519\u8bef\uff0c\u5982\u679c\u6d4b\u8bd5\u73af\u5883\u4e00\u76f4\u5f04\u4e0d\u597d\uff0c\u53ef\u4ee5\u5173\u95ed\u9632\u706b\u5899\u3002ps\uff1a\u53ca\u5176\u4e0d\u5efa\u8bae\u3002<\/span><\/p>\n<\/blockquote>\n<h2 cid=\"n12\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">3.\u5141\u8bb8iptables\u68c0\u67e5\u6865\u63a5\u6d41\u91cf<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n13\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">cat<\/span> <span style=\"color: rgb(170, 17, 17);\">&lt;&lt;EOF | sudo tee \/etc\/modules-load.d\/k8s.conf<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">br_netfilter<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">EOF<\/span><\/span><\/pre>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n14\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">cat<\/span> <span style=\"color: rgb(170, 17, 17);\">&lt;&lt;EOF | sudo tee \/etc\/sysctl.d\/k8s.conf<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">net.bridge.bridge-nf-call-ip6tables = 1<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">net.bridge.bridge-nf-call-iptables = 1<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">EOF<\/span><\/span><\/pre>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n15\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">sysctl<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(119, 0, 136);\">system<\/span><span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">    <\/span>\u521d\u59cb\u5316<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\"> <\/span><\/span><\/pre>\n<h1 cid=\"n16\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 2.25em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.2;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u4e8c\u3001\u5b89\u88c5<\/span><\/h1>\n<h2 cid=\"n17\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">1.\u5b89\u88c5kubeadm\u3001kubelet\u3001kubectl<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n18\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\">\u6dfb\u52a0\u955c\u50cf<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">cat<\/span> <span style=\"color: rgb(170, 17, 17);\">&lt;&lt;EOF | sudo tee \/etc\/yum.repos.d\/kubernetes.repo<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">[kubernetes] <\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">name=Kubernetes <\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">baseurl=https:\/\/mirrors.aliyun.com\/kubernetes\/yum\/repos\/kubernetes-el7-x86_64 <\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">enabled=1 <\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">gpgcheck=0 <\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">repo_gpgcheck=0 <\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">EOF<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#\u5c06 SELinux \u8bbe\u7f6e\u4e3a permissive \u6a21\u5f0f\uff08\u76f8\u5f53\u4e8e\u5c06\u5176\u7981\u7528\uff09<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">setenforce<\/span> <span style=\"color: rgb(17, 102, 68);\">0<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">sed<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">i<\/span> <span style=\"color: rgb(170, 17, 17);\">'s\/^SELINUX=enforcing$\/SELINUX=permissive\/'<\/span> <span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">etc<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">selinux<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">config<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">yum<\/span> <span style=\"color: rgb(85, 85, 85);\">install<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">y<\/span> <span style=\"color: rgb(85, 85, 85);\">kubelet<\/span> <span style=\"color: rgb(85, 85, 85);\">kubeadm<\/span> <span style=\"color: rgb(85, 85, 85);\">kubectl<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">disableexcludes<\/span><span style=\"color: rgb(152, 26, 26);\">=<\/span><span style=\"color: rgb(85, 85, 85);\">kubernetes<\/span>  \u4e0b\u8f7d\u955c\u50cf<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">systemctl<\/span> <span style=\"color: rgb(85, 85, 85);\">enable<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">now<\/span> <span style=\"color: rgb(85, 85, 85);\">kubelet<\/span> <\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(152, 26, 26);\">\/\/<\/span>\u67e5\u770b\u662f\u5426\u5b89\u88c5\u6210\u529f<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubeadm<\/span> <span style=\"color: rgb(85, 85, 85);\">version<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubectl<\/span> <span style=\"color: rgb(85, 85, 85);\">version<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">client<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubelet<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">version<\/span><\/span><\/pre>\n<h2 cid=\"n19\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">2. \u5b89\u88c5\u63d2\u4ef6<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n20\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">yum<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">y<\/span> <span style=\"color: rgb(85, 85, 85);\">install<\/span> <span style=\"color: rgb(85, 85, 85);\">socat<\/span> <span style=\"color: rgb(85, 85, 85);\">conntrack<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">tools<\/span><\/span><\/pre>\n<h2 cid=\"n21\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">3. \u90e8\u7f72docker<\/span><\/h2>\n<p cid=\"n22\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u5728\u670d\u52a1\u5668\u4e0a\u51c6\u5907\u5728\u7ebf\u955c\u50cf\u6e90\uff0c\u7136\u540e\u6dfb\u52a0docker\u7684\u955c\u50cf\u6e90\uff0c\u5982\u679c\u4e4b\u524d\u5b89\u88c5\u8fc7\u9700\u8981\u5148\u5378\u8f7d\u3002<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n23\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#\u5b89\u88c5\u4f9d\u8d56\u5305<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">[<span style=\"color: rgb(85, 85, 85);\">root<\/span><span style=\"color: rgb(0, 0, 0);\">@docker<\/span> ~]<span style=\"color: rgb(170, 85, 0);\"># yum install -y yum-utils device-mapper-persistent-data lvm2<span role=\"presentation\" cm-text=\"\t\" style=\"font-family: var(--monospace);display: inline-block;\">    <\/span><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#\u6dfb\u52a0\u534e\u4e3a\u4e91\u7684docker\u955c\u50cf\u5730\u5740<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">[<span style=\"color: rgb(85, 85, 85);\">root<\/span><span style=\"color: rgb(0, 0, 0);\">@docker<\/span> ~]<span style=\"color: rgb(170, 85, 0);\"># yum-config-manager --add-repo https:\/\/repo.huaweicloud.com\/docker-ce\/linux\/centos\/docker-ce.repo<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">\u66f4\u65b0\u7f13\u5b58\uff0c\u53ea\u5904\u7406\u65b0\u6dfb\u52a0\u7684<span style=\"color: rgb(85, 85, 85);\">yum<\/span>\u6e90\u7f13\u5b58<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">[<span style=\"color: rgb(85, 85, 85);\">root<\/span><span style=\"color: rgb(0, 0, 0);\">@docker<\/span> ~]<span style=\"color: rgb(170, 85, 0);\"># yum makecache fast<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#\u5b89\u88c5docker\uff0c\u9ed8\u8ba4\u5b89\u88c5\u6700\u65b0\u7248\u672c<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">[<span style=\"color: rgb(85, 85, 85);\">root<\/span><span style=\"color: rgb(0, 0, 0);\">@docker<\/span> ~]<span style=\"color: rgb(170, 85, 0);\"># yum -y install docker-ce<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#\u67e5\u770b\u5b89\u88c5docker\u7248\u672c<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">[<span style=\"color: rgb(85, 85, 85);\">root<\/span><span style=\"color: rgb(0, 0, 0);\">@docker<\/span> ~]<span style=\"color: rgb(170, 85, 0);\"># docker --version(\u6216\u8005\u4f7f\u7528docker version)<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">Docker<\/span> <span style=\"color: rgb(85, 85, 85);\">version<\/span> <span style=\"color: rgb(17, 102, 68);\">20.10.7<\/span>, <span style=\"color: rgb(85, 85, 85);\">build<\/span> <span style=\"color: rgb(85, 85, 85);\">f0df350<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">[<span style=\"color: rgb(85, 85, 85);\">root<\/span><span style=\"color: rgb(0, 0, 0);\">@docker<\/span> ~]<span style=\"color: rgb(170, 85, 0);\"># systemctl start docker<\/span><\/span><\/pre>\n<h2 cid=\"n24\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">4. \u4fee\u6539docker\u7ec4\u4ef6\u4e3asystemd<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n25\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(119, 0, 136);\">mkdir<\/span> <span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">etc<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">docker<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">cat<\/span> <span style=\"color: rgb(170, 17, 17);\">&lt;&lt;EOF | sudo tee \/etc\/docker\/daemon.json<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">{<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">  \"exec-opts\": [\"native.cgroupdriver=systemd\"],<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">  \"log-driver\": \"json-file\",<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">  \"log-opts\": {<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">   \"max-size\": \"100m\"<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">  },<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">  \"storage-driver\": \"overlay2\"<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">}<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 17, 17);\">EOF<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"> <\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">systemctl<\/span> <span style=\"color: rgb(85, 85, 85);\">enable<\/span> <span style=\"color: rgb(85, 85, 85);\">docker<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">systemctl<\/span> <span style=\"color: rgb(85, 85, 85);\">daemon<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">reload<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">systemctl<\/span> <span style=\"color: rgb(85, 85, 85);\">restart<\/span> <span style=\"color: rgb(85, 85, 85);\">docker<\/span><\/span><\/pre>\n<h2 cid=\"n26\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">5. k8s\u62c9\u53d6\u955c\u50cf<\/span><\/h2>\n<p cid=\"n27\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u5148\u67e5\u770b\u8981\u62c9\u53d6\u7684\u955c\u50cf<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n28\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubeadm<\/span> <span style=\"color: rgb(85, 85, 85);\">config<\/span> <span style=\"color: rgb(85, 85, 85);\">images<\/span> <span style=\"color: rgb(85, 85, 85);\">list<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">apiserver<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">controller<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">manager<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">scheduler<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">proxy<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">pause<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(17, 102, 68);\">3.5<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">etcd<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(17, 102, 68);\">3.5.0<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(17, 102, 68);\">0<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.8.4<\/span><\/span><\/pre>\n<p cid=\"n29\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u5199\u6210\u811a\u672c\uff0c\u7248\u672c\u6839\u636e\u81ea\u5df1\u7684\u8981\u6c42\u6765\u5199<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n30\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">vim<\/span> <span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">sh<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#!\/bin\/bash<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">images<\/span><span style=\"color: rgb(152, 26, 26);\">=<\/span>(<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">apiserver<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">controller<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">manager<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">scheduler<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">proxy<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">pause<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(17, 102, 68);\">3.5<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">etcd<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(17, 102, 68);\">3.5.0<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(17, 102, 68);\">0<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.8.4<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">)<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(119, 0, 136);\">for<\/span> <span style=\"color: rgb(85, 85, 85);\">imageName<\/span> <span style=\"color: rgb(85, 85, 85);\">in<\/span> ${images[<span style=\"color: rgb(0, 0, 0);\">@]<\/span>} ; <span style=\"color: rgb(119, 0, 136);\">do<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">docker<\/span> <span style=\"color: rgb(85, 85, 85);\">pull<\/span> <span style=\"color: rgb(85, 85, 85);\">registry<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">cn<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">hangzhou<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">aliyuncs<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">com<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">google_containers<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(0, 0, 0);\">${imageName}<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">docker<\/span> <span style=\"color: rgb(85, 85, 85);\">tag<\/span> <span style=\"color: rgb(85, 85, 85);\">registry<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">cn<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">hangzhou<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">aliyuncs<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">com<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">google_containers<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(0, 0, 0);\">${imageName}<\/span> <span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(0, 0, 0);\">${imageName}<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">  <span style=\"color: rgb(85, 85, 85);\">docker<\/span> <span style=\"color: rgb(85, 85, 85);\">rmi<\/span> <span style=\"color: rgb(85, 85, 85);\">registry<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">cn<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">hangzhou<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">aliyuncs<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">com<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">google_containers<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(0, 0, 0);\">${imageName}<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">done<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">docker<\/span> <span style=\"color: rgb(85, 85, 85);\">tag<\/span> <span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.8.4<\/span> <span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.8.4<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">docker<\/span> <span style=\"color: rgb(85, 85, 85);\">rmi<\/span> <span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">gcr<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">io<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coredns<\/span><span style=\"color: rgb(152, 26, 26);\">:<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.8.4<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">\u7ed9\u811a\u672c\u52a0\u6743\u9650<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(119, 0, 136);\">chmod<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">R<\/span> <span style=\"color: rgb(17, 102, 68);\">777<\/span> <span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">sh<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">\u6267\u884c\u811a\u672c,\u9ed8\u9ed8\u7684\u7b49\u5f85\u62c9\u53d6<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">.<span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">k8s<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">sh<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\">\u5b8c\u4e86\u770b\u955c\u50cf\u662f\u5426\u62c9\u53d6\u6210\u529f<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">docker<\/span> <span style=\"color: rgb(85, 85, 85);\">images<\/span><\/span><\/pre>\n<h2 cid=\"n31\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">6. \u5b89\u88c5\u542f\u52a8<\/span><\/h2>\n<p cid=\"n32\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"strong\"><strong><span md-inline=\"plain\">1.<\/span><span md-inline=\"tab\" style=\"display: inline-block;\">\t<\/span><span md-inline=\"plain\">\u4fee\u6539\u4e3b\u673a\u6620\u5c04\uff08\u6839\u636e\u81ea\u5df1\u7684ip\u8bbe\u7f6e\uff09<\/span><\/strong><\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n33\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">vi<\/span> <span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">etc<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">hosts<\/span><\/span><\/pre>\n<p cid=\"n34\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;display: inline-block;width: 800px;\"><img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-imgfileid=\"100000332\" data-ratio=\"0.1368653421633554\"  data-type=\"png\" data-w=\"453\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;display: block;margin: auto;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223511389.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-imgfileid=\"100000332\" data-ratio=\"0.1368653421633554\"  data-type=\"png\" data-w=\"453\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;display: block;margin: auto;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223511389.png\"><\/noscript><\/span><\/p>\n<p cid=\"n35\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"strong\"><strong><span md-inline=\"plain\">2.<\/span><span md-inline=\"tab\" style=\"display: inline-block;\">\t<\/span><span md-inline=\"plain\">\u521d\u59cb\u5316\u670d\u52a1\uff08\u6839\u636e\u81ea\u5df1\u7684ip\u548c\u7f51\u6bb5\u548c\u7248\u672c\u6765\u8bbe\u7f6e\uff09<\/span><\/strong><\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n36\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubeadm<\/span> <span style=\"color: rgb(85, 85, 85);\">init<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">apiserver<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">advertise<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">address<\/span><span style=\"color: rgb(152, 26, 26);\">=<\/span><span style=\"color: rgb(17, 102, 68);\">192.168.2.80<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">pod<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">network<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">cidr<\/span><span style=\"color: rgb(152, 26, 26);\">=<\/span><span style=\"color: rgb(17, 102, 68);\">192.168.0.0<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(17, 102, 68);\">16<\/span> <span style=\"color: rgb(152, 26, 26);\">--<\/span><span style=\"color: rgb(85, 85, 85);\">kubernetes<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">version<\/span><span style=\"color: rgb(152, 26, 26);\">=<\/span><span style=\"color: rgb(85, 85, 85);\">v1<\/span><span style=\"color: rgb(17, 102, 68);\">.22.2<\/span> <span style=\"color: rgb(152, 26, 26);\">|<\/span><span style=\"color: rgb(85, 85, 85);\">tee<\/span> <span style=\"color: rgb(85, 85, 85);\">kubeadmin<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">init<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(119, 0, 136);\">log<\/span><\/span><\/pre>\n<p cid=\"n37\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u51fa\u73b0\u4e00\u4e0b\u5b57\u6837\u5c31\u662f\u521d\u59cb\u5316\u6210\u529f<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\"> <\/span><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;\"><img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-imgfileid=\"100000334\" data-ratio=\"0.6845238095238095\"  data-type=\"png\" data-w=\"504\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223515651.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-imgfileid=\"100000334\" data-ratio=\"0.6845238095238095\"  data-type=\"png\" data-w=\"504\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223515651.png\"><\/noscript><\/span><\/p>\n<p cid=\"n38\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"strong\"><strong><span md-inline=\"plain\">3.<\/span><span md-inline=\"tab\" style=\"display: inline-block;\">\t<\/span><span md-inline=\"plain\">\u6ce8\u610f<\/span><\/strong><\/span><\/p>\n<blockquote cid=\"n39\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n40\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u8981\u4f7f\u975e root \u7528\u6237\u53ef\u4ee5\u8fd0\u884c kubectl\uff0c\u8bf7\u8fd0\u884c\u4ee5\u4e0b\u547d\u4ee4\uff0c \u5b83\u4eec\u4e5f\u662f kubeadm init \u8f93\u51fa\u7684\u4e00\u90e8\u5206\uff1a<\/span><\/p>\n<\/blockquote>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n41\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(119, 0, 136);\">mkdir<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">p<\/span> <span style=\"color: rgb(0, 0, 0);\">$HOME<\/span><span style=\"color: rgb(152, 26, 26);\">\/.<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(85, 85, 85);\">cp<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">i<\/span> <span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">etc<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kubernetes<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">admin<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">conf<\/span> <span style=\"color: rgb(0, 0, 0);\">$HOME<\/span><span style=\"color: rgb(152, 26, 26);\">\/.<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">config<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">sudo<\/span> <span style=\"color: rgb(119, 0, 136);\">chown<\/span> <span style=\"color: rgb(0, 85, 170);\">$(<\/span><span style=\"color: rgb(85, 85, 85);\">id<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">u<\/span>):<span style=\"color: rgb(0, 85, 170);\">$(<\/span><span style=\"color: rgb(85, 85, 85);\">id<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">g<\/span>) <span style=\"color: rgb(0, 0, 0);\">$HOME<\/span><span style=\"color: rgb(152, 26, 26);\">\/.<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">config<\/span><\/span><\/pre>\n<blockquote cid=\"n42\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n43\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u6216\u8005\uff0c\u5982\u679c\u4f60\u662froot \u7528\u6237\uff0c\u5219\u53ef\u4ee5\u8fd0\u884c\uff1a<\/span><\/p>\n<\/blockquote>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n44\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">export<\/span> <span style=\"color: rgb(85, 85, 85);\">KUBECONFIG<\/span>=<span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">etc<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kubernetes<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">admin<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">conf<\/span><\/span><\/pre>\n<blockquote cid=\"n45\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n46\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u5982\u679c\u60f3\u91cd\u65b0\u521d\u59cb\u5316\uff0c\u53ef\u6267\u884ckubeadm reset<\/span><\/p>\n<\/blockquote>\n<p cid=\"n47\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u76f4\u63a5\u7ed9\u5b83\u653e\u5230\u73af\u5883\u53d8\u91cf\u4e2d\uff0c\u4ee5\u514d\u5173\u95ed\u670d\u52a1\u5668\u540e\u91cd\u65b0\u542f\u52a8\u51fa\u73b0\u8bbf\u95ee\u4e0d\u52308080\u7aef\u53e3\u8fd9\u4e2a\u95ee\u9898\u3002<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"bash\" cid=\"n48\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(51, 0, 170);\">vim<\/span> \/etc\/profile<\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span cm-text=\"\"><\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(170, 85, 0);\">#\u653e\u5230\u6700\u540e\u9762<\/span><\/span><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(119, 0, 136);\">export<\/span> <span style=\"color: rgb(0, 0, 255);\">KUBECONFIG<\/span><span style=\"color: rgb(152, 26, 26);\">=<\/span>\/etc\/kubernetes\/admin.conf<\/span><\/pre>\n<h2 cid=\"n50\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">7. \u5b89\u88c5flannel<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n51\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubectl<\/span> <span style=\"color: rgb(85, 85, 85);\">apply<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">f<\/span> <span style=\"color: rgb(85, 85, 85);\">https<\/span>:<span style=\"color: rgb(152, 26, 26);\">\/\/<\/span><span style=\"color: rgb(85, 85, 85);\">raw<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">githubusercontent<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">com<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">coreos<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">flannel<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">master<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">Documentation<\/span><span style=\"color: rgb(152, 26, 26);\">\/<\/span><span style=\"color: rgb(85, 85, 85);\">kube<\/span><span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">flannel<\/span><span style=\"color: rgb(152, 26, 26);\">.<\/span><span style=\"color: rgb(85, 85, 85);\">yml<\/span><\/span><\/pre>\n<blockquote cid=\"n52\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n53\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u5982\u679c\u51fa\u73b0Connecting to raw.githubusercontent.com refused\uff0c\u53ef\u4ee5\u6267\u884cvi \/etc\/hosts<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\">\u5728\u540e\u9762\u6dfb\u52a0199.232.96.133 raw.githubusercontent.com<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;\"><img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-imgfileid=\"100000333\" data-ratio=\"0.17328519855595667\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223522109.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-imgfileid=\"100000333\" data-ratio=\"0.17328519855595667\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223522109.png\"><\/noscript><\/span><\/p>\n<\/blockquote>\n<p cid=\"n54\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\"> <\/span><\/p>\n<h2 cid=\"n55\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">8. \u9a8c\u8bc1<\/span><\/h2>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n56\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubectl<\/span> <span style=\"color: rgb(85, 85, 85);\">get<\/span> <span style=\"color: rgb(85, 85, 85);\">nodes<\/span><\/span><\/pre>\n<p cid=\"n57\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;\"><img decoding=\"async\" class=\"lazyload\"data-imgfileid=\"100000338\" data-ratio=\"0.09221902017291066\"  data-type=\"png\" data-w=\"347\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223526414.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"  \/><noscript><img decoding=\"async\" data-imgfileid=\"100000338\" data-ratio=\"0.09221902017291066\"  data-type=\"png\" data-w=\"347\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223526414.png\"  \/><\/noscript><\/span><span md-inline=\"plain\"> <\/span><\/p>\n<blockquote cid=\"n58\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n59\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u5982\u679c\u51fa\u73b0ready\u5219\u4ee3\u8868\u5b89\u88c5\u5b8c\u6210\uff0cmaster\u8282\u70b9\u5df2\u7ecf\u6ce8\u518c\u5230\u4e86k8s\u3002<\/span><\/p>\n<\/blockquote>\n<h2 cid=\"n60\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">9. \u5f02\u5e38\u5904\u7406<\/span><\/h2>\n<blockquote cid=\"n61\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n62\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u5982\u679c\u51fa\u73b0NotReady\uff0c\u53ef\u4ee5\u6267\u884c\u4ee5\u4e0b\u8bed\u53e5\u5224\u65ad\u670d\u52a1\u5668\u72b6\u6001\u3002<\/span><\/p>\n<\/blockquote>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n63\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;white-space: normal;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\"><span role=\"presentation\" style=\"padding-right: 0.1px;\"><span style=\"color: rgb(85, 85, 85);\">kubectl<\/span> <span style=\"color: rgb(85, 85, 85);\">get<\/span> <span style=\"color: rgb(85, 85, 85);\">nodes<\/span> <span style=\"color: rgb(152, 26, 26);\">-<\/span><span style=\"color: rgb(85, 85, 85);\">o<\/span> <span style=\"color: rgb(85, 85, 85);\">yaml<\/span><\/span><\/pre>\n<blockquote cid=\"n64\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n65\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\u4ee5\u4e0b\u7eff\u8272\u90e8\u5206\u6ca1\u6709\u95ee\u9898\uff0c\u7ea2\u8272\u90e8\u5206\u5f02\u5e38message:docker: network plugin is not ready: cni<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\">config uninitialized\u3002<\/span><\/p>\n<\/blockquote>\n<p cid=\"n66\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\"> <\/span><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;\"><img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-imgfileid=\"100000340\" data-ratio=\"0.6895306859205776\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223531913.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-imgfileid=\"100000340\" data-ratio=\"0.6895306859205776\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223531913.png\"><\/noscript><\/span><\/p>\n<p cid=\"n67\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u5982\u679c\u51fa\u73b0\u4ee5\u4e0a\u95ee\u9898 \u67e5\u770b\u65e5\u5fd7\u3002<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n68\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;text-wrap: wrap;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\">journalctl -f -u kubelet.service<\/pre>\n<p cid=\"n69\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u5982\u679c\u51fa\u73b0\u4ee5\u4e0b\u65e5\u5fd7\u3002<\/span><\/p>\n<blockquote cid=\"n70\" mdtype=\"blockquote\" style=\"margin-top: 0.8em;margin-bottom: 0.8em;border-left-width: 4px;border-left-color: rgb(223, 226, 229);padding-top: 0px;padding-right: 15px;padding-left: 15px;color: rgb(119, 119, 119);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;text-wrap: wrap;\">\n<p cid=\"n71\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;white-space-collapse: preserve;\"><span md-inline=\"plain\">\"Error validating CNI config list\" configList=\"{n <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">name<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">:<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">cbr0<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">,n <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">cniVersion<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">0.3.1<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">,n <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">plugins<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: [n  {n <\/span><span md-inline=\"linebreak\" style=\"font-family: var(--monospace);opacity: 0.6;color: inherit;\"> <span style=\"font-family: var(--monospace);opacity: 0.6;color: inherit;\"><\/span><\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">type<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">flannel<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">,n   <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">delegate<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: {n   <\/span><span md-inline=\"linebreak\" style=\"font-family: var(--monospace);opacity: 0.6;color: inherit;\"> <span style=\"font-family: var(--monospace);opacity: 0.6;color: inherit;\"><\/span><\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">hairpinMode<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: true,n    <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">isDefaultGateway<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: truen   }n <\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\">},n  {n   <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">type<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">portmap<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">,n   <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">capabilities<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: {n<\/span><span md-inline=\"linebreak\" style=\"font-family: var(--monospace);opacity: 0.6;color: inherit;\"> <span style=\"font-family: var(--monospace);opacity: 0.6;color: inherit;\"><\/span><\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">portMappings<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">: truen   }n  }n ]n}n\" err=\"[failed to find<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\">plugin <\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">flannel<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\"> in path [\/opt\/cni\/bin] failed to find plugin<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\">portmap<\/span><span md-inline=\"escape\">\"<\/span><span md-inline=\"plain\"> in path [\/opt\/cni\/bin]]\"<\/span><\/p>\n<\/blockquote>\n<p cid=\"n72\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u6267\u884c\u4ee5\u4e0b\u547d\u4ee4\u5373\u53ef<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"perl\" cid=\"n73\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;text-wrap: wrap;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\">cat &lt;&lt;EOF &gt; \/etc\/yum.repos.d\/kubernetes.repo[kubernetes]name=Kubernetesbaseurl=https:\/\/mirrors.aliyun.com\/kubernetes\/yum\/repos\/kubernetes-el7-x86_64enabled=1gpgcheck=1repo_gpgcheck=1gpgkey=https:\/\/mirrors.aliyun.com\/kubernetes\/yum\/doc\/yum-key.gpg https:\/\/mirrors.aliyun.com\/kubernetes\/yum\/doc\/rpm-package-key.gpgEOFyum clean allyum install kubernetes-cni -y<\/pre>\n<h2 cid=\"n75\" mdtype=\"heading\" style=\"break-after: avoid-page;break-inside: avoid;orphans: 4;font-size: 1.75em;margin-top: 1rem;margin-bottom: 1rem;font-weight: bold;line-height: 1.225;cursor: text;border-bottom: 1px solid rgb(238, 238, 238);white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">10.\u91cd\u542f\u540ek8s\u5f02\u5e38\u5904\u7406<\/span><\/h2>\n<p cid=\"n76\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u91cd\u542f\u540e\u67e5\u770bnodes\u8282\u70b9\uff0c\u6216\u8005\u5176\u4ed6<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"bash\" cid=\"n77\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;text-wrap: wrap;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\">[root@kubernetes ~]# kubectl get nodes<\/pre>\n<p cid=\"n78\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;display: inline-block;width: 800px;\"><img decoding=\"async\" class=\"lazyload\"data-imgfileid=\"100000337\" data-ratio=\"0.04693140794223827\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;display: block;margin: auto;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223539216.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"  \/><noscript><img decoding=\"async\" data-imgfileid=\"100000337\" data-ratio=\"0.04693140794223827\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;display: block;margin: auto;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223539216.png\"  \/><\/noscript><\/span><\/p>\n<p cid=\"n79\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u89e3\u51b3\uff1a\u5199\u5230\u73af\u5883\u91cc<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"bash\" cid=\"n80\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;text-wrap: wrap;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\">bashvim \/etc\/profile\u52a0\u5230\u6700\u540e\u9762export KUBECONFIG=\/etc\/kubernetes\/admin.conf\u91cd\u542f\u865a\u62df\u673a\uff1ainit 6\/reboot<\/pre>\n<p cid=\"n81\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u518d\u6b21\u67e5\u770b\uff1a\uff1a<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"bash\" cid=\"n82\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;text-wrap: wrap;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\">[root@kubernetes ~]# kubectl get nodes<\/pre>\n<p cid=\"n83\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"image\"  style=\"min-width: 10px;min-height: 10px;word-break: break-all;font-family: monospace;vertical-align: top;display: inline-block;width: 800px;\"><img decoding=\"async\" class=\"rich_pages wxw-img lazyload\" data-imgfileid=\"100000339\" data-ratio=\"0.05054151624548736\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;display: block;margin: auto;\" data-src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223544375.png\" src=\"https:\/\/s.nmxc.ltd\/sakurairo_vision\/@2.6\/load_svg\/inload.svg\" onerror=\"imgError(this)\"  \/><noscript><img decoding=\"async\" class=\"rich_pages wxw-img\" data-imgfileid=\"100000339\" data-ratio=\"0.05054151624548736\"  data-type=\"png\" data-w=\"554\" style=\"border-width: 0px 4px 0px 2px;border-top-style: initial;border-right-style: solid;border-bottom-style: initial;border-left-style: solid;border-top-color: initial;border-right-color: transparent;border-bottom-color: initial;border-left-color: transparent;vertical-align: middle;image-orientation: from-image;cursor: default;display: block;margin: auto;\" src=\"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223544375.png\"  \/><\/noscript><\/span><\/p>\n<p cid=\"n84\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\"><span md-inline=\"plain\">\u53c8\u6709\u4e86\u65b0\u7684\u62a5\u9519\uff1a<\/span><span md-inline=\"softbreak\"><\/span><span md-inline=\"plain\">\u89e3\u51b3\uff1a\u5173\u95ed\u4ea4\u6362\u5206\u533a\uff0c\u7b49\u5f85\u4e00\u4f1a\uff08\u5728\u81ea\u542f\u5bb9\u5668\u4e2d\uff09<\/span><\/p>\n<pre spellcheck=\"false\" lang=\"bash\" cid=\"n85\" mdtype=\"fences\" style=\"overflow: visible;font-family: var(--monospace);font-size: 0.9em;break-inside: avoid;text-align: left;text-wrap: wrap;background-image: inherit;background-position: inherit;background-size: inherit;background-repeat: inherit;background-attachment: inherit;background-origin: inherit;background-clip: inherit;background-color: rgb(248, 248, 248);border-width: 1px;border-style: solid;border-color: rgb(231, 234, 237);border-radius: 3px;padding: 8px 4px 6px;margin-bottom: 15px;margin-top: 15px;width: inherit;color: rgb(51, 51, 51);letter-spacing: normal;\">[root@kubernetes ~]# swapoff -a[root@kubernetes ~]# kubectl get nodesNAME         STATUS   ROLES                  AGE   VERSIONkubernetes   Ready    control-plane,master   19m   v1.22.2<\/pre>\n<p cid=\"n86\" mdtype=\"paragraph\" style=\"line-height: inherit;orphans: 4;margin-top: 0.8em;margin-bottom: 0.8em;white-space: pre-wrap;color: rgb(51, 51, 51);font-family: &quot;Open Sans&quot;, &quot;Clear Sans&quot;, &quot;Helvetica Neue&quot;, Helvetica, Arial, sans-serif;font-size: 16px;letter-spacing: normal;text-align: start;\">\n<p style=\"display: none;\"><mp-style-type data-value=\"3\"><\/mp-style-type><\/p>\n<blockquote>\n<p>\u672c\u7bc7\u6587\u7ae0\u6765\u6e90\u4e8e\u5fae\u4fe1\u516c\u4f17\u53f7:                 \u5c0f\u5218Linux              <\/p>\n<\/blockquote>\n<\/div>\n","raw":"","protected":false},"excerpt":{"rendered":"<p>\u8fd9\u662f\u6211\u505a\u4e86\u5f88\u591a\u904d\uff0c\u53c2\u8003\u5f88\u591a\u6587\u7ae0\u5f97\u5230\u7684\uff0c\u4e3a\u4e86\u4fbf\u4e8e\u5927\u5bb6\u53c2\u8003\u548c\u5b66\u4e60\uff0c\u6211\u5df2\u7ecf\u628a\u6bcf\u4e00\u6b65\u90fd\u6574\u7406\u51fa\u6765\u4e86\uff0c\u6b65\u9aa4\u548c\u63d0\u793a\u90fd\u5f88\u6e05\u6670\u3002 \u540e\u7eed\u6587\u6863\u6709\u4ec0\u4e48\u95ee\u9898 &#8230;<\/p>\n","protected":false},"author":1,"featured_media":6042,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"emotion":"","emotion_color":"","title_style":"","license":"","footnotes":""},"categories":[32],"tags":[],"class_list":["post-6068","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-k8s"],"post_thumbnail_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223501685-150x150.jpeg","content_first_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223511389.png","post_medium_image_300":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223501685-300x127.jpeg","post_thumbnail_image_624":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223501685.jpeg","post_frist_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223511389.png","post_medium_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223501685-300x127.jpeg","post_large_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223501685.jpeg","post_full_image":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223501685.jpeg","post_all_images":[{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223511389.png","id":"image0"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223511389.png","id":"image1"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223515651.png","id":"image2"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223515651.png","id":"image3"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223522109.png","id":"image4"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223522109.png","id":"image5"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223526414.png","id":"image6"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223526414.png","id":"image7"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223531913.png","id":"image8"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223531913.png","id":"image9"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223539216.png","id":"image10"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223539216.png","id":"image11"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223544375.png","id":"image12"},{"imagesurl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2024\/08\/20240801223544375.png","id":"image13"}],"videoAdId":"","listAd":"0","listAdId":"","listAdEvery":6,"total_comments":0,"category_name":"K8S","post_date":"2024-08-01","like_count":"0","praiseWord":"\u9f13\u52b1","copyright_state":"","excitationAd":"0","rewardedVideoAdId":"","detailAdId":"","detailAd":"0","enterpriseMinapp":"0","audios":[],"postImageUrl":"https:\/\/wp-moto-1258805347.cos.ap-shanghai.myqcloud.com\/2023\/05\/20230519082947553.jpg","avatarurls":[],"related_posts":null,"pageviews":766,"next_post_id":6108,"next_post_title":"\u4e00\u7bc7\u6587\u7ae0\u7cbe\u901aK8S\u7684\u7edf\u4e00\u8bbf\u95ee\u5165\u53e3-Service","previous_post_id":5961,"previous_post_title":"\u7f51\u7edc\u8bca\u65ad\u5229\u5668\uff1a\u638c\u63e1 Kubernetes Pod \u6293\u5305\u6280\u5de7","_links":{"self":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts\/6068","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/comments?post=6068"}],"version-history":[{"count":1,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts\/6068\/revisions"}],"predecessor-version":[{"id":6308,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/posts\/6068\/revisions\/6308"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/media\/6042"}],"wp:attachment":[{"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/media?parent=6068"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/categories?post=6068"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/xinchewhd.com.cn\/index.php\/wp-json\/wp\/v2\/tags?post=6068"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}