Is there a utility to clean up orphaned resources?

asked 2014-09-23 12:39:16 -0500

Heather gravatar image

updated 2014-09-26 15:03:46 -0500

smaffulli gravatar image

We are having issues related to a F5 load balancer where health monitors, pool members, and pools sometimes fail to delete and go into a pending deletion state.

We end up having to do things directly in the db to clean things up like below:

delete from poolmonitorassociations where pool_id in (select id from pools where status = 'PENDING_DELETE');
delete from poolstatisticss where pool_id in (select id from pools where status = 'PENDING_DELETE');
delete from pools where status = 'PENDING_DELETE';
delete from poolmonitorassociations where status = 'PENDING_DELETE';
delete from healthmonitors where tenant_id = '4e25c321632e42e7a32ec311c8ff99c2';
delete from poolstatisticss where pool_id in (select id from pools where tenant_id = '4e25c321632e42e7a32ec311c8ff99c2');
delete from pools where tenant_id = '4e25c321632e42e7a32ec311c8ff99c2';
delete from vips where tenant_id = '4e25c321632e42e7a32ec311c8ff99c2';

Just curious.

edit retag flag offensive close merge delete