SlideShare a Scribd company logo
[OpenStack]
Resource on OpenStack
김지은
yeswldms@gmail.com
Resource on OpenStack
• OpenStack은 Compute node의 자원으로 Instance의 자원을 할당
• OpenStack의 자원관련
1. Quata – 사용자별 사용가능한 논리적 자원
2. Flavors – 인스턴스 생성 단위
3. Over Commit – 가상화 기술로 물리적 리소스를 뻥튀기해서 사용할 수 있는 논리적 자원을 지원하는 기능
OpenStack Quota
• Quatas are operational limits.
• 각 Tenant 별로 클라우드 자원을 최대한 활용하기 위한 개념
• Tenant와 Tenant User 레벨에서의 논리적 개념
• Quota management for the Other Service
- OpenStack Compute Service
- OpenStack Block Storage Service
- OpenStack Networking Service
• 일반적으로 Quota는 Compute node에서 Tenant가 10개 이상의 volume 또는 1TB를 필요로 할때,
default 설정을 변경
▼ OpenStack DashBoard – Quotas Usage
OpenStack Quota
• Manage Compute Service Qoutas
nova quota-* 라는 명령으로 management
# to view&update qouta values for an existing tenant
$ nova quota-defaults
$ nova quota-class-update --key value default
 $ nova quota-class-update --instances 15 default
$ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}')
$ nova quota-show --tenant $tenant
$ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}')
$ nova quota-update --quotaName quotaValue tenantID
 $ nova quota-update --floating-ips 20 $tenant
 $ nova quota-show --tenant $tenant
$ nova help quota-update
OpenStack Quota
• Manage Compute Service Qoutas
# to view$update qouta values for an existing tenant user
“nova absolute-lismits” 명령은 현재 quota 값과 사용현황을 확인할 때 사용
$ nova absolute-limits --tenant tenantName
$ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}')
$ nova quota-show --user $tenantUser --tenant $tenant
$ nova quota-update --user $tenantUser --quotaName quotaValue $tenant
 $ nova quota-update --user $tenantUser --floating-ips 12 $tenant
 $ nova quota-show --user $tenantUser --tenant $tenant
OpenStack Quota
• Manage Compute Service Qoutas – default Quotas
▲ Compute Quota description
Quota name Description
cores Number of instance cores (VCPUs) allowed per tenant.
fixed-ips
Number of fixed IP addresses allowed per tenant. This number m
ust be equal to or greater than the number of allowed instances.
floating-ips Number of floating IP addresses allowed per tenant.
injected-file-content
-bytes
Number of content bytes allowed per injected file.
injected-file-path-by
tes
Length of injected file path.
injected-files Number of injected files allowed per tenant.
instances Number of instances allowed per tenant.
key-pairs Number of key pairs allowed per user.
metadata-items Number of metadata items allowed per instance.
ram Megabytes of instance ram allowed per tenant.
security-groups Number of security groups per tenant.
security-group-rules Number of rules per security group.
OpenStack Quota
• Manage Compute Service Qoutas – default Quotas on DashBoard
1. 관리자로 로그인
2. 관리자
3. 시스템패널
4. 시스템정보
5. 기본 Qoutas
1
2
4
3
5
OpenStack Quota
• Manage Compute Service Qoutas - test
- 설정한 Quotas 스펙에서 over되는 동작을 시도하면 오류메시지 출력과 함께 해당 작업이 수행되지 않음
- 설정한 Quotas 스펙에서 꽉 찼을경우, 버튼이 disable 되어 더 이상의 인스턴스 생성이 불가능함
OpenStack Quota
• Manage Block Storage Service Qoutas
cinder quota-* 라는 명령으로 management
▼ Block Storage Quotas
# to view qouta values
$ cinder quota-defaults TENANT_ID
$ cinder quota-show TENANT_NAME
$ cinder quota-usage tenantID
roperty name Defines the number of
gigabytes Volume gigabytes allowed for each tenant.
snapshots Volume snapshots allowed for each tenant.
volumes Volumes allowed for each tenant.
OpenStack Quota
• Manage Block Storage Service Qoutas
# to edit & update qouta values
1. Clear per-tenant quota limits
$ cinder quota-delete tenantID
2. for a new project
 /etc/cinder/cinder.conf, “quota” section
3. for a exsiting tenant
$ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}')
$ cinder quota-update --quotaName NewValue tenantID
 $ cinder quota-update --volumes 15 $tenant
 $ cinder quota-show tenant01
◀ /etc/cinder/cinder.conf
OpenStack Quota
• Manage Netwoking Service Qoutas
1. Basic quota configuration
2. Configure per-tenant quotas
Basic quota configuration
: all tenants have the same quota values
▼ neutron.conf
OpenStack Quota
• Manage Netwoking Service Qoutas
Configure per-tenant quotas
1. Set the quota_driver option in the neutron.conf
quota_driver = neutron.db.quota_db.DbQuotaDriver
(이 설정을 해주면 command API를 사용할 수 있음)
2. quotas extension
# to list the Networking extension & show information for quotas extension
$ neutron ext-list -c alias -c name
$ neutron ext-show quotas
$ neutron quota-list
$ neutron quota-show --tenant_id 6f88036c45344d9999a1f971e4882723
$ neutron quota-show
OpenStack Quota
• Manage Netwoking Service Qoutas
# Update puota values for a specified tenant
$ neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 --network 5
$ neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 --subnet 5 --port 20
$ neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 -- --floatingip 20
neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 --network 3 --subnet 3 --port 3 -- --f
loatingip 3 --router 3
# Update puota values for a specified tenant
$ neutron quota-delete --tenant_id 6f88036c45344d9999a1f971e4882723
$ Deleted quota: 6f88036c45344d9999a1f971e4882723
$ $ neutron quota-show --tenant_id 6f88036c45344d9999a1f971e4882723 (확인)
OpenStack Flavors
• Nova Computing Instance들에게 할당되는 사용가능한 하드웨어의 크기를 설정 (가상 하드웨어의 템플릿 정의)
• Instance가 생성될때 “size”로 정의
▲ default Flavors
Flavor VCPUs Disk (in GB) RAM (in MB)
m1.tiny 1 1 512
m1.small 1 20 2048
m1.medium 2 40 4096
m1.large 4 80 8192
m1.xlarge 8 160 16384
OpenStack Flavors
• 최적의 Flavor (예시)
물리 자원 : 4cores, 60GB memory
1. cpu HyperThreading 지원 시로 가정 : 4cores * 2 = 8cores vCPU
2. ram 60GB(사실은 60GB – 오버헤드GB값) = 8cores * 7.5GB (ram 7.5GB per core)
3. overcommit : (default 1:16)
- 8cores * 16 = 64cores
- 7.5GB / 16 = 480MB
 64 vCPU, 480MB per VM
Nice Flavors
: 64 vCPU, RAM 60GB(480MB per vCPU), local storage 10GB
1vCPU / 480MB / 10GB(small) ◀ default(Basic)
2vCPU / 960MB / 20GB(medium)
4vCPU / 1.8GB / 40GB(large)
8vCPU / 3.6GB / 80GB(extra large)
16vCPU / 7.2GB / 160GB(extra extra large)
OpenStack Flavors
# Create a flavor
$ nova flavor-list
$ nova flavor-create FLAVOR_NAME FLAVOR_ID RAM_IN_MB ROOT_DISK_IN_GB NUMBER_OF_VCPUS
 $ nova flavor-create --is-public true m1.extra_tiny auto 256 0 1 --rxtx-factor .1
$ nova help flavor-create
$ nova flavor-access-add FLAVOR TENANT_ID
# Delete a flavor
$ nova flavor-delete FLAVOR_ID
OpenStack OverCommit
• Compute nodes에서 CPU와 RAM에 대한 overcommit을 지원
• 인스턴스들에게 물리적자원보다 더 많은 자원을 할당 할 수 있음
• OpenStack 클라우드 환경에서 Instance들의 퍼포먼스 감소를 허용하고 많은 수의 인스턴스들을 운용할 수 있음
▼ default overcommit
CPU allocation ratio – 16:1
RAM allocation ratio – 1.5:1
DISK allocation ratio – 1:1
• Compute node에서의 생성 가능한 instance의 수
(OR * PC) / VC
OR - CPU overcommit ratio(virtual cores per physical core)
PC - Number of physical cores
VS – Number of cores per instances
OpenStack OverCommit
• nova.conf (*-allocation-ratio)
cpu_allocation_ratio = 16.0
ram_allocation_ratio = 1.5
disk_allocation_ratio = 1.0
• Overcommit & Nova Scheduler
- Overcommit은 Nova Scheduler에서 관리
- Scheduler는 Filter라는 개념으로 Scheduling을 수행
OverCommit과 관련한 Filter
CoreFilter (cpu_allocation_ratio)
RamFilter (ram_allocation_ratio
DiskFilter (disk_allocation_ratio)
• Configure
CPU overcommitting ^2로 사용 (1:2, 1:4, 1:8 …)
RAM overcommitting 메모리 overcommitting은 사용하지 않는 것을 추천  memory o
Disk overcommitting 사용을 추천하지 않음
• OverCommit 고려사항
OpenStack 레벨에서의 overcommitting
KVM 레벨에서의 overcommitting
libvirt 레벨에서의 overcommitting
• 간단 Test
▲ OpenStack DashBoard
메모리 over : OverCommit된 메모리 23GB를 넘기자 인스턴스 생성시, 오류가 발생
OpenStack OverCommit
OpenStack OverCommit
• 예시
▼ hardware spec
▼ OverCommited Resource
호스트 OS CPU RAM DISK Hypervisor 구분
Test PC X 4 cores 16GB 1.8TB EXSi 5.5 Host
Openstack
Controller node
Ubuntu
srever
14.04 LTS
4 cores 16GB 80GB
KVM
(libvirt)
Guest
Network node 1 cores 2GB 80GB Guest
Compute node 4 cores 60GB 80GB Guest
Block storage 1 cores 2GB 61GB Guest
vCPU
: 4(physical) * 16 = 64개 (losical)
Memory
: 15(phsical) * 1.5 = 23GB (losical)
Disk
: 1.8T(phsical) * 1 = 1.8TB (losical)
OpenStack OverCommit
▼ Command 확인
$ nova hypervisor-show 1
OpenStack OverCommit
• 예외사항 및 참고
http://docs.fedoraproject.org/en-US/Fedora/13/html/Virtualization_Guide/sect-Virtualization-Tips_and_tricks-
Overcommitting_with_KVM.html
https://doc.opensuse.org/products/draft/SLES/SLES-kvm_sd_draft/book.kvm.html
http://serverascode.com/2013/02/20/overcommitting-with-kvm.html
OpenStack Scheduling & Filter
• Compute는 nova-scheduler를 사용하여 compute 및 volume서비스를 수행
• 여러가지 옵션이 있음
▲ nova
OpenStack Scheduling & Filter
• Scheduler - Nova-scheduler는 Queue와 central DB를 통하여 다른 nova component들과 통신
• Queue
- Queue는 scheduling에 있어 필수적임
- 주기적으로 모든 compute node는 nova-scheduler에서 가용자원 및 하드웨어 사양에 대해 Queue를 통해 전달
- Compute Scheduler는 Filter Scheduler의 configure를 진행
AvailabilityZoneFilter
– Are in the requested availability zone
RamFilter
– Have sufficient RAM available
ComputeFilter
– capable of servicing the reqquest
Nova VM Provisioning ▶
• Filter Schedulter - Filtering과 weighting으로 새 인스턴스가 생성 될 수 있도록 하는 정보를 만듬
OpenStack Scheduling & Filter
• Filtering & Weights
- 필터 속성을 사용하여 Filtering을 수행
- 표준 필터 클래스 (nova.scheduler.filters)
- Filter Scheduler는 weights hosts 베이스로 동작하며 scheduler_weight_classe 옵션을 configure
* Weights hosts Base : RamWeigher 큰 weight인 호스트가 우선
- 반복적인 filtering과 weighting을 찾는 일은 리소스가 들어가므로 이를 적절히 조절하는 기능도 있음
- Filter Algorithm을 직접 만들어 적용 할 수 있음
OpenStack Scheduling & Filter
• http://docs.openstack.org/icehouse/training-guides/content/operator-computer-node.html
• http://docs.openstack.org/trunk/config-reference/content/section_compute-scheduler.html
OpenStack Scaling
• HORIZONTAL SCAILING
• Designed to be gorizontally saclable, Itself
• Scale-out과 Load Balancing시에 Message Bus를 통해 그룹간에 통신
• Flavors는 자원효율적인 Scale-out을 수행하도록 도옴
▼ OpenStack default flavors
• http://docs.openstack.org/openstack-ops/content/scaling.html
Flavor VCPUs Disk (in GB) RAM (in MB)
m1.tiny 1 1 512
m1.small 1 20 2048
m1.medium 2 40 4096
m1.large 4 80 8192
m1.xlarge 8 160 16384
마지막 업데이트 일자
: 2015-03-25
이 문서는 OpenStack IceHouse 버전을 기준으로 작성되었습니다.

More Related Content

PDF
Ceph issue 해결 사례
PPTX
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
PDF
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
PDF
[2018] 오픈스택 5년 운영의 경험
PPTX
클라우드 환경을 위한 네트워크 가상화와 NSX(기초편)
PDF
ログ+メトリック+トレースの組み合わせで構築する一元的なオブザーバビリティ
PDF
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
PDF
[OpenInfra Days Korea 2018] Day 2 - CEPH 운영자를 위한 Object Storage Performance T...
Ceph issue 해결 사례
[OpenStack 하반기 스터디] Interoperability with ML2: LinuxBridge, OVS and SDN
[개인 프로젝트] 쿠버네티스를 이용한 개발환경 자동화 구축시스템 - 프로토타입
[2018] 오픈스택 5년 운영의 경험
클라우드 환경을 위한 네트워크 가상화와 NSX(기초편)
ログ+メトリック+トレースの組み合わせで構築する一元的なオブザーバビリティ
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
[OpenInfra Days Korea 2018] Day 2 - CEPH 운영자를 위한 Object Storage Performance T...

What's hot (20)

PPTX
コンテナネットワーキング(CNI)最前線
PDF
Kubernetes internals (Kubernetes 해부하기)
PDF
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
PDF
Persistent Storage with Containers with Kubernetes & OpenShift
PDF
Deep dive into Kubernetes Networking
PDF
Scouter와 influx db – grafana 연동 가이드
PDF
OpenStack超入門シリーズ Novaのディスク周りあれこれ
PDF
Hands-On Introduction to Kubernetes at LISA17
PPTX
쿠버네티스 ( Kubernetes ) 소개 자료
PDF
SDN입문 (Overlay and Underlay)
PDF
[오픈소스컨설팅]쿠버네티스를 활용한 개발환경 구축
PDF
[야생의 땅: 듀랑고] 서버 아키텍처 - SPOF 없는 분산 MMORPG 서버
PDF
OpenStack超入門シリーズ いまさら聞けないSwiftの使い方
PDF
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
PDF
NDC14 범용 게임 서버 프레임워크 디자인 및 테크닉
PPTX
Ceph Performance and Sizing Guide
PDF
오픈스택 기반 클라우드 서비스 구축 방안 및 사례
PPTX
Kubernetes #1 intro
PPTX
Kubernetes
PDF
[오픈소스컨설팅] 스카우터 사용자 가이드 2020
コンテナネットワーキング(CNI)最前線
Kubernetes internals (Kubernetes 해부하기)
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
Persistent Storage with Containers with Kubernetes & OpenShift
Deep dive into Kubernetes Networking
Scouter와 influx db – grafana 연동 가이드
OpenStack超入門シリーズ Novaのディスク周りあれこれ
Hands-On Introduction to Kubernetes at LISA17
쿠버네티스 ( Kubernetes ) 소개 자료
SDN입문 (Overlay and Underlay)
[오픈소스컨설팅]쿠버네티스를 활용한 개발환경 구축
[야생의 땅: 듀랑고] 서버 아키텍처 - SPOF 없는 분산 MMORPG 서버
OpenStack超入門シリーズ いまさら聞けないSwiftの使い方
[OpenStack] 공개 소프트웨어 오픈스택 입문 & 파헤치기
NDC14 범용 게임 서버 프레임워크 디자인 및 테크닉
Ceph Performance and Sizing Guide
오픈스택 기반 클라우드 서비스 구축 방안 및 사례
Kubernetes #1 intro
Kubernetes
[오픈소스컨설팅] 스카우터 사용자 가이드 2020
Ad

Viewers also liked (20)

PDF
High Availability from the DevOps side - OpenStack Summit Portland
PPTX
Openstack ha
PPTX
Watcher, a Resource Manager for OpenStack: Plans for the N-release and Beyond
PDF
Orchestrating Docker with OpenStack
PPTX
Openstackha 130925132534-phpapp02
PDF
OpenStack Resource Scheduling
PDF
Openstack Scheduler and Scalability Issue
PDF
Fred explains IPv6
PPTX
OpenStack Tokyo Talk Application Data Protection Service
PDF
IPv6 Best Practice
PPTX
Dragon flow neutron lightning talk
PPTX
OpenStack Dragonflow shenzhen and Hangzhou meetups
PDF
KrDAG 오픈소스를 활용하여 웹블로그 만들기_김지은_201603
PPTX
Dragonflow 01 2016 TLV meetup
PPTX
Open stack HA - Theory to Reality
PDF
150416 OpenStack Networking with Neutron Jieun, Kim
PDF
Build the OpenStack Cloud with Neutron Networing, IceHouse
PPTX
Dragonflow Austin Summit Talk
PDF
집단지성프로그래밍 05. 최적화(optimization) 김지은_20150522
PPTX
OpenStack Neutron Dragonflow l3 SDNmeetup
High Availability from the DevOps side - OpenStack Summit Portland
Openstack ha
Watcher, a Resource Manager for OpenStack: Plans for the N-release and Beyond
Orchestrating Docker with OpenStack
Openstackha 130925132534-phpapp02
OpenStack Resource Scheduling
Openstack Scheduler and Scalability Issue
Fred explains IPv6
OpenStack Tokyo Talk Application Data Protection Service
IPv6 Best Practice
Dragon flow neutron lightning talk
OpenStack Dragonflow shenzhen and Hangzhou meetups
KrDAG 오픈소스를 활용하여 웹블로그 만들기_김지은_201603
Dragonflow 01 2016 TLV meetup
Open stack HA - Theory to Reality
150416 OpenStack Networking with Neutron Jieun, Kim
Build the OpenStack Cloud with Neutron Networing, IceHouse
Dragonflow Austin Summit Talk
집단지성프로그래밍 05. 최적화(optimization) 김지은_20150522
OpenStack Neutron Dragonflow l3 SDNmeetup
Ad

Similar to resource on openstack (20)

PDF
Red Hat OpenStack 17 저자직강+스터디그룹_3주차
PDF
OpenStack 인스턴스 간략 사용자_매뉴얼(liberty)_v1
PDF
Red Hat OpenStack 17 저자직강+스터디그룹_2주차
PDF
OpenStack DevStack Install - 2부 (Multi-nodes)
PDF
Red Hat OpenStack 17 저자직강+스터디그룹_1주차
PDF
Openstack live migration
PDF
오픈 소스 클라우드 플랫폼 분석
PDF
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
PDF
Red Hat OpenStack 17 저자직강+스터디그룹_5주차
PDF
KT 안재석 박사 - 오픈 소스 기반 클라우드 컴퓨팅 솔루션 open stack 이야기 (2011Y05M28D)
PDF
제2회 난공불락 오픈소스 인프라 세미나 Kubernetes
PDF
[오픈테크넷서밋2022] 국내 PaaS(Kubernetes) Best Practice 및 DevOps 환경 구축 사례.pdf
PDF
클라우드 컴퓨팅 기반 기술과 오픈스택(Kvm) 기반 Provisioning
PDF
쉽고 빠르게 접하는 오픈스택
PDF
15minutes to create_vm
PDF
오픈스택: 구석구석 파헤쳐보기
PDF
OpenStack DevStack Install - 1부 (All-in-one)
PDF
오픈스택 멀티노드 설치 후기
PDF
테스트
PDF
Journey for provisioning 20k over rbd volumes to kubernetes with openstack
Red Hat OpenStack 17 저자직강+스터디그룹_3주차
OpenStack 인스턴스 간략 사용자_매뉴얼(liberty)_v1
Red Hat OpenStack 17 저자직강+스터디그룹_2주차
OpenStack DevStack Install - 2부 (Multi-nodes)
Red Hat OpenStack 17 저자직강+스터디그룹_1주차
Openstack live migration
오픈 소스 클라우드 플랫폼 분석
OpenStack을 중심으로 한 오픈 소스 & 상용 하이브리드 클라우드
Red Hat OpenStack 17 저자직강+스터디그룹_5주차
KT 안재석 박사 - 오픈 소스 기반 클라우드 컴퓨팅 솔루션 open stack 이야기 (2011Y05M28D)
제2회 난공불락 오픈소스 인프라 세미나 Kubernetes
[오픈테크넷서밋2022] 국내 PaaS(Kubernetes) Best Practice 및 DevOps 환경 구축 사례.pdf
클라우드 컴퓨팅 기반 기술과 오픈스택(Kvm) 기반 Provisioning
쉽고 빠르게 접하는 오픈스택
15minutes to create_vm
오픈스택: 구석구석 파헤쳐보기
OpenStack DevStack Install - 1부 (All-in-one)
오픈스택 멀티노드 설치 후기
테스트
Journey for provisioning 20k over rbd volumes to kubernetes with openstack

More from jieun kim (6)

PDF
OpenStack Korea 2015 상반기스터디(devops) 스크립트로 오픈스택 설치하기 20150728
PDF
150326 openstack, glance 김지은
PDF
집단지성프로그래밍 05. 최적화(kayak.ipynb) 김지은_20150522
PDF
집단지성프로그래밍 05. 최적화(optimization.ipynb) 김지은_20150522
PDF
Ryu with OpenFlow 1.3, REST API
PDF
Ryu with OpenFlow 1.3, Traffic Monitor
OpenStack Korea 2015 상반기스터디(devops) 스크립트로 오픈스택 설치하기 20150728
150326 openstack, glance 김지은
집단지성프로그래밍 05. 최적화(kayak.ipynb) 김지은_20150522
집단지성프로그래밍 05. 최적화(optimization.ipynb) 김지은_20150522
Ryu with OpenFlow 1.3, REST API
Ryu with OpenFlow 1.3, Traffic Monitor

resource on openstack

  • 2. Resource on OpenStack • OpenStack은 Compute node의 자원으로 Instance의 자원을 할당 • OpenStack의 자원관련 1. Quata – 사용자별 사용가능한 논리적 자원 2. Flavors – 인스턴스 생성 단위 3. Over Commit – 가상화 기술로 물리적 리소스를 뻥튀기해서 사용할 수 있는 논리적 자원을 지원하는 기능
  • 3. OpenStack Quota • Quatas are operational limits. • 각 Tenant 별로 클라우드 자원을 최대한 활용하기 위한 개념 • Tenant와 Tenant User 레벨에서의 논리적 개념 • Quota management for the Other Service - OpenStack Compute Service - OpenStack Block Storage Service - OpenStack Networking Service • 일반적으로 Quota는 Compute node에서 Tenant가 10개 이상의 volume 또는 1TB를 필요로 할때, default 설정을 변경 ▼ OpenStack DashBoard – Quotas Usage
  • 4. OpenStack Quota • Manage Compute Service Qoutas nova quota-* 라는 명령으로 management # to view&update qouta values for an existing tenant $ nova quota-defaults $ nova quota-class-update --key value default  $ nova quota-class-update --instances 15 default $ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}') $ nova quota-show --tenant $tenant $ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}') $ nova quota-update --quotaName quotaValue tenantID  $ nova quota-update --floating-ips 20 $tenant  $ nova quota-show --tenant $tenant $ nova help quota-update
  • 5. OpenStack Quota • Manage Compute Service Qoutas # to view$update qouta values for an existing tenant user “nova absolute-lismits” 명령은 현재 quota 값과 사용현황을 확인할 때 사용 $ nova absolute-limits --tenant tenantName $ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}') $ nova quota-show --user $tenantUser --tenant $tenant $ nova quota-update --user $tenantUser --quotaName quotaValue $tenant  $ nova quota-update --user $tenantUser --floating-ips 12 $tenant  $ nova quota-show --user $tenantUser --tenant $tenant
  • 6. OpenStack Quota • Manage Compute Service Qoutas – default Quotas ▲ Compute Quota description Quota name Description cores Number of instance cores (VCPUs) allowed per tenant. fixed-ips Number of fixed IP addresses allowed per tenant. This number m ust be equal to or greater than the number of allowed instances. floating-ips Number of floating IP addresses allowed per tenant. injected-file-content -bytes Number of content bytes allowed per injected file. injected-file-path-by tes Length of injected file path. injected-files Number of injected files allowed per tenant. instances Number of instances allowed per tenant. key-pairs Number of key pairs allowed per user. metadata-items Number of metadata items allowed per instance. ram Megabytes of instance ram allowed per tenant. security-groups Number of security groups per tenant. security-group-rules Number of rules per security group.
  • 7. OpenStack Quota • Manage Compute Service Qoutas – default Quotas on DashBoard 1. 관리자로 로그인 2. 관리자 3. 시스템패널 4. 시스템정보 5. 기본 Qoutas 1 2 4 3 5
  • 8. OpenStack Quota • Manage Compute Service Qoutas - test - 설정한 Quotas 스펙에서 over되는 동작을 시도하면 오류메시지 출력과 함께 해당 작업이 수행되지 않음 - 설정한 Quotas 스펙에서 꽉 찼을경우, 버튼이 disable 되어 더 이상의 인스턴스 생성이 불가능함
  • 9. OpenStack Quota • Manage Block Storage Service Qoutas cinder quota-* 라는 명령으로 management ▼ Block Storage Quotas # to view qouta values $ cinder quota-defaults TENANT_ID $ cinder quota-show TENANT_NAME $ cinder quota-usage tenantID roperty name Defines the number of gigabytes Volume gigabytes allowed for each tenant. snapshots Volume snapshots allowed for each tenant. volumes Volumes allowed for each tenant.
  • 10. OpenStack Quota • Manage Block Storage Service Qoutas # to edit & update qouta values 1. Clear per-tenant quota limits $ cinder quota-delete tenantID 2. for a new project  /etc/cinder/cinder.conf, “quota” section 3. for a exsiting tenant $ tenant=$(keystone tenant-list | awk '/tenantName/ {print $2}') $ cinder quota-update --quotaName NewValue tenantID  $ cinder quota-update --volumes 15 $tenant  $ cinder quota-show tenant01 ◀ /etc/cinder/cinder.conf
  • 11. OpenStack Quota • Manage Netwoking Service Qoutas 1. Basic quota configuration 2. Configure per-tenant quotas Basic quota configuration : all tenants have the same quota values ▼ neutron.conf
  • 12. OpenStack Quota • Manage Netwoking Service Qoutas Configure per-tenant quotas 1. Set the quota_driver option in the neutron.conf quota_driver = neutron.db.quota_db.DbQuotaDriver (이 설정을 해주면 command API를 사용할 수 있음) 2. quotas extension # to list the Networking extension & show information for quotas extension $ neutron ext-list -c alias -c name $ neutron ext-show quotas $ neutron quota-list $ neutron quota-show --tenant_id 6f88036c45344d9999a1f971e4882723 $ neutron quota-show
  • 13. OpenStack Quota • Manage Netwoking Service Qoutas # Update puota values for a specified tenant $ neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 --network 5 $ neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 --subnet 5 --port 20 $ neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 -- --floatingip 20 neutron quota-update --tenant_id 6f88036c45344d9999a1f971e4882723 --network 3 --subnet 3 --port 3 -- --f loatingip 3 --router 3 # Update puota values for a specified tenant $ neutron quota-delete --tenant_id 6f88036c45344d9999a1f971e4882723 $ Deleted quota: 6f88036c45344d9999a1f971e4882723 $ $ neutron quota-show --tenant_id 6f88036c45344d9999a1f971e4882723 (확인)
  • 14. OpenStack Flavors • Nova Computing Instance들에게 할당되는 사용가능한 하드웨어의 크기를 설정 (가상 하드웨어의 템플릿 정의) • Instance가 생성될때 “size”로 정의 ▲ default Flavors Flavor VCPUs Disk (in GB) RAM (in MB) m1.tiny 1 1 512 m1.small 1 20 2048 m1.medium 2 40 4096 m1.large 4 80 8192 m1.xlarge 8 160 16384
  • 15. OpenStack Flavors • 최적의 Flavor (예시) 물리 자원 : 4cores, 60GB memory 1. cpu HyperThreading 지원 시로 가정 : 4cores * 2 = 8cores vCPU 2. ram 60GB(사실은 60GB – 오버헤드GB값) = 8cores * 7.5GB (ram 7.5GB per core) 3. overcommit : (default 1:16) - 8cores * 16 = 64cores - 7.5GB / 16 = 480MB  64 vCPU, 480MB per VM Nice Flavors : 64 vCPU, RAM 60GB(480MB per vCPU), local storage 10GB 1vCPU / 480MB / 10GB(small) ◀ default(Basic) 2vCPU / 960MB / 20GB(medium) 4vCPU / 1.8GB / 40GB(large) 8vCPU / 3.6GB / 80GB(extra large) 16vCPU / 7.2GB / 160GB(extra extra large)
  • 16. OpenStack Flavors # Create a flavor $ nova flavor-list $ nova flavor-create FLAVOR_NAME FLAVOR_ID RAM_IN_MB ROOT_DISK_IN_GB NUMBER_OF_VCPUS  $ nova flavor-create --is-public true m1.extra_tiny auto 256 0 1 --rxtx-factor .1 $ nova help flavor-create $ nova flavor-access-add FLAVOR TENANT_ID # Delete a flavor $ nova flavor-delete FLAVOR_ID
  • 17. OpenStack OverCommit • Compute nodes에서 CPU와 RAM에 대한 overcommit을 지원 • 인스턴스들에게 물리적자원보다 더 많은 자원을 할당 할 수 있음 • OpenStack 클라우드 환경에서 Instance들의 퍼포먼스 감소를 허용하고 많은 수의 인스턴스들을 운용할 수 있음 ▼ default overcommit CPU allocation ratio – 16:1 RAM allocation ratio – 1.5:1 DISK allocation ratio – 1:1 • Compute node에서의 생성 가능한 instance의 수 (OR * PC) / VC OR - CPU overcommit ratio(virtual cores per physical core) PC - Number of physical cores VS – Number of cores per instances
  • 18. OpenStack OverCommit • nova.conf (*-allocation-ratio) cpu_allocation_ratio = 16.0 ram_allocation_ratio = 1.5 disk_allocation_ratio = 1.0 • Overcommit & Nova Scheduler - Overcommit은 Nova Scheduler에서 관리 - Scheduler는 Filter라는 개념으로 Scheduling을 수행 OverCommit과 관련한 Filter CoreFilter (cpu_allocation_ratio) RamFilter (ram_allocation_ratio DiskFilter (disk_allocation_ratio) • Configure CPU overcommitting ^2로 사용 (1:2, 1:4, 1:8 …) RAM overcommitting 메모리 overcommitting은 사용하지 않는 것을 추천  memory o Disk overcommitting 사용을 추천하지 않음
  • 19. • OverCommit 고려사항 OpenStack 레벨에서의 overcommitting KVM 레벨에서의 overcommitting libvirt 레벨에서의 overcommitting • 간단 Test ▲ OpenStack DashBoard 메모리 over : OverCommit된 메모리 23GB를 넘기자 인스턴스 생성시, 오류가 발생 OpenStack OverCommit
  • 20. OpenStack OverCommit • 예시 ▼ hardware spec ▼ OverCommited Resource 호스트 OS CPU RAM DISK Hypervisor 구분 Test PC X 4 cores 16GB 1.8TB EXSi 5.5 Host Openstack Controller node Ubuntu srever 14.04 LTS 4 cores 16GB 80GB KVM (libvirt) Guest Network node 1 cores 2GB 80GB Guest Compute node 4 cores 60GB 80GB Guest Block storage 1 cores 2GB 61GB Guest vCPU : 4(physical) * 16 = 64개 (losical) Memory : 15(phsical) * 1.5 = 23GB (losical) Disk : 1.8T(phsical) * 1 = 1.8TB (losical)
  • 21. OpenStack OverCommit ▼ Command 확인 $ nova hypervisor-show 1
  • 22. OpenStack OverCommit • 예외사항 및 참고 http://docs.fedoraproject.org/en-US/Fedora/13/html/Virtualization_Guide/sect-Virtualization-Tips_and_tricks- Overcommitting_with_KVM.html https://doc.opensuse.org/products/draft/SLES/SLES-kvm_sd_draft/book.kvm.html http://serverascode.com/2013/02/20/overcommitting-with-kvm.html
  • 23. OpenStack Scheduling & Filter • Compute는 nova-scheduler를 사용하여 compute 및 volume서비스를 수행 • 여러가지 옵션이 있음 ▲ nova
  • 24. OpenStack Scheduling & Filter • Scheduler - Nova-scheduler는 Queue와 central DB를 통하여 다른 nova component들과 통신 • Queue - Queue는 scheduling에 있어 필수적임 - 주기적으로 모든 compute node는 nova-scheduler에서 가용자원 및 하드웨어 사양에 대해 Queue를 통해 전달 - Compute Scheduler는 Filter Scheduler의 configure를 진행 AvailabilityZoneFilter – Are in the requested availability zone RamFilter – Have sufficient RAM available ComputeFilter – capable of servicing the reqquest Nova VM Provisioning ▶ • Filter Schedulter - Filtering과 weighting으로 새 인스턴스가 생성 될 수 있도록 하는 정보를 만듬
  • 25. OpenStack Scheduling & Filter • Filtering & Weights - 필터 속성을 사용하여 Filtering을 수행 - 표준 필터 클래스 (nova.scheduler.filters) - Filter Scheduler는 weights hosts 베이스로 동작하며 scheduler_weight_classe 옵션을 configure * Weights hosts Base : RamWeigher 큰 weight인 호스트가 우선 - 반복적인 filtering과 weighting을 찾는 일은 리소스가 들어가므로 이를 적절히 조절하는 기능도 있음 - Filter Algorithm을 직접 만들어 적용 할 수 있음
  • 26. OpenStack Scheduling & Filter • http://docs.openstack.org/icehouse/training-guides/content/operator-computer-node.html • http://docs.openstack.org/trunk/config-reference/content/section_compute-scheduler.html
  • 27. OpenStack Scaling • HORIZONTAL SCAILING • Designed to be gorizontally saclable, Itself • Scale-out과 Load Balancing시에 Message Bus를 통해 그룹간에 통신 • Flavors는 자원효율적인 Scale-out을 수행하도록 도옴 ▼ OpenStack default flavors • http://docs.openstack.org/openstack-ops/content/scaling.html Flavor VCPUs Disk (in GB) RAM (in MB) m1.tiny 1 1 512 m1.small 1 20 2048 m1.medium 2 40 4096 m1.large 4 80 8192 m1.xlarge 8 160 16384
  • 28. 마지막 업데이트 일자 : 2015-03-25 이 문서는 OpenStack IceHouse 버전을 기준으로 작성되었습니다.