do sync before fusermount to avoid busyness

Fix bug #1013689

Change-Id: I8ae786e105c08e1b5011a1b2a1dac048a710a1cb
vm state and task state management

partially implements bp task-management
fixes bug 997867

also see http://wiki.openstack.org/VMState

Refactored the following API/state:
* rebuild
* migrate
* resize
* start
* stop
* delete
* soft delete
* rework sync_power_state in compute/manager.

fix broken tests, add transition diagram in dot

Change-Id: I3c5a97508a6dad7175fba12828bd3fa6ef1e50ee
Call libvirt_volume_driver with right mountpoint

 * fixes bug 1013782
 * includes failing test
 * fixes tests for live migration

Change-Id: I8f95c6baa7aad878af19d5d8b8b34531a4a43885
Fixes ram_allocation_ratio based over subscription

Fix for bug 1016273

Change-Id: I7f7b227e71e93b4bcded150791fb0b9e9df98e4c
Make tgtadm the default iscsi user-land helper.

Most modern Linux distrobutions have tgtadm as their
default iscsi user-land helper. This includes Ubuntu,
Fedora, RHEL, SuSe, and others.

Make it default for nova as well. No change is
required for devstack since its the default as well.

Change-Id: I3f5204f08bfd9ef41eda2df7aa6bb35559516213
Signed-off-by: Chuck Short <chuck.short@canonical.com>
metadata: cleanup pubkey representation

The previous code provided a '_name' entry in a dict to represent
this, but then appended "=_name" to the key rather than populating
_name with the full value to be rendered.

This just changes the value in '_name' for public key to be
'0=keyname' rather than 'keyname'.  It makes the rendering simpler by
just using the
_name.

It also adds a test for this strange behavior of the metadata service.

Change-Id: I3ef67d85354bf7ac8abaaf900ddfdd2e945aa9af
Fix import order of openstack.common

Change-Id: Id80026ad9eb78c6d9a6bcae33e26ac8a4fdd6680
Another killfilter test fix for Fedora 17.

Updates killfilter test to use /usr/bin/sleep in addition to /bin/sleep.

Fixes LP Bug #1017585.

Change-Id: Ied0a8837fb0e7ca7fa3629859fbd67f71e5d80dc
Merge "Fixes ram_allocation_ratio based over subscription"
Merge "Fix import order of openstack.common"
Merge "vm state and task state management"
Add full test environment.

Add a tox environment that will install all of the optional
packages and which will run with system site packages enabled
so that we pick up those tests as well. This should allow us
to run expansive tests on jenkins that aren't normally required
locally, but which are possible.

Change-Id: Iabd61874061e24950d4d2082a2fba158b4601624
Merge "Call libvirt_volume_driver with right mountpoint"
Migrate existing routes from flat_interface

Right now, any routes that exist on flat_interface (other than the default
route) get lost when we set up the bridge. This patch migrates them over
to avoid losing that connectivity. It does so by using 'ip route' instead
of 'route', which is much easier to script and is consistent with other
use of iproute2 tools in linux_net.py.

Bug 962822

Change-Id: I7d9e8e05169f2f87e8481595397c02fd3a3612f4
Merge "Set libvirt_nonblocking to true by default for Folsom."
Merge "Make tgtadm the default iscsi user-land helper."
fix libvirt get_memory_mb_total() with xen

Commit 5b93a576 failed to remove the 'staticmethod'
decorator from the method, to allow it to access
object variables.

Also there is no need to have the libvirt getInfo() call
be xen specific.  In the LXC/QEMU/UML drivers this call
uses GNULIB's physmem module, which is cross-OS portable.

Change-Id: I565eda78f6c468cf6bd227756cfc068725069218
Fix hacking.py failures...

test_xenapi hacking fix and volume_utils unneeded import

Change-Id: I503cf0780850aba90d7ba8665d83bff08fb2504a
Merge "Another killfilter test fix for Fedora 17."
Re-factor instance DB creation

This patch speeds up the DB creation process considerably in deployments
with a considerable amount of instances.  It also cleans up a lot of the
code which ends up creating the instance DB record.

The biggest improvement in this patch is removing unnecessary joins in
security_groups DB calls.  This also reduces the number of DB calls
needed to create an instance DB record in general.

Side effect of this patch is the default 'display_name' for an instance
when it (or hostname) is not specified is now 'Server <uuid>' vs
'Server <id>'.  Because of the use of 'id', it required creating the DB
record, then updating the record later after we new the 'id'.  This is
gone.

Fixes bug 1017722

Change-Id: I9b7d48644a7abe075545c2c11399351b6a37939c