Notes of Openstack Essex Installation (II)
We begin the second part with starting an instance. Firstly, let download an image from the internet with the command:
Then upload it to glance:
$glance add name=”Ubuntu 12.04 cloudimg amd64″ is_public=true container_format=ovf disk_format=qcow2 < precise-server-cloudimg-amd64-disk1.img
We also can find it on the dashboard web interface:
Using the web interface to create a keypair, which later is used to access your instance. Note that you also can complete this operation by command, although it maybe less comfortable. You will be prompted to save the keypair (with the extension as pem) when click the Create Keypair button.
Now launch the instances by pointing out its hardware config:
Floating ips are used to associate with the instance so that you can access it publicly:
$sudo nova-manage floating create –ip_range=192.168.230.224/27
Although you properly see the following alike under the tab VNC of the instance, but you really cannot login with the user name ubuntu because the those reasons:
1.You can only access the instance by using private key, not password.
2.You cannot ping or ssh to the instance deal to the rejection of the default security group.
Now using SecureCRT to ssh to the instance with the keypair you’ve already stored:
Or if you prefer putty to do that, let using puttygen to generate the private key from the .pem file at first:
After enabling the root user, you will be able to log in at the VNC tab with the root user name and it’s password
Volume can also be created on the web interface, however you need to wait until the operation totally accomplishes so that you can attach it to an instance, unless its status fixedly is attaching and you cannot delete it either. In this case, you need to use mysql command to change its status to active or error before deleting it.
Sometime you cannot delete an instance because it doesn’t really exist (for example you restart the server without terminating the instance beforehand).
To make it easier to fix the error, let install phpmyadmin($sudo apt-get install phpmyadmin). The first step of the installation progress is entering the root’s password – mysqlsecret in my case. Log in the address 192.168.230.41/phpmyadmin, and remove the instance record, you will be prompted that there are some foreign keys linked to the instance，let delete those reference records before deleting the instance.