{"id":1158,"date":"2015-08-16T17:13:41","date_gmt":"2015-08-16T21:13:41","guid":{"rendered":"http:\/\/blog.domb.net\/?p=1158"},"modified":"2015-08-20T09:14:05","modified_gmt":"2015-08-20T13:14:05","slug":"red-hat-openstack-platform-7-director-cli-simple-install-part-2","status":"publish","type":"post","link":"https:\/\/blog.domb.net\/?p=1158","title":{"rendered":"Red Hat OpenStack Platform 7 director (OSP director)  cli simple install part 2"},"content":{"rendered":"<p>Part 2 of the blog series will show you how you can register the nodes to your OSP director via command line create flavors and deploy a simple non HA OpenStack environment. <\/p>\n<p>1. To register the blades I created the following json file. Please keep in mind that if you use hp blades with ilo2 you will have to use the default pxe_ipmitool. The MAC address you see in the json is the mac address from the interface you would like to boot from. <\/p>\n<pre>\r\n{\r\n    \"nodes\":[\r\n        {\r\n            \"mac\":[\r\n            \"1C:C1:DE:EB:FD:46\"\r\n            ],\r\n            \"cpu\":\"12\",\r\n            \"memory\":\"32768\",\r\n            \"disk\":\"60\",\r\n            \"arch\":\"x86_64\",\r\n            \"pm_type\":\"pxe_ipmitool\",\r\n            \"pm_user\":\"admin\",\r\n            \"pm_password\":\"redhat\",\r\n            \"pm_addr\":\"192.168.1.7\"\r\n        },\r\n        {\r\n            \"mac\":[\r\n            \"1C:C1:DE:71:B6:BE\"\r\n            ],\r\n            \"cpu\":\"4\",\r\n            \"memory\":\"16384\",\r\n            \"disk\":\"60\",\r\n            \"arch\":\"x86_64\",\r\n            \"pm_type\":\"pxe_ipmitool\",\r\n            \"pm_user\":\"admin\",\r\n            \"pm_password\":\"redhat\",\r\n            \"pm_addr\":\"192.168.1.18\"\r\n        }\r\n    ]\r\n}\r\n<\/pre>\n<p>2. Import the node definitions into OSP director<\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack baremetal import --json ~\/blades.json\r\n<\/pre>\n<p>3. Assign the kernel and ramdisk to all nodes defined in the blades.json file<\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack baremetal configure boot\r\n<\/pre>\n<p>4. Check if everything got imported correctly <\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack baremetal list\r\n+--------------------------------------+------+---------------+-------------+-----------------+-------------+\r\n| UUID                                 | Name | Instance UUID | Power State | Provision State | Maintenance |\r\n+--------------------------------------+------+---------------+-------------+-----------------+-------------+\r\n| f1bbb294-c0b0-45bc-8431-66bf025ab5b7 | None | None          | power off   | available       | False       |\r\n| 489bd260-be3f-400b-9580-84c0b8bd79e6 | None | None          | power off   | available       | False       |\r\n+--------------------------------------+------+---------------+-------------+-----------------+-------------+\r\n<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.domb.net\/wp-content\/uploads\/nodesbeforediscovery.png\" alt=\"nodesbeforediscovery\" width=\"1914\" height=\"684\" class=\"aligncenter size-full wp-image-1159\" srcset=\"https:\/\/blog.domb.net\/wp-content\/uploads\/nodesbeforediscovery.png 1914w, https:\/\/blog.domb.net\/wp-content\/uploads\/nodesbeforediscovery-300x107.png 300w, https:\/\/blog.domb.net\/wp-content\/uploads\/nodesbeforediscovery-1024x366.png 1024w\" sizes=\"auto, (max-width: 1914px) 100vw, 1914px\" \/><\/p>\n<p>5. Lets inspect the nodes. IPMI will start the nodes and boot them into discovery mode.<\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack baremetal introspection bulk start\r\nSetting available nodes to manageable...\r\nStarting introspection of node: f1bbb294-c0b0-45bc-8431-66bf025ab5b7\r\nStarting introspection of node: 489bd260-be3f-400b-9580-84c0b8bd79e6\r\nWaiting for discovery to finish...\r\nDiscovery for UUID 489bd260-be3f-400b-9580-84c0b8bd79e6 finished successfully.\r\nDiscovery for UUID f1bbb294-c0b0-45bc-8431-66bf025ab5b7 finished successfully.\r\nSetting manageable nodes to available...\r\nNode f1bbb294-c0b0-45bc-8431-66bf025ab5b7 has been set to available.\r\nNode 489bd260-be3f-400b-9580-84c0b8bd79e6 has been set to available.\r\nDiscovery completed.\r\n<\/pre>\n<p><strong>Booting into discovery<br \/>\n<\/strong><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.domb.net\/wp-content\/uploads\/discoveryboot.png\" alt=\"discoveryboot\" width=\"2217\" height=\"951\" class=\"aligncenter size-full wp-image-1161\" srcset=\"https:\/\/blog.domb.net\/wp-content\/uploads\/discoveryboot.png 2217w, https:\/\/blog.domb.net\/wp-content\/uploads\/discoveryboot-300x129.png 300w, https:\/\/blog.domb.net\/wp-content\/uploads\/discoveryboot-1024x439.png 1024w\" sizes=\"auto, (max-width: 2217px) 100vw, 2217px\" \/><\/p>\n<p><strong>Discovered hosts<\/strong><br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.domb.net\/wp-content\/uploads\/discovered.png\" alt=\"discovered\" width=\"505\" height=\"325\" class=\"aligncenter size-full wp-image-1164\" \/><\/p>\n<p>6. Create the flavor for the test scenario (we only create one flavor for all hosts)<\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack flavor create --id auto --ram 4096 --disk 40 --vcpus 1 baremetal\r\n<\/pre>\n<p>7. Set the boot mode for the flavors to local<\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack flavor set --property \"capabilities:boot_option\"=\"local\" baremetal\r\n<\/pre>\n<p>8. Now we are ready to deploy. <\/p>\n<pre>\r\n[stack@ospdirector ~]$ openstack overcloud deploy --templates --control-scale 1 --compute-scale 1 --ntp-server 198.55.111.50 --neutron-network-type vxlan --neutron-tunnel-types vxlan --timeout 90 --debug\r\n<\/pre>\n<p>9. Look at the progress<\/p>\n<pre>\r\n[stack@ospdirector ~]$ heat stack-list --show-nested\r\n+--------------------------------------+----------------------------------------------------------------------------+--------------------+----------------------+--------------------------------------+\r\n| id                                   | stack_name                                                                 | stack_status       | creation_time        | parent                               |\r\n+--------------------------------------+----------------------------------------------------------------------------+--------------------+----------------------+--------------------------------------+\r\n| 33bfb7e0-9b34-4250-a004-af37f608d2cf | overcloud                                                                  | CREATE_IN_PROGRESS | 2015-08-16T18:22:35Z | None                                 |\r\n| 435dc7f7-3308-4807-8904-d5442508711e | overcloud-Networks-32rvmmduffhu                                            | CREATE_COMPLETE    | 2015-08-16T18:22:38Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| 30a1079e-64b2-4d58-9c8e-dcbf224c652a | overcloud-Networks-32rvmmduffhu-StorageMgmtNetwork-wtonza4e5bw2            | CREATE_COMPLETE    | 2015-08-16T18:22:39Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| 4479ccff-415c-489e-afbe-b36b480ed9f5 | overcloud-Networks-32rvmmduffhu-TenantNetwork-gimrl3excqx4                 | CREATE_COMPLETE    | 2015-08-16T18:22:39Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| b33d3efa-3fb7-4a29-ba75-f9cc84959a87 | overcloud-VipConfig-rgs2gbejbezm                                           | CREATE_COMPLETE    | 2015-08-16T18:22:40Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| b75050ad-4cc3-4ab9-8593-6059e4f0943a | overcloud-Networks-32rvmmduffhu-InternalNetwork-dcpc2r7ode6m               | CREATE_COMPLETE    | 2015-08-16T18:22:40Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| cb907b21-4747-450f-85c4-d471fc7ffd7b | overcloud-Networks-32rvmmduffhu-ExternalNetwork-3vnkwpojgwor               | CREATE_COMPLETE    | 2015-08-16T18:22:40Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| 3b9278f9-bb05-4c61-8536-85f910079242 | overcloud-Networks-32rvmmduffhu-StorageNetwork-tziih5yvnz4s                | CREATE_COMPLETE    | 2015-08-16T18:22:41Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| 3179955a-13e2-4ebb-982d-497871913366 | overcloud-ObjectStorage-r5rdi6pu43u3                                       | CREATE_COMPLETE    | 2015-08-16T18:22:44Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| c91c36f0-9bb6-474c-afe4-74b36b778e5f | overcloud-CephStorage-ntsvvt75psbh                                         | CREATE_COMPLETE    | 2015-08-16T18:22:45Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| 36716f1f-d619-47d7-aab3-d69edcd79cc0 | overcloud-InternalApiVirtualIP-lohuosudzibc                                | CREATE_COMPLETE    | 2015-08-16T18:22:47Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| 35e6781f-56f9-46fc-8d73-0ba59125db73 | overcloud-RedisVirtualIP-vsp633woaqcn                                      | CREATE_COMPLETE    | 2015-08-16T18:22:49Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| dfda39da-99e2-4860-831e-73b698137ece | overcloud-StorageMgmtVirtualIP-bmyldzizjmpa                                | CREATE_COMPLETE    | 2015-08-16T18:22:50Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| 10e18542-be81-4b1b-90e4-7a1b9254fbe9 | overcloud-StorageVirtualIP-iifyqfbosjwn                                    | CREATE_COMPLETE    | 2015-08-16T18:22:51Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| bf13367e-817b-4d15-a13a-95ea6d8b694b | overcloud-PublicVirtualIP-zkdwrd25sdaa                                     | CREATE_COMPLETE    | 2015-08-16T18:22:51Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| c6980d62-ac58-40f8-b29f-273dfcb0e345 | overcloud-VipMap-7vlmqgpxatrv                                              | CREATE_COMPLETE    | 2015-08-16T18:22:55Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| 80ed4867-a727-4b0f-bd53-81c894c951eb | overcloud-Compute-cv2ixk53yem3                                             | CREATE_IN_PROGRESS | 2015-08-16T18:22:59Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| da6466ff-1693-459e-804a-e1dab4132eb1 | overcloud-BlockStorage-vo4sim7ab6uo                                        | CREATE_COMPLETE    | 2015-08-16T18:23:00Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| e8b807d5-2226-4cb9-abe9-f47fe8e7458e | overcloud-Controller-e6xv26hhop7f                                          | CREATE_IN_PROGRESS | 2015-08-16T18:23:03Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| c37de593-9b60-4ac3-9fe4-edc7bd39912b | overcloud-Compute-cv2ixk53yem3-0-nwy2d42aixyb-NodeUserData-axvx7ksn3izx    | CREATE_COMPLETE    | 2015-08-16T18:23:04Z | d0b5a90c-d67a-4cc8-879f-9da1664b7d5e |\r\n| d0b5a90c-d67a-4cc8-879f-9da1664b7d5e | overcloud-Compute-cv2ixk53yem3-0-nwy2d42aixyb                              | CREATE_IN_PROGRESS | 2015-08-16T18:23:04Z | 80ed4867-a727-4b0f-bd53-81c894c951eb |\r\n| 47b5b32c-4135-4010-a3ff-688f8679e7bb | overcloud-Compute-cv2ixk53yem3-0-nwy2d42aixyb-UpdateConfig-fwtn3xtant57    | CREATE_COMPLETE    | 2015-08-16T18:23:05Z | d0b5a90c-d67a-4cc8-879f-9da1664b7d5e |\r\n| 3ca61f9f-64ca-4fa3-87bc-17ca875f2109 | overcloud-Controller-e6xv26hhop7f-0-gr4rkg43icqq-UpdateConfig-bvymvawh4jed | CREATE_COMPLETE    | 2015-08-16T18:23:08Z | fac7ac12-06b9-41f3-9c41-52cf880c744f |\r\n| fac7ac12-06b9-41f3-9c41-52cf880c744f | overcloud-Controller-e6xv26hhop7f-0-gr4rkg43icqq                           | CREATE_IN_PROGRESS | 2015-08-16T18:23:08Z | e8b807d5-2226-4cb9-abe9-f47fe8e7458e |\r\n| 098431d0-9ea7-4f52-babb-273d147db8b1 | overcloud-Controller-e6xv26hhop7f-0-gr4rkg43icqq-NodeUserData-c45ewhuiziez | CREATE_COMPLETE    | 2015-08-16T18:23:09Z | fac7ac12-06b9-41f3-9c41-52cf880c744f |\r\n+--------------------------------------+----------------------------------------------------------------------------+--------------------+----------------------+--------------------------------------+\r\n<\/pre>\n<p>10. During the install you will see the following screen if you look at the ilo<br \/>\n<img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.domb.net\/wp-content\/uploads\/duringinstall.png\" alt=\"duringinstall\" width=\"1074\" height=\"934\" class=\"aligncenter size-full wp-image-1170\" srcset=\"https:\/\/blog.domb.net\/wp-content\/uploads\/duringinstall.png 1074w, https:\/\/blog.domb.net\/wp-content\/uploads\/duringinstall-300x261.png 300w, https:\/\/blog.domb.net\/wp-content\/uploads\/duringinstall-1024x891.png 1024w\" sizes=\"auto, (max-width: 1074px) 100vw, 1074px\" \/><\/p>\n<pre>\r\n[stack@ospdirector ~]$ heat stack-list --show-nested\r\n+--------------------------------------+---------------------------------------------------------------------------------------------------------------+-----------------+----------------------+--------------------------------------+\r\n| id                                   | stack_name                                                                                                    | stack_status    | creation_time        | parent                               |\r\n+--------------------------------------+---------------------------------------------------------------------------------------------------------------+-----------------+----------------------+--------------------------------------+\r\n| 33bfb7e0-9b34-4250-a004-af37f608d2cf | overcloud                                                                                                     | CREATE_COMPLETE | 2015-08-16T18:22:35Z | None                                 |\r\n| 435dc7f7-3308-4807-8904-d5442508711e | overcloud-Networks-32rvmmduffhu                                                                               | CREATE_COMPLETE | 2015-08-16T18:22:38Z | 33bfb7e0-9b34-4250-a004-af37f608d2cf |\r\n| 30a1079e-64b2-4d58-9c8e-dcbf224c652a | overcloud-Networks-32rvmmduffhu-StorageMgmtNetwork-wtonza4e5bw2                                               | CREATE_COMPLETE | 2015-08-16T18:22:39Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| 4479ccff-415c-489e-afbe-b36b480ed9f5 | overcloud-Networks-32rvmmduffhu-TenantNetwork-gimrl3excqx4                                                    | CREATE_COMPLETE | 2015-08-16T18:22:39Z | 435dc7f7-3308-4807-8904-d5442508711e |\r\n| b33d3efa-3fb7-4a29-ba75-f9cc84959a87 | overcloud-VipConfig-rgs2gbejbezm                                                                              \r\n+--------------------------------------+---------------------------------------------------------------------------------------------------------------+-----------------+----------------------+--------------------------------------+\r\n<\/pre>\n<pre>\r\nDEBUG: os_cloud_config.keystone Creating endpoint for service 094cc12c3d7f43f1b99e08ef121485b7.\r\nDEBUG: keystoneclient.session REQ: curl -g -i -X POST http:\/\/192.168.2.14:35357\/v2.0\/endpoints -H \"User-Agent: python-keystoneclient\" -H \"Content-Type: application\/json\" -H \"Accept: application\/json\" -H \"X-Auth-Token: {SHA1}def0eb731b8fbbc104161221df9b9139962a817b\" -d '{\"endpoint\": {\"adminurl\": \"http:\/\/192.168.2.12:9696\/\", \"service_id\": \"094cc12c3d7f43f1b99e08ef121485b7\", \"region\": \"regionOne\", \"internalurl\": \"http:\/\/192.168.2.12:9696\/\", \"publicurl\": \"http:\/\/192.168.2.14:9696\/\"}}'\r\nDEBUG: keystoneclient.session RESP: [200] content-length: 256 vary: X-Auth-Token connection: keep-alive date: Sun, 16 Aug 2015 18:55:14 GMT content-type: application\/json x-openstack-request-id: req-3fe1be7f-27f2-4700-b616-4988854ebd07 \r\nRESP BODY: {\"endpoint\": {\"adminurl\": \"http:\/\/192.168.2.12:9696\/\", \"region\": \"regionOne\", \"internalurl\": \"http:\/\/192.168.2.12:9696\/\", \"service_id\": \"094cc12c3d7f43f1b99e08ef121485b7\", \"id\": \"9aa2e2f02d8b423d81711df5fe60f663\", \"publicurl\": \"http:\/\/192.168.2.14:9696\/\"}}\r\n\r\nDEBUG: os_cloud_config.utils.clients Creating nova client.\r\nOvercloud Endpoint: http:\/\/192.168.2.14:5000\/v2.0\/\r\n<strong>Overcloud Deployed<\/strong>\r\nDEBUG: openstackclient.shell clean_up DeployOvercloud\r\n\r\n<\/pre>\n<p><img loading=\"lazy\" decoding=\"async\" src=\"http:\/\/blog.domb.net\/wp-content\/uploads\/doneosp.png\" alt=\"doneosp\" width=\"1920\" height=\"952\" class=\"aligncenter size-full wp-image-1174\" srcset=\"https:\/\/blog.domb.net\/wp-content\/uploads\/doneosp.png 1920w, https:\/\/blog.domb.net\/wp-content\/uploads\/doneosp-300x149.png 300w, https:\/\/blog.domb.net\/wp-content\/uploads\/doneosp-1024x508.png 1024w\" sizes=\"auto, (max-width: 1920px) 100vw, 1920px\" \/><\/p>\n<p>11. If you would like to login to your overcloud instances you have to source the overcloud.rc file which you find in stacks home directory. <\/p>\n<pre>\r\n[stack@ospdirector ~]$ source ~\/overcloud.rc\r\n[stack@ospdirector ~]$ ssh heat-admin@192.168.2.14\r\nLast login: Sun Aug 16 17:03:31 2015 from 192.168.2.2\r\n[heat-admin@<strong>overcloud-controller-0<\/strong> ~]$\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Part 2 of the blog series will show you how you can register the nodes to your OSP director via command line create flavors and deploy a simple non HA OpenStack environment. 1. To register the blades I created the following json file. Please keep in mind that if you use hp blades with ilo2&#8230;<\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_themeisle_gutenberg_block_has_review":false,"footnotes":""},"categories":[36],"tags":[45,43,44,46],"class_list":["post-1158","post","type-post","status-publish","format-standard","hentry","category-openstack","tag-ironic","tag-osp-director","tag-osp7","tag-tripleo"],"_links":{"self":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts\/1158","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1158"}],"version-history":[{"count":17,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts\/1158\/revisions"}],"predecessor-version":[{"id":1181,"href":"https:\/\/blog.domb.net\/index.php?rest_route=\/wp\/v2\/posts\/1158\/revisions\/1181"}],"wp:attachment":[{"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1158"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1158"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.domb.net\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1158"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}