How can I use an ISO image to create an openstack image and then generate a virtual machine ?, Isoopenstack

Source: Internet
Author: User

How can I use an ISO image to create an openstack image and then generate a virtual machine ?, Isoopenstack

1. You can click "Create Image" on the dashboard's image interface. Select the ISO format as the format requirement. You can also run the following command:

Openstack image create "kolla_ocata" -- file CentOS-7-x86_64-DVD-1611.ISO -- disk-format iso -- container-format bare -- public

2. Create flavor

You can use the original flavor as needed. You can also create a new flavor on the dashboard or command line.

Openstack flavor create -- id 3 -- vcpus 2 -- ram 2048 -- disk 20 m4.nano

3. Create an instance.

Nova boot -- image kolla_ocata -- flavor 8cpu8G-disk300G -- security-groups default \

-- Availability-zone nova: computer1 -- nic net-name = test192.168.5.0 -- nic net-name = test192.168.11.0 kolla

Or use the following command

Openstack server create -- image CentOS-7-x86_64-Minimal-1511 -- flavor 4cpu4G-disk50G -- security-group default \

-- Availability-zone nova: computer1 -- nic net-id = 653139ea-e44f-437c-bed6-665df16488e6 centos7-min

4. Create a blank volume

Openstack volume create -- size -- bootable VOLUME_NAME

Note: The newton version I used does not have -- bootable. After being created, use the dashboard to change it to bootable on the interface.

5. the blank volume is attached to the instance generated in step 3 as the system disk.

You can operate on the dashboard or use the following command:

Openstack server add volume INSTANCE_NAME VOLUME_NAME -- device/dev/vda

6. Install the system

7. After installing the system, cancel the volume and contact the previous instance.

You can cancel the task on the dashboard or use the following command:

Openstack server remove volume INSTANCE_NAME VOLUME_NAME

8. view the volume ID

Openstack volume list

9 use this volume to generate an image

Openstack image create -- volume b569cdfc-05d8-4654-9113-403adf58553f IMAGE_NAME

10 use this image to generate a virtual machine

You can use the command to perform step 3 or start the image on the dashboard and enter the corresponding parameters.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.