0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

Ubuntu で Kubernetes 三昧その5-1(Weave Net CNI)

Last updated at Posted at 2025-06-22

Ubuntu で Kubernetes 三昧その4からの続きです。

Network Pluginsをインストールします。
サポートされているのは、これらのプラグインになります。

ここでは、Weave Net CNIプラグインをインストールしてみます。

Weave Net CNIプラグインのインストールは簡単です。マスターで、このコマンドを実行します。

@masternode1:~$ kubectl apply -f https://reweave.azurewebsites.net/k8s/v1.29/net.yaml
serviceaccount/weave-net created
clusterrole.rbac.authorization.k8s.io/weave-net created
clusterrolebinding.rbac.authorization.k8s.io/weave-net created
role.rbac.authorization.k8s.io/weave-net created
rolebinding.rbac.authorization.k8s.io/weave-net created
daemonset.apps/weave-net created

Pod が立ち上がったかどうか、確認します。

$ kubectl get pods -n kube-system
NAME                                  READY   STATUS    RESTARTS        AGE
coredns-674b8bbfcf-44dwf              1/1     Running   0               16h
coredns-674b8bbfcf-ppcj7              1/1     Running   0               16h
etcd-masternode1                      1/1     Running   2               16h
kube-apiserver-masternode1            1/1     Running   2               16h
kube-controller-manager-masternode1   1/1     Running   2               16h
kube-proxy-9n8hv                      1/1     Running   0               16h
kube-proxy-km2s7                      1/1     Running   0               16h
kube-scheduler-masternode1            1/1     Running   2               16h
weave-net-7jtp6                       2/2     Running   1 (4m10s ago)   4m26s
weave-net-v2fhz                       2/2     Running   1 (4m10s ago)   4m26s

ノードの状態はどうでしょうか。CNI をインストールする前は、両ノードとも、NotReady でした。

@masternode1:~$ kubectl get nodes
NAME          STATUS     ROLES           AGE   VERSION
masternode1   NotReady   control-plane   78s   v1.33.2
workernode1   NotReady   <none>          11s   v1.33.2

今回は、Readyになったでしょうか。

@masternode1:~$ kubectl get nodes
NAME          STATUS   ROLES           AGE   VERSION
masternode1   Ready    control-plane   16h   v1.33.2
workernode1   Ready    <none>          16h   v1.33.2

Readyになりました!

また、ワーカーノードからkubectl コマンドを実行しても、エラーにはならず、ちゃんと動きました。

Ubuntu で Kubernetes 三昧その5-2(Weave Net CNI)つづく

参考:

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?