How can I delete the system.profile collection at the SECONDARY node?

  mongodb, question
jp-spl-shard0:SECONDARY> db.setProfilingLevel(0)
 { "was" : 1, "slowms" : 500, "ok" : 1 }
 jp-spl-shard0:SECONDARY> db.system.profile.drop()
 2017-10-19T22:27:56.428+0800 E QUERY    [thread1] Error: drop failed: {
 "ok" : 0,
 "errmsg" : "not master",
 "code" : 10107,
 "codeName" : "NotMaster"
 } :
 _getErrorWithCode@src/mongo/shell/utils.js:25:13
 DBCollection.prototype.drop@src/mongo/shell/collection.js:752:1
 @(shell):1:1

The above command can be run on the PRIMARY node, but it does not work on the SECONDARY node, and the answer has not been found yet.

If the purpose is to query the last record, you can use the$natural

db.system.profile.find().sort({$natural: -1}).limit(10);