-
Notifications
You must be signed in to change notification settings - Fork 5.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[DNM]Wip rgw d4n next #56336
Draft
pritha-srivastava
wants to merge
32
commits into
ceph:main
Choose a base branch
from
pritha-srivastava:wip-rgw-d4n-next
base: main
Could not load branches
Branch not found: {{ refName }}
Could not load tags
Nothing to show
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Draft
[DNM]Wip rgw d4n next #56336
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
pritha-srivastava
force-pushed
the
wip-rgw-d4n-next
branch
from
March 20, 2024 16:32
fd16a3e
to
5f2ee68
Compare
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
modifications in ReadOp::prepare() method of the d4n filter driver to cache the head object. modification in get_obj_attrs to read from cache or backend store. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: mosayyebzadeh <mosayyeb@bu.edu>
samarahu
reviewed
Apr 26, 2024
pritha-srivastava
force-pushed
the
wip-rgw-d4n-next
branch
from
May 2, 2024 08:17
24339ea
to
440f00b
Compare
Signed-off-by: mosayyebzadeh <mosayyeb@bu.edu>
Signed-off-by: mosayyebzadeh <mosayyeb@bu.edu>
Signed-off-by: mosayyebzadeh <mosayyeb@bu.edu>
Read process needs to be updated based on write process. It needs to check where is the data and if it is dirty or clean. If it is in the cache and dirty, we need to put D_ in the oid of the object before reading it from cache. If it is clean, there is nothing to do. Signed-off-by: mosayyebzadeh <mosayyeb@bu.edu>
Signed-off-by: mosayyebzadeh <mosayyeb@bu.edu>
pritha-srivastava
force-pushed
the
wip-rgw-d4n-next
branch
from
May 2, 2024 10:40
440f00b
to
28b9921
Compare
Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
process. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
which has objects ordered by their creation time and the top element of which is fetched in the cleaning method, processed and deleted in a loop. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
bucket_name_version_object_name_ofs_len, to avoid checks for versioned and non-versioned objects. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
and delete_obj_attrs() to check if the head object exists in a cache, else direct the calls to backend store. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
pritha-srivastava
force-pushed
the
wip-rgw-d4n-next
branch
from
May 6, 2024 07:23
28b9921
to
3976cb9
Compare
while writing the object. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
RGWRados, in case ReadOp::prepare() reads the head object from the cache. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved |
1. storing objects in directory using their oid, so that the version is included. 2. making sure that the head block corresponds to latest version in the block directory. 3. add a directory entry for head block for every version in case of a versioned bucket. 4. Populating hostsList correctly for blocks and objects. Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
…cript Signed-off-by: Samarah <samarah.uriarte@ibm.com>
data handling and faster completion Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Samarah <samarah.uriarte@ibm.com>
…sistent values, and fix directory updates in `cleanup` method Signed-off-by: Samarah <samarah.uriarte@ibm.com>
Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
… (LFUDA). Signed-off-by: Pritha Srivastava <prsrivas@redhat.com>
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the next set of changes for the d4n filter driver.
This PR so far has achieved a working write-back cache on a single node for non-multipart (small) objects, for both versioned and non-versioned objects.
To test various scenarios, bring up vstart cluster as follows:
MON=1 OSD=1 RGW=1 MGR=0 MDS=0 ../src/vstart.sh -n -d -o rgw_d4n_l1_datacache_persistent_path=/home/prsrivas/ceph/build/rgw_d4n_datacache/ -o rgw_d4n_l1_datacache_size=5368709120 -o rgw_filter=d4n -o d4n_writecache_enabled=true -o rgw_d4n_cache_cleaning_interval=600
The following steps are for uploading and downloading an object to/from a non-versioned bucket:
Create a bucket:
aws s3 mb s3://my-new-bucket --endpoint-url http://localhost:8000 --region us-east-1
Upload a small object (non-multipart) object:
aws s3 cp ./1M s3://my-new-bucket --endpoint-url http://localhost:8000 --region us-east-1
Check d4n datacache contents - you will see one entry for head, and other entries belonging to data of an object
ls -l rgw_d4n_datacache/
-rw-r--r--. 1 prsrivas prsrivas 0 May 2 12:43 D_my-new-bucket_09v6V6FcjyJ17hNJmFgysOjxtLAAX2n_1M
-rw-r--r--. 1 prsrivas prsrivas 1048576 May 2 12:43 D_my-new-bucket_09v6V6FcjyJ17hNJmFgysOjxtLAAX2n_1M_0_1048576
Check if get-object works:
aws s3api get-object --bucket my-new-bucket --key 1M --endpoint-url http://localhost:8000 --region us-east-1 ./1M-out
Check md5 of the objects, to ensure that the contents are as expected:
md5sum ./1M ./1M-out
Now wait for the cleaning process to kick in (roughly after rgw_d4n_cache_cleaning_interval which is 600 seconds)
Check d4n datacache contents - all dirty entries are converted to non-dirty now (D prefix removed), which means they have been written to backend store
-rw-r--r--. 1 prsrivas prsrivas 0 May 2 12:43 my-new-bucket_09v6V6FcjyJ17hNJmFgysOjxtLAAX2n_1M
-rw-r--r--. 1 prsrivas prsrivas 1048576 May 2 12:43 my-new-bucket_09v6V6FcjyJ17hNJmFgysOjxtLAAX2n_1M_0_1048576
Check get-object now
aws s3api get-object --bucket my-new-bucket --key 1M --endpoint-url http://localhost:8000 --region us-east-1 ./1M-cache
Check md5 of the objects, to ensure that the contents are as expected:
md5sum ./1M ./1M-cache
The following steps are for uploading/downloading an object to/from a versioned bucket:
Create a bucket:
aws s3 mb s3://my-new-bucket --endpoint-url http://localhost:8000 --region us-east-1
Enable versioning on the bucket:
aws s3api put-bucket-versioning --bucket my-new-bucket --versioning-configuration Status=Enabled --endpoint-url http://localhost:8000 --region us-east-1
Upload an object:
aws s3 cp ./1M s3://my-new-bucket --endpoint-url http://localhost:8000 --region us-east-1
Check d4n datacache contents for the head and data entries
Check get-object without specifying version-id
aws s3api get-object --bucket my-new-bucket --key 1M --endpoint-url http://localhost:8000 --region us-east-1 ./1M-out
Check get-object by specifying a version-id
aws s3api get-object --bucket my-new-bucket --key 1M --version-id "09v6V6FcjyJ17hNJmFgysOjxtLAAX2n" --endpoint-url http://localhost:8000 --region us-east-1 ./1M-out
Now wait for the cleaning process to kick in (roughly after rgw_d4n_cache_cleaning_interval which is 600 seconds)
Check d4n datacache contents - all dirty entries are converted to non-dirty now (D prefix removed), which means they have been written to backend store
Now check get-object with and without version-id as in step 6 and 7.
Testing steps for copy object:
when both source and destination buckets are non-versioned
when source bucket is versioned
when destination bucket is versioned:
Things that do NOT work:
Contribution Guidelines
To sign and title your commits, please refer to Submitting Patches to Ceph.
If you are submitting a fix for a stable branch (e.g. "quincy"), please refer to Submitting Patches to Ceph - Backports for the proper workflow.
When filling out the below checklist, you may click boxes directly in the GitHub web UI. When entering or editing the entire PR message in the GitHub web UI editor, you may also select a checklist item by adding an
x
between the brackets:[x]
. Spaces and capitalization matter when checking off items this way.Checklist
Show available Jenkins commands
jenkins retest this please
jenkins test classic perf
jenkins test crimson perf
jenkins test signed
jenkins test make check
jenkins test make check arm64
jenkins test submodules
jenkins test dashboard
jenkins test dashboard cephadm
jenkins test api
jenkins test docs
jenkins render docs
jenkins test ceph-volume all
jenkins test ceph-volume tox
jenkins test windows
jenkins test rook e2e