一、Train版 裸金属配置向导
1、系统环境
ansible 2.7.18
kolla-ansible 7.2.2.dev9
[root@kolla-ansible-master ~]# python --version
Python 2.7.5
[root@kolla-ansible-master ~]# cat /etc/centos-release
CentOS Linux release 7.8.2003 (Core)
[root@kolla-ansible-master ~]# docker info
Server:
Containers: 4
Running: 4
Paused: 0
Stopped: 0
Images: 180
Server Version: 19.03.12
Storage Driver: overlay2
Backing Filesystem: xfs
Supports d_type: true
Native Overlay Diff: true
Logging Driver: json-file
Cgroup Driver: cgroupfs
2、注册物理节点
3、注册节点-节点信息
4、注册节点-驱动详情
5、注册节点-驱动接口
6、注册节点-CLI
resource provider create
Create a new resource provider
openstack resource provider create
[--parent-provider <parent_provider>]
[--uuid <uuid>]
<name>
--parent-provider <parent_provider>
UUID of the parent provider. Omit for no parent. This option requires at least --os-placement-api-version 1.14.
--uuid <uuid>
UUID of the resource provider
name¶
Name of the resource provider
This command is provided by the osc-placement plugin.
[root@kolla-ansible-master ~]# openstack resource class list
+-------------------+
| name |
+-------------------+
| VCPU |
| MEMORY_MB |
| DISK_GB |
| PCI_DEVICE |
| SRIOV_NET_VF |
| NUMA_SOCKET |
| NUMA_CORE |
| NUMA_THREAD |
| NUMA_MEMORY_MB |
| IPV4_ADDRESS |
| VGPU |
| VGPU_DISPLAY_HEAD |
+-------------------+
$ export OS_PLACEMENT_API_VERSION=1.10
$ openstack allocation candidate list --resource VCPU=1
+---+------------+-------------------------+-------------------------+
| # | allocation | resource provider | inventory used/capacity |
+---+------------+-------------------------+-------------------------+
| 1 | VCPU=1 | 66bcaca9-9263-45b1-a569 | VCPU=0/128 |
| | | -ea708ff7a968 | |
+---+------------+-------------------------+-------------------------+
7、详细CLI命令 参考
ironic baremetal 裸金属环境 使用 Placement Trait 在特定物理机上启用实例_openstack placement trait-CSDN博客
Command Line Reference — osc-placement documentation
二、2024.1版 裸金属配置向导
1、系统环境
ansible-core 2.16.11
kolla-ansible 18.1.1.dev28
server:~# python3 --version
Python 3.10.12
server:~# cat /etc/os-release
PRETTY_NAME="Ubuntu 22.04.1 LTS"
NAME="Ubuntu"
VERSION_ID="22.04"
VERSION="22.04.1 LTS (Jammy Jellyfish)"
VERSION_CODENAME=jammy
server:~# docker info
Client: Docker Engine - Community
Version: 27.2.1
Context: default
Debug Mode: false
Plugins:
buildx: Docker Buildx (Docker Inc.)
Version: v0.16.2
Path: /usr/libexec/docker/cli-plugins/docker-buildx
compose: Docker Compose (Docker Inc.)
Version: v2.29.2
Path: /usr/libexec/docker/cli-plugins/docker-compose
2、容器运行情况
3、配置向导
4、注册界面
5、使用命令行CLI
openstack image create --disk-format aki --container-format aki --public \
--file /etc/kolla/config/ironic/ironic-agent.kernel deploy-vmlinuz
openstack image create --disk-format ari --container-format ari --public \
--file /etc/kolla/config/ironic/ironic-agent.initramfs deploy-initrd
创建裸金属节点
openstack baremetal node create --driver ipmi --name baremetal-node \
--driver-info ipmi_port=6230 --driver-info ipmi_username=admin \
--driver-info ipmi_password=password \
--driver-info ipmi_address=192.168.5.1 \
--resource-class baremetal-resource-class --property cpus=1 \
--property memory_mb=512 --property local_gb=1 \
--property cpu_arch=x86_64 \
--driver-info deploy_kernel=15f3c95f-d778-43ad-8e3e-9357be09ca3d \
--driver-info deploy_ramdisk=9b1e1ced-d84d-440a-b681-39c216f24121
openstack baremetal port create 52:54:00:ff:15:55 \
--node 57aa574a-5fea-4468-afcf-e2551d464412 \
--physical-network physnet1
openstack server create --image cirros --flavor my-baremetal-flavor \
--key-name mykey --network public1 demo1
三、对比结果
对比功能列表看,二者使用功能差别不大,几乎相同。只是在远程镜像下载方式上,T版仅支持tftp下载模式,2024.1版在支持tftp基础上还支行http模式下载镜像,增加了镜像服务器部署的灵活性。