scrub command raise exception because of default security group

Bug #1308880 reported by John Haan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
python-novaclient
Won't Fix
Medium
Arvinder Singh

Bug Description

Scrub command raise following exception because of default security group.

DEBUG (shell:777) Unable to delete system group 'default' (HTTP 400) (Request-ID: req-9ac7f8f5-cb68-436b-8ecc-f4d0aba31741)
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/novaclient/shell.py", line 774, in main
    OpenStackComputeShell().main(map(strutils.safe_decode, sys.argv[1:]))
  File "/usr/lib/python2.7/dist-packages/novaclient/shell.py", line 710, in main
    args.func(self.cs, args)
  File "/usr/lib/python2.7/dist-packages/novaclient/v1_1/shell.py", line 747, in do_scrub
    cs.security_groups.delete(group)
  File "/usr/lib/python2.7/dist-packages/novaclient/v1_1/security_groups.py", line 71, in delete
    self._delete('/os-security-groups/%s' % base.getid(group))
  File "/usr/lib/python2.7/dist-packages/novaclient/base.py", line 161, in _delete
    _resp, _body = self.api.client.delete(url)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 263, in delete
    return self._cs_request(url, 'DELETE', **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 231, in _cs_request
    **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 213, in _time_request
    resp, body = self.request(url, method, **kwargs)
  File "/usr/lib/python2.7/dist-packages/novaclient/client.py", line 207, in request
    raise exceptions.from_response(resp, body, url, method)
BadRequest: Unable to delete system group 'default' (HTTP 400) (Request-ID: req-9ac7f8f5-cb68-436b-8ecc-f4d0aba31741)

ERROR: Unable to delete system group 'default' (HTTP 400) (Request-ID: req-9ac7f8f5-cb68-436b-8ecc-f4d0aba31741)

I think the default security group should not be deleted unless the target project is removed.

Therefore when we remove security group of target project, the scrub method should not try to remove the the default security group

John Haan (yongiman)
Changed in python-novaclient:
assignee: nobody → John Haan (yongiman)
Revision history for this message
melanie witt (melwitt) wrote :

We shouldn't try to delete the default security group of a project.

Changed in python-novaclient:
importance: Undecided → Medium
status: New → Confirmed
Changed in python-novaclient:
assignee: John Haan (yongiman) → nobody
assignee: nobody → Arvinder Singh (arvinder-09)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to python-novaclient (master)

Fix proposed to branch: master
Review: https://review.openstack.org/390243

Changed in python-novaclient:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on python-novaclient (master)

Change abandoned by Michael Still (<email address hidden>) on branch: master
Review: https://review.openstack.org/390243
Reason: This patch has been sitting unchanged for more than 12 weeks. I am therefore going to abandon it to keep the review queue sane. Please feel free to restore the change if you're still working on it.

Revision history for this message
Takashi Natsume (natsume-takashi) wrote :

The 'scrub' command has been removed in https://review.openstack.org/#/c/437145/.
So it is no longer necessary to fix it.

Changed in python-novaclient:
status: In Progress → Won't Fix
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.