1. 마스터 노드 우분투 설치
일반 적인 설치 방법에 따름
2. IP 고정
vi /etc/netplan/50-cloud-init.yaml
network:
version: 2
renderer: networkd
ethernets:
enp7s0:
dhcp4: no
addresses:
- 192.168.2.100/24
routes:
- to: default
via: 192.168.2.1
nameservers:
addresses:
- 8.8.8.8
- 8.8.4.4
3. 기존 라즈베리파이5 호스트 네임 변경
3-1. 기존 hostname 확인
$ hostname
db1
$ hostnamectl
Static hostname: db1
Icon name: computer
Machine ID: a9e06a10a6b344d784f2653671249681
Boot ID: 41f22ead5d2f4bfdac458a7aa20d13fd
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 6.12.47+rpt-rpi-2712
Architecture: arm64
$
3.2. hostname 변경
$ hostnamectl set-hostname node1
$ vi /etc/hosts
...
127.0.0.1 localhost
127.0.1.1 node1
~
~
~
3.3. 변경된 hostname 확인
$ hostname
node1
$ hostnamectl
Static hostname: node1
Icon name: computer
Machine ID: a9e06a10a6b344d784f2653671249681
Boot ID: 41f22ead5d2f4bfdac458a7aa20d13fd
Operating System: Debian GNU/Linux 12 (bookworm)
Kernel: Linux 6.12.47+rpt-rpi-2712
Architecture: arm64
$
3.4. 재부팅 후 변경된 hostname 확인
기존 사용하던 라즈베리파이 5에 OS가 Ubuntu가 아닌 Raspberry OS (Devian bookworm) 이 설치 되어 있어서
Ubuntu Server 25.10 (64bit) 로 재설치 (아래 5. 라즈메리파이 5 Ubuntu 설치 챕터 참고)
4. 패키지 업데이트
$ sudo apt update -y
... 생략 ...
$ sudo apt upgrade -y
... 생략 ...
5. 라즈베리파이 5 Ubuntu 설치
Worker 노드로 이용할 라즈베리파이 5에 Ubuntu 설치는 아래 내용에 따로 정리 했습니다.
https://opensrc.tistory.com/281
라즈베리파이 5 OS 설치 (Raspberry Pi 5 OS Install with Raspberry Pi Imager v2.0.0)
1. 준비물- 라즈베리파이 5- Micro SD (32G 이상 권장) 2. 라즈베리파이 Imager 설치https://www.raspberrypi.com/software/ Raspberry Pi software – Raspberry PiFrom our operating system to our GitHub repos, explore the software that powers
opensrc.tistory.com
6. 모든 노드에 /etc/hosts 수정
모든 노드에서 hostname 을 인식 할 수 있도록 아래 내용 추가
root@master:~# cat /etc/hosts
127.0.0.1 localhost
192.168.2.100 master
192.168.2.101 node1
192.168.2.102 node2
192.168.2.103 node3
... 생략 ...
모든 노드에서 상호간 hostname 으로 ping 확인
$ ping master
$ ping node1
$ ping node2
$ ping node3
여기까지 쿠버네티스 마스터 노드와 워커노드 3개를 설치하기 위한 기본 준비는 완료 되었습니다.
끝.
'UNIX-Networking' 카테고리의 다른 글
| 쿠버네티스 설치하기 #3 - Container Runtime(containerd) 설치 및 설정 (0) | 2025.12.19 |
|---|---|
| 쿠버네티스 설치하기 #2 - Swap, Congrol Groups 확인 (0) | 2025.12.18 |
| [Ubuntu] 시간 동기화 서버 chrony 설치 (1) | 2025.07.20 |
| [AWS] EC2 추가, SK브로드밴드 이용하는 경우 outbound 22(ssh) port 차단 문제 (0) | 2025.04.29 |
| crontab 명령 중복 실행 방지 (0) | 2024.05.30 |