Jump to: navigation, search


Revision as of 10:06, 2 November 2012 by Hvolkmer (talk) (Added more info about development)


OpenStack/SmartOS Compute

This is a work-in-progress page about OpenStack and SmartOS.

Some helpers

Getting an SmartOS imager in OpenStack

On a SmartOS host:

imgadm update
imgadm import f9e4be48-9466-11e1-bc41-9f993f5dff36
zfs snapshot zones/f9e4be48-9466-11e1-bc41-9f993f5dff36@now
zfs send zones/f9e4be48-9466-11e1-bc41-9f993f5dff36@now > /zones/workspace/smartos.img

and than:

glance image-create --name 'smartos' --is-public 'true' --container-format 'bare' --disk-format 'raw' --property 'zone=true' < /zones/workspace/smartos.img

Getting the Code

The code is currently not in the mainline code base. The latest version is available at https://github.com/hvolkmer/nova/tree/smartosfolsom

Once the code is mature enough it should be easy to integrate the code into the main.

Setting up an environment

There is a setup script that you can use to create an environment; similar to devstack but focussed on SmartOS: https://github.com/hvolkmer/openstack-smartos

This is a work in progess. YMMV. Additions welcome.

This Metsch also has a setup script.

Running the metadata service

1. Add these options to compute.conf: metadata_listen= and metadata_listen_port=80 2. Configure metadata interface like this:

dladm create-vnic -l e1000g0 meta0
ifconfig meta0 plumb
ifconfig meta0
ifconfig meta0 up

3. Then start /openstack/nova/bin/nova-api-metadata --config-file=/openstack/cfg/compute.conf in the global (compute) zone

4. When booting VMs I currently force the default route IP to be the IP of the compute zone, so that the metadata IP is reachable

Next development steps

As Basic VM handling is working now the following dev steps should happen:

  • add unit tests to fixate the current VM start/stop behaviour for SmartOS
  • add networking manager based on the VLANManager but integrate with vmadm/crossbow instead of the Linux way