MongoDB is a scalable, high-performance, open source, document-oriented database. It supports a large number of languages and application development platforms. Questions about programming should be asked on http://stackoverflow.com.

learn more… | top users | synonyms

3
votes
0answers
392 views

Mongo not using enough RAM, and is slow

Our Production Mongo appears to be behaving weirdly. As far as I have read, Mongo should eat up all the available RAM to cache Index and Data in memory but in our case it is not doing so. Our ...
2
votes
0answers
99 views

Mongodb incremental backups

I was given the task to setup incremental backups for mongodb replicaset, as start point of course I googled about it and could not find anything on mongodb docs, I did find however this question ...
2
votes
0answers
63 views

Why is our Non-Mapped Virtual memory usage high when running MongoDB (MMAP) on CENTOS

Our non-virtual virtual memory usage on our Linux MongoDb instances seems high, currently sitting just over 2GB. The instances are running a minimal installation of CENTOS (no GUI) and they acting as ...
2
votes
0answers
34 views

MongoDB C# driver fails to reconnect after stepDown

I have an Elastic Beanstalk environment in AWS that constantly verifies the DB is accessible by querying the mongos for one document. We only speak to the DB routers and not to specific instances. ...
2
votes
0answers
217 views

Error while creating an admin user in replica set

I have a relatively simple replica set test setup between two VMs and my host machine, with VM1 as primary, VM2 as secondary and the host as arbiter. I have mongodb 2.6.4 installed on all machines. So ...
2
votes
0answers
497 views

Positional Operator Matching Nested Arrays Workaround?

As was just pointed out to me on stackoverflow, Positional Operator Matching Nested Arrays has yet to be made available.. I need to display read.marked:true replies differently than read.marked:false ...
2
votes
0answers
924 views

“Host has low open file limits” error in MMS

I am running Standalone MongoDB (v 2.6.0 64-bit) host on Centos (v 6.5). Centos is guest OS on Windows 7 host running under VirtualBox (4.3.10). MongoDB process runs under root account. And it is ...
2
votes
0answers
277 views

Store large hierarchy in NoSQL each day and compare

I'm in the process of creating a utility that stores a fairly large hierarchy into a NoSQL document. The data of this is similar to an Active Directory / LDAP structure which contains sub groupings, ...
2
votes
0answers
148 views

automated data sync after Primary node is down

I have this scenario, using version 2.2.2: Node A, Primary, Priority: 10, Wireless network Node B, Secondary, Priority: 9, VM Server1 Node C, Secondary, Priority: 8, VM Server1 Sequence: In Node ...
1
vote
0answers
14 views

Impact of adjusting Time of Mongodb server?

Using Ubuntu 14.04 and mongodb 2.6.10 I have time difference between a replica machine and primary , my secondary isn't configured with NTP what are the implications of adjusting time on the ...
1
vote
0answers
13 views

Why mongodb never end some connection

My mongod runs out of connections from time to time. But when I restart the instance, it becomes normal. I check the log and found some connections were created and never be ended. This cause the ...
1
vote
0answers
34 views

MongoDB: movechunk failed after adding a new share to cluster

I have a MongoDB cluster, which already has two shares: share1 and share2. When I add a new share3 to the cluster, data chunk can't migrate to share3. This is from the mongos log: ...
1
vote
0answers
24 views

MongoDB Update with NODE-RED?

I am in the process of trying to move data around via MQTT with MongoDB as my storage engine. I am using Node-Red to get the MQTT data and store it as JSON objects in Mongo using the mongo node ...
1
vote
0answers
19 views

MongoDB user account required for arbiter?

I have a test environment with two mongo v2.6.5 instances (#1, #2) and an arbiter instance in a replica set. I have a a common key file configured for all three instances. I have created an admin ...
1
vote
0answers
13 views

Should mongodb be run in a service, or a worker cluster?

I'm trying to implement an architecture that's similar to the coreos's production architecture (shown below) Should I run the database as a central service or one or more of the workers? I figured ...
1
vote
0answers
30 views

mongoDB - how to link one embedded object to another embedded object

Background Information I'm trying my hand at my first mongoDB database. So far, I've decided that I will need to use both references and embedded data models. One of the features of this application ...
1
vote
0answers
97 views

Docker Mongodb replication on different hosts is not working

I am trying to setup a mongodb replication in Docker containers running on different hosts. Please find the steps below: In a VM1 running ubuntu 14.04, installed docker, then created container C1. ...
1
vote
0answers
158 views

Creating Pandas DataFrame on Python From a MongoDB Document containing Embedded documents

I am working on a machine learning algorithm on python's scikit.learn, but this time the data are in Mongodb documents format. I would like to pull my data into a dataframe. Here is an exemple of the ...
1
vote
0answers
27 views

Replica Set In Mongo Are All Primary

So I saw a thread on here for when all the replica sets are Primary. The fix was to do rs.Add(hostportStr) on the master server before you do rs.initiate() on the server you want to become a ...
1
vote
0answers
63 views

Mongo 3 Intermitted Crashes

Currently running two VMs with fresh installs of Ubuntu 14.04 x64 and Mongo 3 Stable. Each VM has the same specs with 8 cores and 56GBs of RAM. Our processing VM is doing great under heavy loads, ...
1
vote
0answers
44 views

Mongodb schema design validation

I am building an app which allows users to do some "tasks" to earn points. The "tasks" are part of a "campaign" which themselves are a part of "brands". I am confused about the schema for storing the ...
1
vote
0answers
56 views

Good way to store daily train data in MongoDB

I am preparing to collect large amounts of information about trains in my country. Each train in my country has a number. I've already collected all of these numbers. There are about 4000 of them. ...
1
vote
0answers
33 views

why my data is not being sharded?

I am using mongo 2.6.7 I deploy a sharding cluster follow the guide: http://docs.mongodb.org/manual/tutorial/deploy-shard-cluster/ My sharding cluster include: - two replica sets (one primary + one ...
1
vote
0answers
124 views

How I can create user defined roles

I have a database in mongoDB 2.6.4 in which I want to restrict the users as per their level. I want to give read privileges to some users and insert/update privileges to some other users on a ...
1
vote
0answers
57 views

Nosql multiple database design to handle sharing scenarios

This question is regarding design of a database in mongodb. The scenario: A user has a drive which he can share with others. Drive has two categories: docs and others. The user has three choices in ...
1
vote
0answers
63 views

MongoDb Volume alert so much iops(>10000)

I am new for MongoDB. I have setup mongodb for my production server. I have setup alert in aws ec2 instance for iops and it gives me alert every 15 minutes that iops reached at > 10000. I am not ...
1
vote
0answers
148 views

Pentaho Kettle (Data Intergration) MongoDB Aggregation

I'm using kettle v5.2 which support the aggregation pipleline in MongoDB when using MongoDB input the query works for small data set but I need to use option allowDiskUse to the query can't figure ...
1
vote
0answers
148 views

Replica failed with error mongo db

I am running mongo sharded cluster with two replica set as shards. One set is working fine but replica secondary on other replica set is not working. When ever i restart it it gives me this error and ...
1
vote
0answers
58 views

Mongo stuck on save

We have a single node of Mongo holding data in a single collection. We run it on windows 2008 64-bit machine with 128 GB RAM. The size of the collection is ~2TB holding ~200M items. Lately, when we ...
1
vote
0answers
73 views

MongoDB read performance

I have an ingestion process which loads data into a specific collection at a very high rate. Some of these documents have to be loaded into another system in batches of 100K . Means as soon as I find ...
1
vote
0answers
55 views

How to check which sql statement is causing global lock

We are monitoring mongodb Database using MMS and it is showing 15-20 sec global lock. But we can't find any statement is taking more than 2-3 sec. I like to know which is causing so much global lock ...
1
vote
0answers
311 views

MongoDB communication issues on Azure

I have a Python uWSGI app running behind Nginx using pymongo to communicate with a 4 machine replica set running Mongodb 2.6.3. The replica set is configured using domain names for each machine ...
1
vote
0answers
106 views

mongodb replicaset

I am adding a new member in ReplicaSet and it starts initial sync bur after certain point sync break and start resync again.this process continue and never complete its initial sync.so please resolve ...
1
vote
0answers
372 views

Error to connect mongos when trying to create replicated sharded cluster

I'm trying to create an replicated sharded cluster in mongodb. Initially I've created two shards and there are a replica set with three members in each shard. And all the shards and replicasets run in ...
1
vote
0answers
305 views

mongodb balancer does not move chunks because of obscure error

After carefully following this guide, on how to migrate a 3 member replica set to a shard containing 2 X 3 member replica sets, after sharding one of my collections nothing happened. Looking into the ...
1
vote
0answers
21 views

Modeling for inclusion of two different entities

What I Have I am currently hashing out the data model for an application that will utilize MongoDB. In my setup, users or members (as they are called in the schema) will be created and then assigned ...
1
vote
0answers
353 views

Restore backup to staging replica set

I have a staging environment with Mongo replica set which I refresh on a regular basis. Refresh is done automatically using a bash script. Staging replica set consists of 3 members (primary, ...
1
vote
0answers
74 views

mysql vs mongodb cache/load balancing

I have a system where users can 'like' content. There will likely be many hundreds of these likes going on at once. I'd like it to be AJAX driven so you get an immediate response. At the moment I ...
1
vote
0answers
159 views

MongoDB secondary heartbeat hangs

We have got the same issue in two replica sets in AWS cloud. According to rs.status() on primary secondary jumping between SECONDARY and unhealthy states. With period of 10-20 seconds. In logs I see ...
1
vote
0answers
221 views

How can I use mongoDB efficiently in this scenario?

I'm trying to build a system of documents that have hundreds of tags assigned to them, but each document-tag association has a certain condition it has to also meet so the document would be returned: ...
0
votes
0answers
2 views

mongodb sharding by id, based on the first 8 characters

we have a database full of grams,and they're organised in a tree fashion, with parent references, like so: _id: gram:a;p1:as;p2;astr;p3;astrot;p4:astrotur;word:astroturf we would like to chunk the ...
0
votes
0answers
5 views

What will happen if the primary shard for a mongodb database is down?

Well as I understand each database has it's primary shard, which is mostly the first shard added to mongodb cluster. And we know that spliter will not split chunks until the chanksize is less then max ...
0
votes
0answers
11 views

What exactly are secondary members acknowledging in replicasets with MongoDB?

I try to understand the mechanics and behavior of MongoDB's replica-features better. I hope to get some insightful information from someone who is familiar with mongo's internals and behaviour. My aim ...
0
votes
0answers
6 views

How restore a specific database from backup using mongorestore command

I created a backup of my all database using mongodump command. Now I want to restore a specific database using mongorestore command. How is this possible, I use this command: --db option then mongodb ...
0
votes
0answers
9 views

how to restore the copied mongodb files in a server?

I have copied mongodb database files from my local machine into a server. How can i restore these files in the server and use them? Please help.
0
votes
0answers
10 views

Replica Set elected a new primary - i/o timeout on ping

We received this MMS Alert (log level INFO): Replica Set elected a new primary I browsed /var/log/mongodb-mms-automation/automation-agent-verbose.log [2015/09/01 03:45:08.305] [.debug] ...
0
votes
0answers
10 views

GridFS “UPLOAD-ONLY” permissions

I need to allow UPLOAD-only to GridFS. Does restricting role to "insert" to fs.files and fs.chunks do the trick? Does GridFS perform any actions except "insert" onto fs.files during upload?
0
votes
0answers
21 views

How to read from Mongodb secondary Only in a replica set?

Mongodb version 2.6.10 Ubuntu 14.04 Currently having a replica set of 4 nodes , my read preference is Primary Only , I configured one node with priority 0 Also i have a file on the priority 0 node ...
0
votes
0answers
19 views

MongoDB Slow updates

My application is doing extremely slow updates, despite my query being covered by indexes. My query is: query = {'spot': df_youtube['spot'].values[key], 'segment': ...
0
votes
0answers
14 views

How to merge numerous collections within one colection in MongoDB?

Here is the scenario: In one collection name is "Parent" I have the following document {"_id" : ObjectId("4f7ee46e08403d063ab0b4f9"), "name" : "MongoDB", "range" : "spec", "notes" : { { ...