swift client delete object failed

Home / Uncategorized / swift client delete object failed

Question:
Environment
swift client in CentOS7(10.0.0.2) bash [root@bogon ~]# pip2 show python-swiftclient Name: python-swiftclient Version: 2.7.0 Summary: OpenStack Object Storage API Client Library Home-page: http://www.openstack.org/ Author: OpenStack Author-email: openstack-dev@lists.openstack.org License: UNKNOWN Location: /usr/lib/python2.7/site-packages Requires: futures, six, requests
swift server in CentOS7(10.0.0.4) bash [root@bogon ~]# swift –version python-swiftclient 3.2.1.dev9

Question
swift client login server ,and delete one .jpg file in the container "temporary".

Details

[root@bogon ~]# swift -A http://10.0.0.4:8080/auth/v1.0 -U admin:admin -K admin_pass list contract data mask_contract temporary
[root@bogon ~]# swift -A http://10.0.0.4:8080/auth/v1.0 -U admin:admin -K 806huayuan list temporary | tail 9f2f8626-a2ad-11e7-ad0b-1866daecc1a0.jpg a25ebf08-a2b0-11e7-ad0b-1866daecc1a0.jpg a6cfc990-a2ad-11e7-ad0b-1866daecc1a0.jpg a8732914-a216-11e7-ad0b-1866daecc1a0.jpg a87cda6a-77f8-11e7-befe-1866daecc1a0.jpg ad186efc-a216-11e7-ad0b-1866daecc1a0.jpg b255e2e6-a216-11e7-ad0b-1866daecc1a0.jpg d1d010f2-0129-11e8-8cef-1866daecc1a0.jpg f779a1ea-a2ad-11e7-ad0b-1866daecc1a0.jpg ff4fbf7e-aa70-11e7-bbe0-1866daecc1a0.jpg
[root@bogon ~]# swift -A http://10.0.0.4:8080/auth/v1.0 -U admin:admin -K 806huayuan delete temporary ff4fbf7e-aa70-11e7-bbe0-1866daecc1a0.jpg Error Deleting: temporary/f779a1ea-a2ad-11e7-ad0b-1866daecc1a0.jpg: Object DELETE failed: http://10.0.0.4:8080/v1/AUTH_admin/temporary/f779a1ea-a2ad-11e7-ad0b-1866daecc1a0.jpg 409 Conflict [first 60 chars of response] There was a conflict when trying t


Answer:
Got it! The reason is that the timestamp assigned to the delete is earlier than the timestamp of the objects.

http://lists.openstack.org/pipermail/openstack-dev/2014-April/033438.html
Read more

Leave a Reply

Your email address will not be published. Required fields are marked *