I have a simple mongodb setup in a replicaset, with 1 actual instance and 1 arbiter (to avoid conflicts). This is in anticipation of expanding the replicaset to include more instances as our load increases.
If I access mongodb through the shell, I correctly get the
PRIMARY > prompt, and running
rs.status() tells me everything is fine and dandy.
I have a node.js server that is accessing the database, using the mongodb-native driver found on github, version 0.9.9-8. However, occasionally it simply breaks down with the following error:
Unable to connect to database: Error: no primary server found
The program is given the two adresses for the two instances (normal instance + arbiter), but otherwise neither the program log or mongodb's log gives any clue as to what is wrong. Any help is welcome!