以下所有操作在baremetal节点执行。
vi /etc/ironic/ironic.conf
1 2 3 4 | [database] # The SQLAlchemy connection string used to connect to the # database (string value) connection = mysql+pymysql://ironic:PASSWORD@controller/ironic?charset=utf8 |
为方便理解,本文将涉及到的密码全部以“PASSWORD”代替,请用户根据实际情况进行修改。此处将PASSWORD修改为ironic数据库的密码。
1 2 | [DEFAULT] transport_url = rabbit://RPC_USER:RPC_PASSWORD@RPC_HOST:RPC_PORT/ |
此处RPC_USER为RabbitMQ服务的OpenStack用户,RPC_PASSWORD为RabbitMQ服务用户对应的密码,RPC_HOST为RabbitMQ消息队列所在节点的管理IP地址,RPC_PORT为RabbitMQ服务的端口,RabbitMQ消息详细信息请参见安装RabbitMQ。本指导中为:transport_url = rabbit://openstack:123456@controller:5672/。
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 | [DEFAULT] rpc_transport = json-rpc [json_rpc] # Authentication type to load (string value) auth_type = password # Authentication URL (string value) auth_url = http://controller:5000/ # Username (string value) username = ironic # User's password (string value) password = PASSWORD # Project name to scope to (string value) project_name = service # Domain ID containing project (string value) project_domain_id = default # User's domain id (string value) user_domain_id = default |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 | [DEFAULT] auth_strategy = keystone [keystone_authtoken] # Authentication type to load (string value) auth_type = password # Complete public Identity API endpoint (string value) www_authenticate_uri = http://controller:5000 # Complete admin Identity API endpoint. (string value) auth_url = http://controller:5000 # Service username. (string value) username = ironic # Service account password. (string value) password = PASSWORD # Service tenant name. (string value) project_name = service # Domain name containing project (string value) project_domain_name = Default # User's domain name (string value) user_domain_name = Default |
1 | ironic-dbsync --config-file /etc/ironic/ironic.conf create_schema |
1 2 | systemctl restart openstack-ironic-api systemctl status openstack-ironic-api |