Networking
Deploy OpenStack dengan Juju dan MAAS
Instalasi Juju, konfigurasi cloud MAAS, penambahan credential, bootstrap controller, pembuatan model OpenStack, deployment bundle OpenStack, konfigurasi Keystone dan console Nova, akses Horizon, penambahan machine/unit, penghapusan machine/unit, cleanup environment, hingga command operasional Juju untuk model, controller, cloud, dan service machine.
Tutorial ini merapihkan catatan deploy OpenStack berbasis Juju charm dan MAAS.
1. Disable IPv6 Ubuntu
Edit /etc/sysctl.conf:
sudo nano /etc/sysctl.conf
Tambahkan:
net.ipv6.conf.all.disable_ipv6 = 1
net.ipv6.conf.default.disable_ipv6 = 1
net.ipv6.conf.lo.disable_ipv6 = 1
Apply konfigurasi:
sudo sysctl -p
2. Install Juju
sudo snap install juju --classic
3. Tambahkan Cloud MAAS ke Juju
juju add-cloud --local
Input contoh:
select cloud type : maas
Enter a name.... : maas
End Point : http://<MAAS_IP>:5240/MAAS
Ambil API key MAAS:
sudo maas apikey --username=admin
Tambahkan credential:
juju add-credential maas
Input contoh:
Enter credential name: maas
Replace local credential? (y/N): y
Select region [any region, credential is not region specific]: default
Using auth-type "oauth1".
4. Bootstrap Controller Juju
nohup juju bootstrap maas maas-controller --debug --bootstrap-series=jammy --credential maas &
Alternatif:
juju bootstrap maas maas-controller --debug
5. Buat Model OpenStack
juju add-model openstack
juju add-model --config default-series=jammy openstack
6. Deploy OpenStack Bundle
Deploy dari charm store:
juju deploy cs:bundle/openstack-base-80
juju deploy cs:bundle/openstack-base-79
juju deploy cs:bundle/openstack-base-65
Deploy dari repository bundle:
git clone https://github.com/openstack-charmers/openstack-bundles
cd /home/<USER>/openstack-bundles/stable/openstack-base
juju add-model openstack
juju deploy ./bundle.yaml --debug
7. Konfigurasi Awal Keystone dan Console
juju config keystone admin-password=<PASSWORD>
juju config nova-cloud-controller console-access-protocol=novnc
Cek password admin:
juju run --unit keystone/0 leader-get admin_passwd
8. Akses Horizon
http://<HORIZON_IP>/horizon
9. Tambah Machine dan Unit
Tambah machine by hostname dari MAAS:
sudo juju add-machine node10.maas --series="bionic"
juju add-machine node05.maas --series="jammy"
juju add-machine node06.maas --series="jammy"
juju add-machine node06.maas --series="focal"
sudo juju add-machine node13.maas --series="bionic" --debug
Tambah unit Ceph OSD dan Nova Compute:
sudo juju add-unit --to 28 ceph-osd
sudo juju add-unit --to 28 nova-compute
juju add-unit --to 4 ceph-osd
juju add-unit --to 5 ceph-osd
juju add-unit --to 28 nova-compute
juju add-unit --to 4 nova-compute
sudo juju add-unit --to 8 ceph-osd
sudo juju add-unit --to 8 nova-compute
sudo juju add-unit --to 2 ceph
10. Remove Machine dan Unit
sudo juju remove-machine 27 --force
sudo juju remove-machine 28 --force
sudo juju remove-machine 31 --force
juju remove-machine 5 --force
juju remove-unit postgresql/2
sudo juju remove-unit ceph-osd/10
sudo juju remove-unit ceph/3
sudo juju remove-machine 21
juju remove-unit ceph-osd/1
11. Clean OpenStack/Juju Environment
SSH ke controller:
ssh -i .local/share/juju/ssh/juju_id_rsa ubuntu@<CONTROLLER_IP>
Hapus controller, credential, dan cloud:
juju kill-controller maas-controller
juju remove-credential maas maas
juju remove-cloud maas
12. Command Operasional Model dan Controller
juju models
juju destroy-model [nama model]
juju controllers
juju destroy-controller [nama controller]
juju clouds
juju remove-cloud [nama cloud]
13. Menyalakan Service Juju Machine Manual
sudo systemctl start jujud-machine-1/lxd/2*
sudo systemctl start jujud-machine-1/lxd/1*
sudo systemctl start jujud-machine-1/lxd/0*
sudo systemctl start jujud-machine-1*
openstackjujumaascloud deploymentubuntubare metalbootstrap controllerjuju modelopenstack bundlekeystonenovahorizonceph osdnova computeprovisioningcloud infrastructuretroubleshootingsystemctl
Published by Nirantara
Nirantara is an Indonesian Enterprise AI company specializing in Enterprise AI, RAG, Intelligent Search, and AI Automation. Article written by jsturana.