
https://docs.openstack.org/cinder/2023.1/install/cinder-controller-install-ubuntu.html
블록 스토리지 서비스로, VM 및 베어메탈 서버에 대해 영구적인 블록 스토리지를 제공
주요 기능
- 가상 머신 및 베어메탈 서버에 대한 블록 스토리지 제공
- 다양한 백엔드 스토리지 드라이버 지원 (Ceph, LVM, NetApp 등)
- 스냅샷 생성 및 복원 기능
- 볼륨 확장 및 복제 지원
- QoS(서비스 품질) 및 정책 기반 스토리지 관리
연계
- Nova와 연계하여 VM에 블록 스토리지 볼륨 연결
- Glance와 연계하여 이미지로부터 볼륨 생성
- Keystone과 연계하여 사용자 인증 및 권한 관리
- Horizon을 통해 GUI 기반 관리 가능
mysql
CREATE DATABASE cinder;
GRANT ALL PRIVILEGES ON cinder.* TO 'cinder'@'localhost' \
IDENTIFIED BY 'openstack';
GRANT ALL PRIVILEGES ON cinder.* TO 'cinder'@'%' \
IDENTIFIED BY 'openstack';
exit
openstack user create --domain default --password-prompt cinder
User Password: openstack
Repeat User Password: openstack
openstack role add --project service --user cinder admin
openstack service create --name cinderv3 \
--description "OpenStack Block Storage" volumev3
openstack endpoint create --region RegionOne \
volumev3 public http://con01:8776/v3/%\(project_id\)s
openstack endpoint create --region RegionOne \
volumev3 internal http://con01:8776/v3/%\(project_id\)s
openstack endpoint create --region RegionOne \
volumev3 admin http://con01:8776/v3/%\(project_id\)s
apt install cinder-api cinder-scheduler
cd /etc/cinder/
cp cinder.conf cinder.conf.v0
/nfs/sed.sh cinder.conf
vi cinder.conf
[database]
connection = mysql+pymysql://cinder:openstack@con01/cinder
[DEFAULT]
transport_url = rabbit://openstack:openstack@con01
auth_strategy = keystone
my_ip = 10.0.0.1
[keystone_authtoken]
www_authenticate_uri = http://con01:5000
auth_url = http://con01:5000
memcached_servers = con01:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = cinder
password = openstack
[oslo_concurrency]
lock_path = /var/lib/cinder/tmp
su -s /bin/sh -c "cinder-manage db sync" cinder
vi /etc/nova/nova.conf
[cinder]
os_region_name = RegionOne
service nova-api restart
service cinder-scheduler restart
service apache2 restart
이 글에서는 컴퓨트 노드에 Cinder를 설치한다.
apt install lvm2 thin-provisioning-tools
cp lvm.conf lvm.conf.v0
vi /etc/lvm/lvm.conf
filter = [ "a/sda/", "a/nvme0n1/", "r/.*/"]
apt install cinder-volume tgt
cd /etc/cinder
cp cinder.conf cinder.conf.v0
/nfs/sed.sh cinder.conf
vi cinder.conf
[database]
connection = mysql+pymysql://cinder:openstack@con01/cinder
[DEFAULT]
transport_url = rabbit://openstack:openstack@con01
auth_strategy = keystone
my_ip = 10.0.0.2
enabled_backends = lvm
glance_api_servers = http://con01:9292
[keystone_authtoken]
www_authenticate_uri = http://con01:5000
auth_url = http://con01:5000
memcached_servers = con01:11211
auth_type = password
project_domain_name = default
user_domain_name = default
project_name = service
username = cinder
password = openstack
[lvm]
volume_driver = cinder.volume.drivers.lvm.LVMVolumeDriver
volume_group = cinder-volumes
target_protocol = iscsi
target_helper = tgtadm
[oslo_concurrency]
lock_path = /var/lib/cinder/tmp
service tgt restart
service cinder-volume restart