[SERVER-18962] Fatal assertion on profiling-enabled secondary when dropping system.profile collection on primary Created: 12/Jun/15  Updated: 31/Aug/16  Resolved: 17/Jun/15

Status: Closed
Project: Core Server
Component/s: Replication
Affects Version/s: 3.1.3
Fix Version/s: 3.1.5

Type: Bug Priority: Major - P3
Reporter: Kamran K. Assignee: Matt Dannenberg
Resolution: Done Votes: 0
Labels: 32qa
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
is duplicated by SERVER-14514 disallow convertToCapped on system co... Closed
Related
is related to SERVER-18112 mongod replicates operations on syste... Closed
is related to SERVER-15207 Return errors from commands during re... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Steps To Reproduce:

var rst = new ReplSetTest({nodes: 2});
rst.startSet();
rst.initiate();
rst.awaitReplication();
 
var primaryDB = rst.getPrimary().getDB('test');
var secondaryDB = rst.getSecondary().getDB('test');
 
// Enable profiling on all nodes
primaryDB.runCommand({profile: 2});
secondaryDB.runCommand({profile: 2});
 
// Create the profile collection before disabling profiling on the primary
primaryDB.foo.insert({});
primaryDB.runCommand({profile: 0});
 
// Drop the collection on the primary to trigger an fassert on the secondary
primaryDB.system.profile.drop();
rst.awaitReplication();

Sprint: RPL 5 06/26/16
Participants:
Linked BF Score: 0

 Description   

If profiling is enabled on a secondary and a system.profile drop occurs on the primary, the secondary will abort, as of 3.1.2.

In previous versions, including 3.0.4-rc0, the same set of operations would result in a warning and a failed drop.

3.1.2+

 I COMMAND  [repl writer worker 15] CMD: drop test.system.profile
 E REPL     [repl writer worker 15] Failed command { drop: "system.profile" } on test with status IllegalOperation turn off profiling before dropping system.profile collection during oplog application
 I -        [repl writer worker 15] Fatal Assertion 16359
 I -        [repl writer worker 15] 

3.1.1 and 3.0.4-rc0

I COMMAND  [repl writer worker 15] CMD: drop test.system.profile
W REPL     [repl writer worker 15] Failed command { drop: "system.profile" } on test with status IllegalOperation turn off profiling before dropping system.profile collection during oplog application



 Comments   
Comment by Githook User [ 17/Jun/15 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: SERVER-18962 do not replicate metadata operations pertaining to system.profile
Branch: master
https://github.com/mongodb/mongo/commit/7523229c8dda361a10a42e622fc04441f5011fb6

Comment by Githook User [ 17/Jun/15 ]

Author:

{u'username': u'dannenberg', u'name': u'matt dannenberg', u'email': u'matt.dannenberg@10gen.com'}

Message: SERVER-18962 ignore IllegalOperation when replicating a dropCollection
Branch: master
https://github.com/mongodb/mongo/commit/bdf6a4b8af528241818ce03ce2483ac3c0c2aeff

Comment by Scott Hernandez (Inactive) [ 17/Jun/15 ]

Matt, please take a look at SERVER-14514 and see if we can close it, once these observer changes go in.

Comment by Scott Hernandez (Inactive) [ 16/Jun/15 ]

We should also ignore replicated operations on that collection for upgrade compatibility.

Comment by Eric Milkie [ 16/Jun/15 ]

Dropping system.profile should not replicate, since the items in that collection are not replicated.

Comment by Kamran K. [ 15/Jun/15 ]

The warning -> fassert change was introduced by SERVER-15207.

Generated at Thu Feb 08 03:49:23 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.