zoukankan      html  css  js  c++  java
  • 如何通过密钥验证的方式登录镜像

    Running an Instance

    Step 1: Visit the Dashboard

    Log in to the Openstack dashboard at http://CONTROL_NODE/dashboard - the username is "demo". The password can be found in the file keystonerc_demo in the /root/ directory of the control node.

    Note: make sure you use the "demo" username here.

    Step 2: Enable SSH on your default security group.

    Once logged in to the OpenStack dashboard, click the "Project" tab in the left-side navigation menu, and then click "Access & Security" under the heading "Compute."

    Access security.png

    Under the "Security Groups" heading, click the "Edit Rules" button for the "default" security group. Click the "Add Rule" button, and in the resulting dialog, enter "22" in the "Port" field, and then click the "Add" button.

    Step 3: Create or import a key pair.

    In the left-side navigation menu, click "Access & Security" under the heading "Compute." In the main portion of the screen, click the tab labeled "Keypairs," and choose either to "Create Keypair" or "Import Keypair." The "Create Keypair" dialog will prompt you to supply a keypair name before downloading a private key to your client.

    The "Import Keypair" option will prompt you to provide a name and a public key to use with an existing private key on your client. For name, choose something to identify that key (like your username, for example) and for key, use the contents of your public key file, usually in ~/.ssh/id_rsa.pub or ~/.ssh/id_dsa.pub on the machine from which you will be ssh-ing in.

    Step 4: Add an image.

    In the left-side navigation menu, click "Images & Snapshots" under the heading "Manage Compute." Click the "Create Image" button, located in the upper-right portion of the screen. In the resulting dialog box, enter "Fedora19" in the "Name" field, "http://cloud.fedoraproject.org/fedora-19.x86_64.qcow2" in the "Image Location" field, choose "QCOW2" from the "Format" drop-down menu, leave the "Minimum Disk" and "Minimum Ram" fields blank, leave the "Public" box unchecked, and click the "Create Image" button.

    For a collection of links to alternative cloud-ready images, check out image resources.

    Step 5: Launch the instance.

    In the main portion of the screen, under the "Images" heading, click the "Launch" button for the "F19" image. In the resulting dialog, provide a name in the "Instance Name" field, and click the "Launch" button.

    Step 6: Associate Floating IP

    In the main portion of the screen, under the "Instances" heading, click the "More" button, followed by the "Associate Floating IP" link for the instance you just launched. You should see both public and private IP addresses listed in the "IP Address" column for your instance.

    For additional details, please read how to set a floating IP range.

    Step 7: SSH to Your Instance

    Using the key pair file from step 3, ssh into the running vm using its floating ip address:

    $ ssh -l root -i my_key_pair.pem floating_ip_address
  • 相关阅读:
    启动django报错
    celery简单使用
    git简单使用
    selinux干扰mysql启动
    python操作xml文件时,带有^M符号
    获取服务器内网地址
    WebStorm激活
    linux nohup python 后台运行无输出问题
    安装FTP
    sql server还原数据库代码
  • 原文地址:https://www.cnblogs.com/IvanChen/p/4489482.html
Copyright © 2011-2022 走看看