openstack高可用集群10-更改配額限制(quata)以及用戶配額


1:quota相關配置:
1.1:查看當前配額:
[root@node1 ~]# neutron quota-show admin
neutron CLI is deprecated and will be removed in the future. Use openstack CLI instead.
+---------------------+-------+
| Field               | Value |
+---------------------+-------+
| floatingip          | 50    |
| network             | 100   |
| port                | 500   |
| rbac_policy         | 10    |
| router              | 10    |
| security_group      | 10    |
| security_group_rule | 100   |
| subnet              | 100   |
| subnetpool          | -1    |
+---------------------+-------+
1.2:web端修改項目配額:
1.2.1:查看openstack配置文件(/etc/httpd/conf.d/openstack-dashboard.conf)是否開啟配額限制:
1.2.2:修改web端配額:
1.3:修改/etc/neutron/neutron.conf:
1.3.1:控制端:
[quotas]
quota_network = 200
quota_subnet = 200
quota_port = 5000
quota_driver = neutron.db.quota.driver.DbQuotaDriver
quota_router = 100
quota_floatingip = 1000
quota_security_group = 100
quota_security_group_rule = 1000
#重啟neutron服務
[root@node1 ~]# systemctl restart openstack-nova-api.service  neutron-server.service  neutron-linuxbridge-agent.service neutron-dhcp-agent.service neutron-metadata-agent.service
15.1.3.2:計算節點:
[quotas]
quota_network = 200
quota_subnet = 200
quota_port = 5000
quota_driver = neutron.db.quota.driver.DbQuotaDriver
quota_router = 100
quota_floatingip = 50
quota_security_group = 100
quota_security_group_rule = 1000
#重啟neutron服務
[root@node3 ~]# systemctl  restart neutron-linuxbridge-agent
1.4:驗證當前配額:
 
2:修改用戶配額
2.1:單獨調整單個用戶的配額
 
2.2:修改默認配額
查看當前默認值
[root@node1 ~]# nova quota-defaults
+----------------------+-------+
| Quota                | Limit |
+----------------------+-------+
| instances            | 10    |
| cores                | 20    |
| ram                  | 51200 |
| metadata_items       | 128   |
| key_pairs            | 100   |
| server_groups        | 10    |
| server_group_members | 10    |
+----------------------+-------+
[root@node1 ~]# nova quota-class-update default --instances 20
[root@node1 ~]# nova quota-defaults
+----------------------+-------+
| Quota                | Limit |
+----------------------+-------+
| instances            | 20    |
| cores                | 20    |
| ram                  | 51200 |
| metadata_items       | 128   |
| key_pairs            | 100   |
| server_groups        | 10    |
| server_group_members | 10    |
+----------------------+-------+
 
常用命令
nova quota-class-update default --instances 20
nova quota-class-update default --cores 80
nova quota-class-update default --ram 512000
nova quota-class-update default --metadata_items 1280
nova quota-class-update default --key_pairs 1000
nova quota-class-update default --server_groups 80
nova quota-class-update default --server_group_members 80
 
 作者:Dexter_Wang   工作崗位:某互聯網公司資深雲計算與存儲工程師  聯系郵箱:993852246@qq.com


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM