Skip to content

qa/multisite: stabilize multisite testing - #56874

Merged
smanjara merged 9 commits into
ceph:mainfrom
smanjara:wip-shilpa-multisite-tests
Jun 6, 2024
Merged

smanjara merged 9 commits into
ceph:mainfrom
smanjara:wip-shilpa-multisite-tests

Conversation

@smanjara

@smanjara smanjara commented Apr 14, 2024 •

Copy link
Copy Markdown
Contributor

until we have a fix for all the failing tests, this pr disables data_sync_init tests, sync policy and endpoint tests to allow running functional multisite tests against PR's.
also includes fixes from @cbodley's #54442

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

  • Tracker (select at least one)
    • References tracker ticket
    • Very recent bug; references commit where it was introduced
    • New feature (ticket optional)
    • Doc update (no ticket needed)
    • Code cleanup (no ticket needed)
  • Component impact
    • Affects Dashboard, opened tracker ticket
    • Affects Orchestrator, opened tracker ticket
    • No impact that needs to be tracked
  • Documentation (select at least one)
    • Updates relevant documentation
    • No doc update is appropriate
  • Tests (select at least one)
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

@smanjara
smanjara requested a review from a team as a code owner April 14, 2024 03:01
@smanjara
smanjara force-pushed the wip-shilpa-multisite-tests branch from 6ed76bc to 03e7a11 Compare April 15, 2024 02:23
Comment thread src/test/rgw/rgw_multi/tests.py Resolved
@smanjara
smanjara force-pushed the wip-shilpa-multisite-tests branch 2 times, most recently from 9fbf23e to 5d4ca1d Compare April 17, 2024 18:35
@smanjara

Copy link
Copy Markdown
Contributor Author

ran the suite after pulling #56893 into two_zone.yaml. test_topic_notification_sync still seems to fail.

2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:======================================================================
2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:ERROR: rgw_multi.tests.test_topic_notification_sync
2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:----------------------------------------------------------------------
2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:Traceback (most recent call last):
2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:  File "/home/teuthworker/src/git.ceph.com_teuthology_9481b1d62f50e7d0a4f3dd83adf6945b08d5ff17/virtualenv/lib/python3.8/site-packages/nose/case.py", line 198, in runTest
2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:    self.test(*self.arg)
2024-04-18T20:15:45.433 INFO:tasks.rgw_multisite_tests:  File "/home/teuthworker/src/git.ceph.com_ceph-c_5d4ca1d4687229e2ba4144f00b14e7c911ce18dd/qa/../src/test/rgw/rgw_multi/tests.py", line 1788, in test_topic_notification_sync
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:    zone_conn.create_notification(bucket.name, [topic_conf])
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:  File "/home/teuthworker/src/git.ceph.com_ceph-c_5d4ca1d4687229e2ba4144f00b14e7c911ce18dd/qa/tasks/rgw_multi/zone_rados.py", line 160, in create_notification
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:    return self.s3_client.put_bucket_notification_configuration(
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:  File "/home/teuthworker/src/git.ceph.com_teuthology_9481b1d62f50e7d0a4f3dd83adf6945b08d5ff17/virtualenv/lib/python3.8/site-packages/botocore/client.py", line 553, in _api_call
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:    return self._make_api_call(operation_name, kwargs)
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:  File "/home/teuthworker/src/git.ceph.com_teuthology_9481b1d62f50e7d0a4f3dd83adf6945b08d5ff17/virtualenv/lib/python3.8/site-packages/botocore/client.py", line 1009, in _make_api_call
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:    raise error_class(parsed_response, operation_name)
2024-04-18T20:15:45.434 INFO:tasks.rgw_multisite_tests:botocore.exceptions.ClientError: An error occurred (ConcurrentModification) when calling the PutBucketNotificationConfiguration operation: None

@cbodley

cbodley commented Apr 18, 2024

Copy link
Copy Markdown
Contributor

cc @kchheda3 @yuvalif

An error occurred (ConcurrentModification) when calling the PutBucketNotificationConfiguration operation: None

this is an ECANCELED error coming from our write of the bucket instance metadata. it's a common error for metadata writes on secondary zones, because our write races with metadata sync from the write that we forwarded to the master zone

rgw ops should generally retry these writes on ECANCELED after reading the updated bucket metadata. see a very simple example from RGWPutCORS::execute(): https://github.com/ceph/ceph/blob/c46a99d/src/rgw/rgw_op.cc#L6058-L6061

for RGWPSCreateNotifOp::execute_v2(), the entire block of https://github.com/ceph/ceph/blob/c46a99d/src/rgw/rgw_rest_pubsub.cc#L1327-L1362 should be done inside of retry_raced_bucket_write()

i guess that means the retry_raced_bucket_write() template needs to move from rgw_op.cc to rgw_op.h or some other header

@kchheda3

Copy link
Copy Markdown
Contributor

because our write races wi

interesting, this could also be real world problem ? if yes then this needs to be backported to squid as well?

@cbodley

cbodley commented Apr 19, 2024

Copy link
Copy Markdown
Contributor

@kchheda3

Copy link
Copy Markdown
Contributor

i opened https://tracker.ceph.com/issues/65590 to track the squid backport

@cbodley i think line https://github.com/ceph/ceph/blob/c46a99d/src/rgw/rgw_rest_pubsub.cc#L1323 also needs to be under retry_raced_bucket_write, coz deletion of topic also updates the bucket_attr that could lead to race condition ?

@kchheda3

kchheda3 commented Apr 19, 2024 •

Copy link
Copy Markdown
Contributor

i opened https://tracker.ceph.com/issues/65590 to track the squid backport

@cbodley i think line https://github.com/ceph/ceph/blob/c46a99d/src/rgw/rgw_rest_pubsub.cc#L1323 also needs to be under retry_raced_bucket_write, coz deletion of topic also updates the bucket_attr that could lead to race condition ?

PR --> #57004

@smanjara

Copy link
Copy Markdown
Contributor Author

thanks @kchheda3 and @cbodley. pulling changes from #57004 to test.

@smanjara

Copy link
Copy Markdown
Contributor Author

the notification test passes. we are left with one last failure. will look into it once I am back from PTO.

https://qa-proxy.ceph.com/teuthology/smanjara-2024-04-20_03:53:15-rgw:multisite-wip-shilpa-multisite-tests-distro-default-smithi/7664381/teuthology.log

2024-04-20T04:44:53.060 INFO:tasks.rgw_multisite_tests:FAIL: rgw_multi.tests.test_multi_object_delete 2024-04-20T04:44:53.060 INFO:tasks.rgw_multisite_tests:---------------------------------------------------------------------- 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests:Traceback (most recent call last): 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: File "/home/teuthworker/src/git.ceph.com_teuthology_9481b1d62f50e7d0a4f3dd83adf6945b08d5ff17/virtualenv/lib/python3.8/site-packages/nose/case.py", line 198, in runTest 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: self.test(*self.arg) 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: File "/home/teuthworker/src/git.ceph.com_ceph-c_b7ee7f9c91570cb720e431aed1e36bd77ea044bb/qa/../src/test/rgw/rgw_multi/tests.py", line 880, in test_multi_object_delete 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: zone_bucket_checkpoint(target_conn.zone, source_conn.zone, bucket.name) 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: File "/home/teuthworker/src/git.ceph.com_ceph-c_b7ee7f9c91570cb720e431aed1e36bd77ea044bb/qa/../src/test/rgw/rgw_multi/tests.py", line 390, in zone_bucket_checkpoint 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: target_zone.cluster.admin(cmd, debug_rgw=1) 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: File "/home/teuthworker/src/git.ceph.com_ceph-c_b7ee7f9c91570cb720e431aed1e36bd77ea044bb/qa/tasks/rgw_multisite.py", line 197, in admin 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests: assert r == 0 2024-04-20T04:44:53.064 INFO:tasks.rgw_multisite_tests:AssertionError:

@cbodley

cbodley commented Apr 22, 2024

Copy link
Copy Markdown
Contributor

that looks like a bucket checkpoint timeout:

2024-04-20T04:44:54.379 INFO:tasks.rgw_multisite_tests:teuthology.orchestra.run.smithi027.stderr: INFO: 2024-04-20T04:25:12.896+0000 7f9647ddb980  1 waiting to reach incremental sync..
2024-04-20T04:44:54.379 INFO:tasks.rgw_multisite_tests:teuthology.orchestra.run.smithi027.stderr: INFO: 2024-04-20T04:25:17.896+0000 7f9647ddb980 -1 bucket checkpoint timed out waiting to reach incremental sync
2024-04-20T04:44:54.379 INFO:tasks.rgw_multisite_tests:teuthology.orchestra.run.smithi027.stderr: INFO: 2024-04-20T04:25:17.896+0000 7f9647ddb980  0 bucket sync checkpoint failed: (110) Connection timed out
2024-04-20T04:44:54.379 INFO:tasks.rgw_multisite_tests:teuthology.orchestra.run.smithi027.stderr: INFO: 2024-04-20T04:25:17.896+0000 7f9647ddb980 -1 bucket sync checkpoint failed: (110) Connection timed out
2024-04-20T04:44:54.379 INFO:tasks.rgw_multisite_tests:teuthology.orchestra.run: DEBUG: got remote process result: 110
2024-04-20T04:44:54.379 INFO:tasks.rgw_multisite_tests:--------------------- >> end captured logging << ---------------------
2024-04-20T04:44:54.380 INFO:tasks.rgw_multisite_tests:
2024-04-20T04:44:54.380 INFO:tasks.rgw_multisite_tests:----------------------------------------------------------------------
2024-04-20T04:44:54.380 INFO:tasks.rgw_multisite_tests:Ran 35 tests in 1674.303s
2024-04-20T04:44:54.380 INFO:tasks.rgw_multisite_tests:
2024-04-20T04:44:54.380 INFO:tasks.rgw_multisite_tests:FAILED (SKIP=2, failures=1)

@cbodley

cbodley commented Apr 22, 2024

Copy link
Copy Markdown
Contributor

2024-04-20T04:25:17.896+0000 7f9647ddb980 -1 bucket checkpoint timed out waiting to reach incremental sync

interesting that it was stuck on bucket full sync. i dug into the primary rgw logs and found that it finished full sync and switched to incremental about 30 seconds after the bucket sync checkpoint command timed out and gave up:

2024-04-20T04:25:40.848+0000 7fe8bbfb0640 5 RGW-SYNC:data:sync:shard[2]:entry[pwpelu-12:143fe602-7506-4f91-90f6-c5174255a275.4354.16:0[0]]:bucket_sync_sources[source=:pwpelu-12[143fe602-7506-4f91-90f6-c5174255a275.4354.16]):source_zone=459827fe-c3cc-483f-a1bd-c4d0bbf4b8a0]:bucket[pwpelu-12:143fe602-7506-4f91-90f6-c5174255a275.4354.16<-pwpelu-12:143fe602-7506-4f91-90f6-c5174255a275.4354.16:0]:full_sync[pwpelu-12:143fe602-7506-4f91-90f6-c5174255a275.4354.16:0]: set bucket state=incremental

@cbodley

cbodley commented Apr 22, 2024

Copy link
Copy Markdown
Contributor

i used zgrep 'full_sync\[pwpelu-12' rgw.c1.client.0.log.gz on this rgw log to track this progress. when the checkpoint starts, there are 50 objects to full sync

that full sync proceeds normally until we inject an error:

2024-04-20T04:18:05.594+0000 ... full_sync[pwpelu-12:143fe602-7506-4f91-90f6-c5174255a275.4354.16:5]:entry[obj30]: : injecting data sync error on key=obj30

this causes bucket sync to error out, and data sync adds it to the error repo. when we retry the bucket sync later, we restart from the beginning of the listing and try to sync every object again

this cycle repeats until we get lucky and process all 50 objects without an error being injected. rgw sync data inject err probability: 0.1 means that on average we'd inject an EIO error every 10th object

@cbodley

cbodley commented Apr 22, 2024

Copy link
Copy Markdown
Contributor

this causes bucket sync to error out, and data sync adds it to the error repo. when we retry the bucket sync later, we restart from the beginning of the listing and try to sync every object again

we should be storing our full sync progress in sync_status.full.position and resuming from there. maybe we're not flushing our pending marker updates when we encounter those EIO errors?

@cbodley

cbodley commented Apr 22, 2024

Copy link
Copy Markdown
Contributor

@smanjara error injection is an important piece of testing to make sure we're covering the error paths, but maybe we turn it off for now?

@smanjara
smanjara force-pushed the wip-shilpa-multisite-tests branch from 5d4ca1d to 46a5ada Compare May 21, 2024 17:34
@smanjara

Copy link
Copy Markdown
Contributor Author

@smanjara error injection is an important piece of testing to make sure we're covering the error paths, but maybe we turn it off for now?

thanks for analyzing the logs @cbodley. testing with error injection turned off.

@smanjara

smanjara commented Jun 5, 2024

Copy link
Copy Markdown
Contributor Author

@github-actions

github-actions Bot commented Jun 5, 2024

Copy link
Copy Markdown

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

Comment thread src/test/rgw/rgw_multi/tests.py Resolved
Shilpa Jagannath and others added 3 commits June 6, 2024 12:07
Signed-off-by: Casey Bodley <[email protected]>
(cherry picked from commit bc084c0)
> WARNING: The OSD cluster is overloaded and struggling to complete ops. You need more capacity to serve this level of demand.

give each cluster 2 nodes instead of 1, and 6 osds instead of 3

Signed-off-by: Casey Bodley <[email protected]>
(cherry picked from commit 9a80cf4)
cbodley and others added 5 commits June 6, 2024 12:07
@smanjara
smanjara force-pushed the wip-shilpa-multisite-tests branch from 46a5ada to aa927f4 Compare June 6, 2024 19:08
Signed-off-by: Shilpa Jagannath <[email protected]>
@smanjara
smanjara force-pushed the wip-shilpa-multisite-tests branch from aa927f4 to 6753e27 Compare June 6, 2024 19:10
@smanjara
smanjara merged commit 37816ef into ceph:main Jun 6, 2024
@cbodley

cbodley commented Jun 28, 2024

Copy link
Copy Markdown
Contributor

@smanjara

Copy link
Copy Markdown
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants