I have installed Openstack on a VM using devstack and have juju installed on my Ubuntu 12.10 laptop. I'm working with a fresh install of both Openstack and Juju with not VMs created. I bootstrapped my Openstack environment with a success message. But then, any deploy or subsequest bootstrap commands produce this error: 2013-02-09 11:56:52,050 ERROR Unexpected 400: '{"badRequest": {"message": "Security group is still in use", "code": 400}}' The verbose output shows that a security group deletion was attempted: 2013-02-09 11:53:12,161 DEBUG access compute @ http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/os-security-groups/3 2013-02-09 11:53:12,161 DEBUG openstack: DELETE 'http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/os-security-groups/3' 2013-02-09 11:53:12,488 DEBUG openstack: 400 '{"badRequest": {"message": "Security group is still in use", "code": 400}}' My question is, if security groups are no longer deleted, but reused, then why does this output show an attempt to delete? Here is the entire verbose output and stack trace for a juju bootstrap command. 2013-02-09 11:53:10,715 DEBUG Initializing juju bootstrap runtime 2013-02-09 11:53:10,739 WARNING OpenStack identity service not using secure transport 2013-02-09 11:53:10,739 DEBUG openstack: using auth-mode 'userpass' with http://192.168.0.100:5000/v2.0/ 2013-02-09 11:53:10,739 WARNING S3 API calls not using secure transport 2013-02-09 11:53:11,108 DEBUG openstack: authenticated til u'2013-02-10T16:51:51Z' 2013-02-09 11:53:11,109 WARNING OpenStack compute service not using secure transport 2013-02-09 11:53:11,109 DEBUG openstack: GET 'http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors' 2013-02-09 11:53:11,328 DEBUG openstack: 200 '{"flavors": [{"id": "1", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/1", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/1", "rel": "bookmark"}], "name": "m1.tiny"}, {"id": "2", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/2", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/2", "rel": "bookmark"}], "name": "m1.small"}, {"id": "3", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/3", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/3", "rel": "bookmark"}], "name": "m1.medium"}, {"id": "4", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/4", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/4", "rel": "bookmark"}], "name": "m1.large"}, {"id": "42", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/42", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/42", "rel": "bookmark"}], "name": "m1.nano"}, {"id": "5", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/5", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/5", "rel": "bookmark"}], "name": "m1.xlarge"}, {"id": "84", "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/flavors/84", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/84", "rel": "bookmark"}], "name": "m1.micro"}]}' 2013-02-09 11:53:11,329 INFO Bootstrapping environment 'openstack-local' (origin: ppa type: openstack_s3)... 2013-02-09 11:53:11,347 DEBUG access compute @ http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/servers/cd26d8d5-c813-407a-a0c1-4f9e4076e220 2013-02-09 11:53:11,347 DEBUG openstack: GET 'http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/servers/cd26d8d5-c813-407a-a0c1-4f9e4076e220' 2013-02-09 11:53:11,737 DEBUG openstack: 200 '{"server": {"status": "ERROR", "updated": "2013-02-09T16:44:25Z", "hostId": "24e9a1265dc8a89eb3b57844501812e85bf129e6d1db671646ee1bda", "OS-EXT-SRV-ATTR:host": "openstack-eval", "addresses": {}, "links": [{"href": "http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/servers/cd26d8d5-c813-407a-a0c1-4f9e4076e220", "rel": "self"}, {"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/servers/cd26d8d5-c813-407a-a0c1-4f9e4076e220", "rel": "bookmark"}], "key_name": null, "image": {"id": "04d87629-8d0b-4986-8c4a-3b8e32c4038b", "links": [{"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/images/04d87629-8d0b-4986-8c4a-3b8e32c4038b", "rel": "bookmark"}]}, "OS-EXT-STS:task_state": null, "OS-EXT-STS:vm_state": "error", "OS-EXT-SRV-ATTR:instance_name": "instance-00000001", "OS-EXT-SRV-ATTR:hypervisor_hostname": "openstack-eval", "flavor": {"id": "1", "links": [{"href": "http://192.168.0.100:8774/3d30e458a99c4814977c35b46dcb3760/flavors/1", "rel": "bookmark"}]}, "id": "cd26d8d5-c813-407a-a0c1-4f9e4076e220", "security_groups": [{"name": "juju-openstack-local"}, {"name": "juju-openstack-local-0"}], "OS-EXT-AZ:availability_zone": null, "user_id": "b52077f9de864a86aca426e4ec1ab018", "name": "juju openstack-local instance 0", "created": "2013-02-09T16:37:10Z", "tenant_id": "3d30e458a99c4814977c35b46dcb3760", "OS-DCF:diskConfig": "MANUAL", "OS-EXT-AZ:host_availability_zone": "nova", "accessIPv4": "", "accessIPv6": "", "fault": {"message": "NoValidHost", "code": 500, "details": "No valid host was found. \\n", "created": "2013-02-09T16:37:16Z"}, "OS-EXT-STS:power_state": 4, "config_drive": "", "metadata": {}}}' 2013-02-09 11:53:11,739 DEBUG Verifying writable storage 2013-02-09 11:53:11,754 DEBUG Launching juju bootstrap instance. 2013-02-09 11:53:11,808 DEBUG access compute @ http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/os-security-groups 2013-02-09 11:53:11,808 DEBUG openstack: GET 'http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/os-security-groups' 2013-02-09 11:53:12,159 DEBUG openstack: 200 '{"security_groups": [{"rules": [], "tenant_id": "3d30e458a99c4814977c35b46dcb3760", "id": 1, "name": "default", "description": "default"}, {"rules": [{"from_port": 22, "group": {}, "ip_protocol": "tcp", "to_port": 22, "parent_group_id": 2, "ip_range": {"cidr": "0.0.0.0/0"}, "id": 1}, {"from_port": 1, "group": {"tenant_id": "3d30e458a99c4814977c35b46dcb3760", "name": "juju-openstack-local"}, "ip_protocol": "tcp", "to_port": 65535, "parent_group_id": 2, "ip_range": {}, "id": 2}, {"from_port": 1, "group": {"tenant_id": "3d30e458a99c4814977c35b46dcb3760", "name": "juju-openstack-local"}, "ip_protocol": "udp", "to_port": 65535, "parent_group_id": 2, "ip_range": {}, "id": 3}], "tenant_id": "3d30e458a99c4814977c35b46dcb3760", "id": 2, "name": "juju-openstack-local", "description": "juju group for openstack-local"}, {"rules": [], "tenant_id": "3d30e458a99c4814977c35b46dcb3760", "id": 3, "name": "juju-openstack-local-0", "description": "juju group for openstack-local machine 0"}]}' 2013-02-09 11:53:12,161 DEBUG access compute @ http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/os-security-groups/3 2013-02-09 11:53:12,161 DEBUG openstack: DELETE 'http://192.168.0.100:8774/v2/3d30e458a99c4814977c35b46dcb3760/os-security-groups/3' 2013-02-09 11:53:12,488 DEBUG openstack: 400 '{"badRequest": {"message": "Security group is still in use", "code": 400}}' Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 397, in errback self._startRunCallbacks(fail) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 464, in _startRunCallbacks self._runCallbacks() File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 551, in _runCallbacks current.result = callback(current.result, *args, **kw) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1101, in gotResult _inlineCallbacks(r, g, deferred) --- --- File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/control/bootstrap.py", line 39, in command yield provider.bootstrap(constraints) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/common/bootstrap.py", line 57, in _launch_machine {"machine-id": "0", "constraints": self._constraints}, master=True) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/common/launch.py", line 64, in run machines = yield self.start_machine(machine_id, zookeepers) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/openstack/launch.py", line 84, in start_machine yield self._provider.port_manager.ensure_groups(machine_id)) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/openstack/ports.py", line 132, in ensure_groups groups_by_name[machine_group]) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 551, in _runCallbacks current.result = callback(current.result, *args, **kw) File "/usr/lib/python2.7/dist-packages/juju/providers/openstack/client.py", line 319, in _empty response.code, body)) juju.errors.ProviderInteractionError: Unexpected 400: '{"badRequest": {"message": "Security group is still in use", "code": 400}}' 2013-02-09 11:53:12,540 ERROR Traceback (most recent call last): File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 397, in errback self._startRunCallbacks(fail) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 464, in _startRunCallbacks self._runCallbacks() File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 551, in _runCallbacks current.result = callback(current.result, *args, **kw) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1101, in gotResult _inlineCallbacks(r, g, deferred) --- --- File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/control/bootstrap.py", line 39, in command yield provider.bootstrap(constraints) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/common/bootstrap.py", line 57, in _launch_machine {"machine-id": "0", "constraints": self._constraints}, master=True) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/common/launch.py", line 64, in run machines = yield self.start_machine(machine_id, zookeepers) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/openstack/launch.py", line 84, in start_machine yield self._provider.port_manager.ensure_groups(machine_id)) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 1043, in _inlineCallbacks result = result.throwExceptionIntoGenerator(g) File "/usr/lib/python2.7/dist-packages/twisted/python/failure.py", line 382, in throwExceptionIntoGenerator return g.throw(self.type, self.value, self.tb) File "/usr/lib/python2.7/dist-packages/juju/providers/openstack/ports.py", line 132, in ensure_groups groups_by_name[machine_group]) File "/usr/lib/python2.7/dist-packages/twisted/internet/defer.py", line 551, in _runCallbacks current.result = callback(current.result, *args, **kw) File "/usr/lib/python2.7/dist-packages/juju/providers/openstack/client.py", line 319, in _empty response.code, body)) juju.errors.ProviderInteractionError: Unexpected 400: '{"badRequest": {"message": "Security group is still in use", "code": 400}}' 2013-02-09 11:53:12,541 ERROR Unexpected 400: '{"badRequest": {"message": "Security group is still in use", "code": 400}}'