0

We deployed MongoDB on EC2 with r3.8xlarge with 10000 IOPS. We are running a replicaset with 1 primary, 1 secondary, and 1 arbiter. In our applications we have readPreference set to secondaryPreferred.

Now, I am watching the EBS Read Throughput metrics on EBS for Mongo instances. I can see it's hitting 10k IOPs on the Mongo Primary node which is surprising for me; I see spikes on the secondary node which is obvious, but spikes on Primary are what is confusing me?

Why do I see spikes on the Primary mongo node EBS, even though I set readPreference to be secondaryPreferred?

Vince Bowdren
  • 8,326
  • 3
  • 31
  • 56
shiv455
  • 7,384
  • 19
  • 54
  • 93

1 Answers1

0

Just remind you

In most situations, operations read from secondary members but if no secondary members are available, operations read from the primary.

In your case please confirm your secondary node still alive.

And what is driver you used to connect mongodb? Node, Python, Java, ..?

I'm having same issues with Mongo driver for Node, and i submitted a ticket to Mongo. You can check in here: NODE-1049

HuyTran
  • 153
  • 1
  • 11