[SERVER-31128] run_validate_collections hook doesn't check secondaries Created: 18/Sep/17  Updated: 30/Oct/23  Resolved: 29/Sep/17

Status: Closed
Project: Core Server
Component/s: Testing Infrastructure
Affects Version/s: None
Fix Version/s: 3.4.15, 3.6.0-rc0

Type: Bug Priority: Major - P3
Reporter: Ian Boros Assignee: Ian Boros
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Depends
is depended on by SERVER-30979 Run the fuzzer with CSRS primary step... Closed
is depended on by SERVER-31307 Run jstestfuzz_sharded_continuous_ste... Closed
Related
Backwards Compatibility: Minor Change
Operating System: ALL
Backport Requested:
v3.4
Sprint: TIG 2017-10-23
Participants:
Linked BF Score: 0

 Description   

In the run_validate_collections hook, it seems like we only call validate on the primary.

Take a look at this loop:

https://github.com/mongodb/mongo/blob/80a01240a1e1ac5ddb9191561046b38a50686ac0/jstests/hooks/run_validate_collections.js#L28-L36

We get the list of DBs from the secondary, but we call validate using the original mongo shell (which is connected to the primary).



 Comments   
Comment by Githook User [ 25/Mar/18 ]

Author:

{'email': 'ian.boros@10gen.com', 'name': 'Ian Boros'}

Message: SERVER-24759 SERVER-31128 Validate collections on all nodes in cluster

When connecting to a secondary to perform validate(), we now call
slaveOk() on the connection.

This also adds support for us to call validate() on all members of
replica set shards.

(cherry picked from commit 79da41f50a567ce1b0df5a4ab7a7eb5109414762)
Branch: v3.4
https://github.com/mongodb/mongo/commit/9a352e332e5b9f3abb693c5ccd4fa469daf9e417

Comment by Githook User [ 25/Mar/18 ]

Author:

{'email': 'max.hirschhorn@mongodb.com', 'name': 'Max Hirschhorn', 'username': 'visemet'}

Message: SERVER-31128 Skip validate on NotMaster error response.

This change is in preparation for running the validate command against
secondaries in a replica set.

The fuzzer test suites require that the validate command is only run
when the server's featureCompatibilityVersion=3.4. Otherwise, it is
possible that previously inserted Decimal128 data could lead to an
actually innocuous data consistency failure.
Branch: v3.4
https://github.com/mongodb/mongo/commit/2c5a4238a190f52dd2a301524c751aa3fac3a8d8

Comment by Githook User [ 29/Sep/17 ]

Author:

{'email': 'ian.boros@10gen.com', 'name': 'Ian Boros'}

Message: SERVER-24759 SERVER-31128 Validate collections on all nodes in cluster

When connecting to a secondary to perform validate(), we now call
slaveOk() on the connection.

This also adds support for us to call validate() on all members of
replica set shards.
Branch: master
https://github.com/mongodb/mongo/commit/79da41f50a567ce1b0df5a4ab7a7eb5109414762

Generated at Thu Feb 08 04:26:05 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.