All versions of MongoDB - a scalable, high-performance, open source, document-oriented database.

learn more… | top users | synonyms

1
vote
1answer
34 views

Is MongoDB Connections getting too high?

I currently have my MongoDB running in Production Environment. It has 1 Primary, 1 secondary and an Arbiter. Configuration of the ubuntu machines are pretty decent, it's got 56GB of RAM and about ...
0
votes
0answers
39 views

add mongod service to rhel when mongdb installed offiine

I've RHEL6.7 machine which does not have internet connection. I installed mongodb by doing below steps Downloaded mongodb-linux-x86_64-v2.4-latest.tgz from mongodb official website. Extracted ...
0
votes
0answers
15 views

Mongodb slave shut down

i started a mongodb master slave but due to technical issues the slave server crashed. I restarted it and the mongod proccess as well with the host parameter, but for some reason the slave isnt ...
0
votes
1answer
98 views

MongoDB replica set: members with different versions of mongod

The primary is running mongod 3.0.6 and the secondaries running mongod 3.0.7 is a mixing of versions allowed in the same replica set? For upgrade it's best practise to not all nodes the same time. ...
1
vote
2answers
30 views

When one of masters is unreachable all other replica sets work too slow in mongodb 2.6.11 and web application throws error 71

When one of masters is unreachable all other replica sets work too slow in mongodb 2.6.11, also I can not list the databases on mongos servers, and that is because of one replica set. How to solve ...
0
votes
0answers
13 views

MongoDB Single Array or Multiple Fields

I have a MongoDB for a game, and I made a collection to store all outgoing attacks. My question is which of these models is more efficient. spearMenCount: type: Number required: true ...
2
votes
1answer
118 views

How to validate data before loading it to DB

I have a situation where in I have million records in CSV file, what I need to do is to apply some business validation on certain columns of CSV and load data to DB only if particular record is valid. ...
0
votes
0answers
23 views

Performance issues when using 2dsphere indexes

I'm working on mongodb for geospatial processing. Currently I'm ingesting about 8 million GeoJSON, that initially were stored as point data, taking about 20 minutes to index. Recently, we changed the ...
1
vote
1answer
56 views

storing files on mongodb

I am developing an app where user will upload multiple images along with some other data like name address etc. I am using MEAN stack for development, So I have some questions regarding this: How ...
2
votes
1answer
78 views

Hash index use case in MongoDB

Recently MongoDB added hash index to its features but in the documentation doesn't explain much about hash index use case and its privileges to normal MongoDB index. So I'll be grateful if you guide ...
1
vote
0answers
75 views

Mongodb Huge Number of Open Connections and Write Locks

We are seeing around 800 open connections to our Mongodb. To clarify our issue: We have 5 different clients who write the data into Mongodb. Each of these clients - write four different type of ...
1
vote
1answer
89 views

mongo converting standalone to replica set causes services down

I have standalone node1 already running for a long time. Now I want to convert it to replica set. I followed steps in https://docs.mongodb.org/v2.4/tutorial/convert-standalone-to-replica-set/ to ...
2
votes
2answers
52 views

How to optimize performance of backup process? Servers go down during backup

The context - So I am an intern (So I'll appreciate a more noob friendly response) and we have several websites on a server of which we do a backup daily, at midnight. We use MongoDB and there's a ...
1
vote
1answer
23 views

How to test MongoDb sharded cluster

I set up a MongoDb sharded cluster (2 shards) as described in this tutorial. Now, I want to test that the shard 1 (RS1) and shard 2 (RS2) works well. However, all the databases, collections and ...
0
votes
1answer
21 views

MongoDb: sharded replica set: data distribution

How does the data get distributed among the shards? How to backup and restore an infrastructure with 2 shards (3 config servers and 1 mongos) When should I choose MongoDb Shard with Replica Set vs ...
2
votes
1answer
33 views

How verify if the MongoDb Sharded Replica Set works well?

I set up a MongoDb Sharded Replica Set with 2 clusters as described in this tutorial but I don't know how to test if everything works well. I have no error messages on the any of the hosts, which ...
0
votes
0answers
14 views

DB Design - Advanced Permission Combinations by Per Content & Getting All Allowed Contents

I've been trying to develop an internal staff portal for our company. There are departments, job grades, working areas, roles (user, editor, admin, super admin, etc...) and special groups (executives, ...
3
votes
2answers
122 views

MongoDB uses only one index on simple query with sorting

So the problem is that I'm having a huge collection and I'm trying to run a query that filters and sorts on only fields that have indexes on them. I have these two indexes: ...
1
vote
1answer
58 views

Is any way to restructure MongoDB?

I have a MongoDB with compound index by 4 fields and I want to reorder physical data distribution at HDD by this index. I am looking for something like creating chunk in NOT sharded environment. Is ...
0
votes
0answers
93 views

Configure Mongo to close idle connections

I want to know if there's something that can be configured on the Mongo server (mongod) to close idle connections. The scenario is this, we've some node clients that open a connection, when the ...
0
votes
1answer
29 views

Mongodb monitoring

I am using a mongodb in my application and i would like to ask if someone here has some tested tools to monitor the servers (similar to tools like heidi sql or mysql workbench). My main needs are ...
0
votes
0answers
331 views

Issues in starting MongoDB service

I've installed MongoDB 3.0 in RHEL 6. From root user, i'm trying to start the mongo service but it is getting failed and the log file is not getting updated as well.. 2015-10-13T09:53:26.133+0530 ...
0
votes
0answers
32 views

MongoDB Update If… Else… Statement

So I'm trying to run an update operation that includes a few conditions but I'm unsure of the correct syntax to use. For example, if field name "status" equals "some value", then change the value to ...
1
vote
0answers
13 views

how to authenticate user added to the router on the shards added in that router in mongodb sharded cluster set up

I have added the user in the admin database of the router(mongos) and then generated the key file and shared it across all component that is config server and the replica which need to be added in the ...
1
vote
1answer
56 views

How do long string field names affect MongoDB database size?

I am using MongoDB and the names of my fields are strings with 10-20 characters. A typical document consists of 30.000 columns filled mostly with floats, like 1.2, 10.5, 2.55. It's size is 1MB. Do ...
0
votes
0answers
33 views

Is there a way of implementing a composite primary key with varying fields in MongoDB?

Here is the information about my development environment: -Mongodb 3.0.0 -Microsoft Visual Studio Professional 2013 -.NET Framework 4.5 We are trying to design some MongoDB collections at work ...
1
vote
1answer
38 views

How indexing on a date field that is constantly updated and or omitted affect performance?

In mongo, I have a collection with a date field called last_updated I would like to index. Reason being, I am often querying on a date range of that field, in addition to sorting by that field. I ...
0
votes
1answer
127 views

Mongo error : Could not lock auth data update lock. on root user

i have a mongodb on 2.6.9. my connected user is root: mongo --username myadmin --password thepassword --port 27018 --host 127.0.0.1 admin MongoDB shell version: 2.6.9 connecting to: ...
0
votes
1answer
30 views

How set balancing as main task for sharder MongoDB cluster?

I have a big collection (over 400 millions records) which I want to divided between 4 shards. I created infrastructure (4 shards, config server, mongos) and all work well (balancer is working and data ...
1
vote
0answers
80 views

MongoDB very poor query performance vs Oracle

I'm a MongoDB noob and trying to import data from an Oracle table. My Oracle table has 1 unique index on a single column, which is an id (a number - primary key). I successfuly imported data to ...
0
votes
0answers
25 views

MongoDB: poor compression rates

I'm importing a small set of data from Oracle in MongoDB. Basically, I have a table which is about 1Gb in Oracle (avg_row_len x nb. rows, i'm not counting the index sizes. Though data is compressed). ...
0
votes
1answer
54 views

MongoDB Unrecoverable Failure

My machine (OSX) had a power failure and when restarted, I have one db in Mongo that is completely unrecoverable. I am using the db per directory with dbpath and logpath specified options and was able ...
1
vote
2answers
43 views

MongoDB automatic failover between 2 data centers

If I deploy a MongoDb replica set across only 2 data centers, if one entire data center fails, can there be automatic failover to the other data center? Consider the situation where 1 data center has ...
0
votes
1answer
25 views

How to remove blockages in MongoDB when multiple write query comes for same collection at same time

I want to use MongoDB in a clustered environment with 3 shards and make each shard replicated. MongoDB is a single threaded so when multiple requests hit shard 1 to insert or edit one collection at a ...
0
votes
1answer
56 views

cannot repair database in mongodb

I accidentally deleted 2 data (mydb.47, mydb.62) files from my /data/db of my mongodb. I have rest of the files in place... Now my mongodb won't start up..I tried repairing it using this command ...
0
votes
0answers
24 views

convert mongo standalone to replicaset in docker

I've a Docker instance with mongo. This run as standalone configuration. Now I would to change entrypoint.sh to run itself as replica set following official guide standalone to replica set Any ...
1
vote
1answer
60 views

Measuring MongoDB I/O and CPU performance

I am new to MongoDB and I'm experiencing this NoSQL db through a series of very simple queries, with an Oracle exported data set. Aside measuring the execution time with primitives like ...
0
votes
0answers
42 views

MongoDB: Change block_compressor for existing collection

I have a server running with wiredTiger storage engine, but without compression enabled globally. Now I want to change the "block_compressor" option for a single collection to use "snappy". According ...
1
vote
1answer
61 views

Ideal database to store/query data submitted through dynamic user created forms

I am designing a web application that allows administrators to create public facing forms. The fields that can be included in the forms are anything from text fields to radio buttons. I need a ...
1
vote
1answer
22 views

Export and Import MongoDB?

I come from a bash and mysql environment. I'm trying to get use to mongodb. I see there are different ways to export and import mongodbs. Does anyone know the bash and mongodb equivalent of ...
0
votes
3answers
1k views

mongoimport error - Failed: error connecting to db server: no reachable servers

I am currently trying to learn mongodb and I am having trouble finding a solution for this problem. When I run a mongoimport command it I get the following error: ~ mongoimport --host localhost ...
0
votes
0answers
33 views

design of schema in mongoDB

I'm using mongoDB as my database. i have an record of 100 hospitals. To store all the information i'm designing schema of my database for that i've three solutions: i can create collection for each ...
0
votes
0answers
8 views

impact on Nodejs app - Disable Server-Side Execution of JavaScript --noscripting

What does the startup option --noscripting do exactly? What is the impact on a Nodejs app? What does not work anymore if we Disable Server-Side Execution of JavaScript? The admin guys are the only ...
1
vote
1answer
38 views

mongodump replicaset - 10 hours data loss acceptable - do we need --oplog (oplog.bson) option?

We have a 3 node replica set. We take backups from secondary with mongodump. Our customer said that it's ok too loose 10 hours of data in worst case. So we decided we don't need point in time ...
1
vote
0answers
24 views

what is getmore / cursor batch

In MongoDB world you see often getmore. For example in mongostat. What is that exactly? What would be the analogous term for MySQL/MariaDB or Oracle RDBMS?
3
votes
1answer
44 views

Does it make sense to limit Mongo RAM?

I have a Windows server running MongoDB. My database has big indexes and all RAM is usually busy. As I know, it can be a cause of Windows swapping and performance issues. Does it make sense to limit ...
-2
votes
1answer
75 views

Why are writes failing in MongoDB?

Here is the information about my development environment: Microsoft Visual Studio Community 2015 .NET Framework 4.6 ASP.NET MVC assembly System.Web.Mvc Version=5.2.3.0 MongoDB.Driver 2.0.1.27 ...
0
votes
1answer
69 views

Why does MongoDB give me the cannot use 'w' > 1 when a host is not replicated Error message?

Here is the information about my development environment: •Microsoft Visual Studio Community 2015 •.NET Framework 4.6 •ASP.NET MVC assembly System.Web.Mvc Version=5.2.3.0 •MongoDB.Driver 2.0.1.27 ...
1
vote
0answers
33 views

Identify a blocking process in MongoDB

I have a single MongoDB instance is performing quite badly. I noticed that db.currentOP().inprog.length quite often becomes quite big, sometimes even goes up to 100. When I drill down to the actual ...
0
votes
1answer
356 views

MongoDB replica set configuration error

I am trying to set up a MongoDB replica set on Digital Ocean. I edited /etc/mongo.conf and specified replica set id: replSet=rs1 and did not change anything else. I did rs.initiate() on the first ...