kubernetes를 배우다~그 2:택내 LAN~
8031 단어 kubernetes
목차
마지막 회의
전회는, kubernetes를 배우다~그 1~ 로, 환경의 구축을 했습니다. vagrant의 환경에서 WindowsPC의 퍼스널 방화벽으로 해 주었습니다만, 구축 있는 것이었기 때문에 복습의 의미로 망설이는 것이 좋았다고 생각합니다.
가정 내 LAN 설정
네트워크 정보 확인
구축한 master, node1, node2의 네트워크 정보를 정리합니다.
호스트 PC(노트북 PC)의 IP 주소는
Wireless LAN adapter Wi-Fi:
接続固有の DNS サフィックス . . . . .:
IPv4 アドレス . . . . . . . . . . . .: 192.168.11.101
サブネット マスク . . . . . . . . . .: 255.255.255.0
デフォルト ゲートウェイ . . . . . . .: 192.168.11.1
master, node1, node2의 어댑터는,
어댑터 1: nat
Adapter 2: hostonly
와 vagrant up 명령시의 로그에 표시되고 있었으므로, 브리지 접속하는 네트워크가 없는 상태.
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh master
Last login: Mon Feb 1 10:48:34 2021 from 10.0.2.2
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 04:49:28 UTC 2021
System load: 1.03 Users logged in: 1
Usage of /: 7.6% of 38.71GB IP address for enp0s3: 10.0.2.15
Memory usage: 36% IP address for enp0s8: 172.16.20.11
Swap usage: 0% IP address for docker0: 172.17.0.1
Processes: 144 IP address for cni0: 10.244.0.1
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Mon Feb 1 10:48:34 2021 from 10.0.2.2
enp0s3이 NAT이고 enp0s8이 HostOnly입니다.
virtualBox의 설정 화면에서도 확인할 수 있네요.
브리지 네트워크 추가
이대로 가내 LAN의 다른 단말기에서 접속할 때 호스트 PC의 IP로 가챠가챠해야 하므로 브리지용 네트워크를 추가하려고 합니다.
takara9 님의 vagrantfile을 수정하세요.
vagrantfile 파일내에 수정 개소를 명시해 주고 있으므로, 거기를 택내 LAN의 정보에 수정.
※그 전에 택내 LAN에서 비어있는 IP를 확인할 때 합시다.
라우터의 DHCP 스코프외의 IP에 버립니다.
수정이 끝나면 vagrant를 다시 시작하고 반영합니다.
D:\Repository\kubernetes\vagrant-kubernetes>vagrant reload
==> master: Attempting graceful shutdown of VM...
==> master: Checking if box 'ubuntu/bionic64' version '20210129.0.0' is up to date...
==> master: Clearing any previously set forwarded ports...
==> master: Clearing any previously set network interfaces...
==> master: Specific bridge 'en0:Microsoft Wi-Fi Direct Virtual Adapter #2' not found. You may be asked to specify
==> master: which network to bridge to.
==> master: Available bridged network interfaces:
1) Killer(R) Wi-Fi 6 AX1650s 160MHz Wireless Network Adapter (201D2W)
2) Microsoft Wi-Fi Direct Virtual Adapter #2
3) Hyper-V Virtual Ethernet Adapter
==> master: When choosing an interface, it is usually the one that is
==> master: being used to connect to the internet.
==> master:
master: Which interface should the network bridge to? 1
==> master: Preparing network interfaces based on configuration...
master: Adapter 1: nat
master: Adapter 2: hostonly
master: Adapter 3: bridged
~ 省略 ~
node1、node2ともに同じようなログ。
중간에 브리지 어댑터를 선택하라는 메시지가 나타났으므로 1) 어댑터를 지정했습니다.
master, node1, node2에 액세스합니다.
masterにログイン
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh master
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 05:58:31 UTC 2021
System load: 0.4 IP address for enp0s3: 10.0.2.15
Usage of /: 7.7% of 38.71GB IP address for enp0s8: 172.16.20.11
Memory usage: 34% IP address for enp0s9: 192.168.11.40
Swap usage: 0% IP address for docker0: 172.17.0.1
Processes: 147 IP address for cni0: 10.244.0.1
Users logged in: 0
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Tue Feb 2 05:29:28 2021 from 10.0.2.2
node1にログイン
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh node1
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 06:00:15 UTC 2021
System load: 0.03 IP address for enp0s3: 10.0.2.15
Usage of /: 5.6% of 38.71GB IP address for enp0s8: 172.16.20.12
Memory usage: 3% IP address for enp0s9: 192.168.11.41
Swap usage: 0% IP address for docker0: 172.17.0.1
Processes: 132 IP address for cni0: 10.244.1.1
Users logged in: 0
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Tue Feb 2 05:42:40 2021 from 10.0.2.2
node2にログイン
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh node2
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 06:01:03 UTC 2021
System load: 0.22 Users logged in: 0
Usage of /: 5.5% of 38.71GB IP address for enp0s3: 10.0.2.15
Memory usage: 3% IP address for enp0s8: 172.16.20.13
Swap usage: 0% IP address for enp0s9: 192.168.11.42
Processes: 132 IP address for docker0: 172.17.0.1
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Tue Feb 2 05:40:48 2021 from 10.0.2.2
이제 ↓의 이미지가되었습니다.
후기
실은, 이번 네트워크 확인으로 여러가지 손잡고 있었다. NAT의 설정이 필요하다고 생각하고 virtualBox에서 NAT를 브릿지로 변경해 보거나 했지만, vagrant로부터의 ssh가 연결이 끊어지거나와 여러가지 일어났다.
일단, 원래로 되돌려 브리지용의 네트워크 어댑터 추가해 대처했지만, vagrant도 잘 이해하지 않으면 빠진다고 재인식했다.
※원인은 알 수 없는 w
다음 번은, kubctl나 용어에 대해 정리해 보려고 한다.
참고문헌
15Step으로 습득 Docker에서 들어가는 Kubernetes
Reference
이 문제에 관하여(kubernetes를 배우다~그 2:택내 LAN~), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다
https://qiita.com/shintoshin_se/items/9290f96821f3870f14d8
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념
(Collection and Share based on the CC Protocol.)
네트워크 정보 확인
구축한 master, node1, node2의 네트워크 정보를 정리합니다.
호스트 PC(노트북 PC)의 IP 주소는
Wireless LAN adapter Wi-Fi:
接続固有の DNS サフィックス . . . . .:
IPv4 アドレス . . . . . . . . . . . .: 192.168.11.101
サブネット マスク . . . . . . . . . .: 255.255.255.0
デフォルト ゲートウェイ . . . . . . .: 192.168.11.1
master, node1, node2의 어댑터는,
어댑터 1: nat
Adapter 2: hostonly
와 vagrant up 명령시의 로그에 표시되고 있었으므로, 브리지 접속하는 네트워크가 없는 상태.
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh master
Last login: Mon Feb 1 10:48:34 2021 from 10.0.2.2
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 04:49:28 UTC 2021
System load: 1.03 Users logged in: 1
Usage of /: 7.6% of 38.71GB IP address for enp0s3: 10.0.2.15
Memory usage: 36% IP address for enp0s8: 172.16.20.11
Swap usage: 0% IP address for docker0: 172.17.0.1
Processes: 144 IP address for cni0: 10.244.0.1
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Mon Feb 1 10:48:34 2021 from 10.0.2.2
enp0s3이 NAT이고 enp0s8이 HostOnly입니다.
virtualBox의 설정 화면에서도 확인할 수 있네요.
브리지 네트워크 추가
이대로 가내 LAN의 다른 단말기에서 접속할 때 호스트 PC의 IP로 가챠가챠해야 하므로 브리지용 네트워크를 추가하려고 합니다.
takara9 님의 vagrantfile을 수정하세요.
vagrantfile 파일내에 수정 개소를 명시해 주고 있으므로, 거기를 택내 LAN의 정보에 수정.
※그 전에 택내 LAN에서 비어있는 IP를 확인할 때 합시다.
라우터의 DHCP 스코프외의 IP에 버립니다.
수정이 끝나면 vagrant를 다시 시작하고 반영합니다.
D:\Repository\kubernetes\vagrant-kubernetes>vagrant reload
==> master: Attempting graceful shutdown of VM...
==> master: Checking if box 'ubuntu/bionic64' version '20210129.0.0' is up to date...
==> master: Clearing any previously set forwarded ports...
==> master: Clearing any previously set network interfaces...
==> master: Specific bridge 'en0:Microsoft Wi-Fi Direct Virtual Adapter #2' not found. You may be asked to specify
==> master: which network to bridge to.
==> master: Available bridged network interfaces:
1) Killer(R) Wi-Fi 6 AX1650s 160MHz Wireless Network Adapter (201D2W)
2) Microsoft Wi-Fi Direct Virtual Adapter #2
3) Hyper-V Virtual Ethernet Adapter
==> master: When choosing an interface, it is usually the one that is
==> master: being used to connect to the internet.
==> master:
master: Which interface should the network bridge to? 1
==> master: Preparing network interfaces based on configuration...
master: Adapter 1: nat
master: Adapter 2: hostonly
master: Adapter 3: bridged
~ 省略 ~
node1、node2ともに同じようなログ。
중간에 브리지 어댑터를 선택하라는 메시지가 나타났으므로 1) 어댑터를 지정했습니다.
master, node1, node2에 액세스합니다.
masterにログイン
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh master
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 05:58:31 UTC 2021
System load: 0.4 IP address for enp0s3: 10.0.2.15
Usage of /: 7.7% of 38.71GB IP address for enp0s8: 172.16.20.11
Memory usage: 34% IP address for enp0s9: 192.168.11.40
Swap usage: 0% IP address for docker0: 172.17.0.1
Processes: 147 IP address for cni0: 10.244.0.1
Users logged in: 0
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Tue Feb 2 05:29:28 2021 from 10.0.2.2
node1にログイン
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh node1
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 06:00:15 UTC 2021
System load: 0.03 IP address for enp0s3: 10.0.2.15
Usage of /: 5.6% of 38.71GB IP address for enp0s8: 172.16.20.12
Memory usage: 3% IP address for enp0s9: 192.168.11.41
Swap usage: 0% IP address for docker0: 172.17.0.1
Processes: 132 IP address for cni0: 10.244.1.1
Users logged in: 0
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Tue Feb 2 05:42:40 2021 from 10.0.2.2
node2にログイン
D:\Repository\kubernetes\vagrant-kubernetes>vagrant ssh node2
Welcome to Ubuntu 18.04.5 LTS (GNU/Linux 4.15.0-135-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Tue Feb 2 06:01:03 UTC 2021
System load: 0.22 Users logged in: 0
Usage of /: 5.5% of 38.71GB IP address for enp0s3: 10.0.2.15
Memory usage: 3% IP address for enp0s8: 172.16.20.13
Swap usage: 0% IP address for enp0s9: 192.168.11.42
Processes: 132 IP address for docker0: 172.17.0.1
* Introducing self-healing high availability clusters in MicroK8s.
Simple, hardened, Kubernetes for production, from RaspberryPi to DC.
https://microk8s.io/high-availability
7 packages can be updated.
0 of these updates are security updates.
To see these additional updates run: apt list --upgradable
New release '20.04.1 LTS' available.
Run 'do-release-upgrade' to upgrade to it.
Last login: Tue Feb 2 05:40:48 2021 from 10.0.2.2
이제 ↓의 이미지가되었습니다.
후기
실은, 이번 네트워크 확인으로 여러가지 손잡고 있었다. NAT의 설정이 필요하다고 생각하고 virtualBox에서 NAT를 브릿지로 변경해 보거나 했지만, vagrant로부터의 ssh가 연결이 끊어지거나와 여러가지 일어났다.
일단, 원래로 되돌려 브리지용의 네트워크 어댑터 추가해 대처했지만, vagrant도 잘 이해하지 않으면 빠진다고 재인식했다.
※원인은 알 수 없는 w
다음 번은, kubctl나 용어에 대해 정리해 보려고 한다.
참고문헌
15Step으로 습득 Docker에서 들어가는 Kubernetes
Reference
이 문제에 관하여(kubernetes를 배우다~그 2:택내 LAN~), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다
https://qiita.com/shintoshin_se/items/9290f96821f3870f14d8
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념
(Collection and Share based on the CC Protocol.)
Reference
이 문제에 관하여(kubernetes를 배우다~그 2:택내 LAN~), 우리는 이곳에서 더 많은 자료를 발견하고 링크를 클릭하여 보았다 https://qiita.com/shintoshin_se/items/9290f96821f3870f14d8텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
우수한 개발자 콘텐츠 발견에 전념 (Collection and Share based on the CC Protocol.)