mirror of
https://github.com/nspcc-dev/neofs-s3-gw.git
synced 2026-03-01 04:29:15 +00:00
Uploaded parts of multipart-upload keep stored even if multipart upload was aborted. #342
Labels
No labels
I2
I2
I3
I4
S2
S3
S4
S4
U0
U1
U2
U2
U3
U4
U4
auth-mate
blocked
bug
config
dependencies
discussion
documentation
enhancement
epic
feature
go
good first issue
help wanted
performance
question
security
test
tree-service
tree-service
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
nspcc-dev/neofs-s3-gw#342
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @lesnya on GitHub (Oct 18, 2022).
Originally assigned to: @masterSplinter01 on GitHub.
Some uploaded parts of s3 multipart-upload keep stored in neofs container even if multipart upload was aborted.
If you upload some relatively small objects (5MB or 100MB) as part of multipart upload and than do multipart-upload abort, they desappear from s3 and objects truly be deleted from neofs container underneath.
But if you upload some big objects (tested and validated for 1GB and 5GB) as part of multipart upload and than do multipart-upload abort - those objects will not be deleted from thier respective neofs container and continue to take up disk space.
Steps to reproduce:
Create bucket
aws --no-verify-ssl s3api create-bucket --bucket multipart-test --endpoint-url http://node1.neofs:8084Create multipart upload
aws --no-verify-ssl s3api create-multipart-upload --bucket multipart-test --key multipart-upload-1 --endpoint http://node1.neofs:8084Create small (5MB) and big (1GB) files and upload them as parts of multipart upload.
neofs-cli --rpc-endpoint node1.neofs:8080 -w scenarios/files/wallet.json container list-objects --cid 21dKQ9k6tF7azfJ8g2XM3WQXEBHK2GTiyYa1ivBTZMtVEXPECTED RESULT: Number of objects should match an uploaded parts, i.e. 3 objects in our case:
2dfBnvPEfyyZfb1wXySpPgVDTEK51Cr28hUnCc3XZ6DX
Bq2yrAvDdL3HEbGJb6mFTam2RzgjC4ux2hQ3xr3xCP2N
4pv88qwi2NdHkPgbRkYSFSaGHnzSapXp3BXWTDSzuwQN
aws --no-verify-ssl s3api abort-multipart-upload --bucket multipart-test --key multipart-upload-1 --upload-id 685318f5-585f-4c3c-9c0a-dff930bba9a7 --endpoint http://node1.neofs:8084EXPECTED RESULT: s3api list-parts and list-multipart-upload outputs should be empty now.
neofs-cli --rpc-endpoint node1.neofs:8080 -w scenarios/files/wallet.json container list-objects --cid 21dKQ9k6tF7azfJ8g2XM3WQXEBHK2GTiyYa1ivBTZMtVEnter password >
2dfBnvPEfyyZfb1wXySpPgVDTEK51Cr28hUnCc3XZ6DX
Bq2yrAvDdL3HEbGJb6mFTam2RzgjC4ux2hQ3xr3xCP2N
One object has gone (5Mb upload), while other 2 objects are still there.
UPD: ticking epochs doesn't help.
@masterSplinter01 commented on GitHub (Oct 19, 2022):
Couldn't reproduce the bug.
@lesnya Could you please check it one more time? If the bug appear, it will be nice to attach s3 gate and storage nodes logs.
@anatoly-bogatyrev commented on GitHub (Oct 20, 2022):
Issue did not reproduced on the latest versions (master) of all components. Can be closed.
@anatoly-bogatyrev commented on GitHub (Oct 25, 2022):
Part size: 5.1G /home/admin/object.sample or 1G
versions (latest master):
Create bucket:
Bucket d7b6a5b4-e389-49ab-9e4a-7aaac3c971eb has been created.
Get CID:
4az85vrmCMkvVL1t5chk5Epkg5ZT5VM9gS73ybw2MVom
Displaying a list of objects:
Multipart-upload start:
Uploading two parts for each of the created multipart-upload sessions:
Objects list:
Stop multipart upload session:
Objects list:
After several minutes.
Objects list:
Object GRzBQ7xpe12BZ9brsfkuDNYs9eXNXe8bTDkWN5F74ZXK has not been deleted.
@anatoly-bogatyrev commented on GitHub (Oct 25, 2022):
The issue is not reproduced with small objects (part size 100Mb -).
@alexvanin commented on GitHub (Nov 16, 2022):
Should be fixed now @lesnya
@alexvanin commented on GitHub (Nov 18, 2022):
Done in https://github.com/nspcc-dev/neofs-sdk-go/issues/360