Questions tagged [mongodb]

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

Filter by
Sorted by
Tagged with
0
votes
1answer
948 views

How to structure a MongoDB database to allow for multiple users to use the same account with restrictions based on roles?

Ok, firstly I'm very new to MongoDB, and newish to DB development/management as a whole. I've done a unit using Oracle through uni, but apart from just manipulating fields through the phpmyadmin ...
0
votes
2answers
924 views

How to find all invalid document based on jsonSchema validator?

One of the new feature in MongoDB 3.6 is jsonSchema validator. I can create a collection with an validator like below: "validator" : { "$jsonSchema" : { "...
0
votes
1answer
2k views

Mongo crash after 2 seconds of starting

My mongod service crashes within 2-5 seconds of starting. I don't understand why. Here are the systemctl logs: systemctl status mongod.service mongod.service - High-performance, schema-free ...
0
votes
1answer
75 views

what is so special about MongoDB indexing?

I was reading the MongoDB documentation, where it lists Indexing as an special feature. But after reading the doc, I still can't see what it is that makes MongoDB index special. Anyone can explain?
0
votes
1answer
646 views

Multiple system.replset collections in local

I have a replicaset that's showing multiple system.replset collection in the local db. replset1:PRIMARY> show collections; me oplog.rs replset.minvalid slaves system.indexes system.profile system....
-1
votes
1answer
559 views

Problem with Mongodb 3.6 version [closed]

there is a problem with me i cant found the mongod.exe mongo.exe In MongoDB 3.6 version, so please help me with an installation of MongoDB properly there is no any videoes on youtube for how to ...
-1
votes
1answer
766 views

mongos and monod have the same default port?

Is it true that by default mongos and mongod use the same port - 27017? I had to pick a different port for one of these two, for example --port 37017 for mongos.
-1
votes
1answer
209 views

What database do most mobile start ups use? [closed]

mongodb? MySQL? PostgreSQL? If someone would add pluses and minus, let me know. Why I ask: I am a mobile startup. I need a database that supports spatial indexes. The spatial index must be able to ...
-1
votes
2answers
663 views

MongoDB replication to one machine

Does MonogDB supports replication where I have many machines with MongoDB that have different data and I want to replicate this data to one, and only one MongoDB?
-1
votes
1answer
490 views

MongoDB Performance of Overwriting an Array Field vs Individually Updating the items

The problem I am facing is basically updating the inventory when an order is received in a MongoDB database.The general hierarchy is as follows Manufacturer: { ... Items: [ ... ...
-1
votes
1answer
964 views

mongodb not working after install

I followed these steps at http://www.liquidweb.com/kb/how-to-install-mongodb-on-ubuntu-14-04/ as I usually do, since everyone on ubuntu knows the mongo docs don't work. I'm actually on kubuntu 15 I ...
-1
votes
1answer
4k views

Getting next and previous document

In a mongo collection I have a list of words (millions words). {word:'a'} {word:'b'} {word:'x'} {word:'y'} {word:'z'} I need to get lexical adjacent of a word. I am looking for most efficient method....
-1
votes
1answer
21 views

Trouble designing mongodb 1-many collection/query that could grow without bounds

So in an application I'm currently working on, I'm having an issue designing a collection. I can't give away too much information about the application, but here is a similar (albeit not as realistic) ...
-1
votes
1answer
31 views

Mongodb restriction on update to only allow “$push” operator

Mongodb V 4.0 I want to restrict a user's role by only allowing new inserts to the collection. Either as a new document, or as an append to the document. I don't want the user to be able to update(...
-1
votes
1answer
169 views

Unstructured point cloud data from MongoDB vs filesystem

NOTE: I am using geographic locations here in my question, but those who do image processing likely face similar questions/issues. That is why I've titled the question using unstructured point could ...
-1
votes
1answer
28 views

How to backup documents to s3 in a particular collection older than specific dates in a mongodb collection where timeseries data are stored? [closed]

I have mongodb database. I have a collection in that stores time series data, time values are stored as ISODate. Older than few days are not required on database, but required to be backed up in aws ...
-1
votes
2answers
2k views

Unable to start MongoDB with --replSet [closed]

I have been trying to install Rocket.chat which requires MongoDB, the instruction for configuring MongoDB is here: https://rocket.chat/docs/installation/manual-installation/ubuntu/index.html#install. ...
-1
votes
1answer
262 views

bigchaindb set up and run cluster node error

I have been following the instructions given on: https://docs.bigchaindb.com/projects/server/en/latest/production-nodes/setup-run-node.html in an attempt to create a cluster. However I get this error ...
-1
votes
1answer
34 views

Updating a mongoCluster

We have Mongodb 3.2.6 as a cluster with 2 arbiter and 2 working data nodes running. Now we want to update to version 3.4.3. What is the intended way of doing this? Can I update one by one and will ...
-1
votes
1answer
417 views

why are NoSQL databases better suitable for container platforms (cloud)?

In the article from Linux-Magazin 04/2017 Relationale Datenbanken als Container (sorry German and paywall) there is written in conclusion that NoSQL DBs are better suitable for containers than the "...
-1
votes
2answers
574 views

What database should I use to create a webmail service like gmail? [closed]

I planned to use python for my frontend with django framework. But for backend, I have no idea which database I should use. Since it involves plenty of reads and writes can someone point me in the ...
-1
votes
1answer
29 views

Database are not visible to users who has access in MongoDB

We are using Robo 3t tool to interact with Mongodb. We could see the user has read access on 2 databases but when the user is connected to MongoInstance that databases are not visible to the users. ...
-1
votes
2answers
1k views

join two collections with group by and sum in Mongodb

i have this two collection and i want to join, after this I want to sum the value of TotalPrice each orderdate : some line of my two collections the first collection date : {"Id_Date":1,"...
-1
votes
1answer
134 views

What are the pros and cons of having more data-bearing members in a MongoDB replica set? [closed]

A 3 member replica set has the same fault tolerance if all 3 members contain a copy of the data or if one is an arbiter so why would I ever want all 3 members to have a copy of the data? What is a ...
-1
votes
1answer
158 views

Automate setting secondary node to primary when majority nodes are down-MongoDB

There are many ways to force a secondary node to become a primary when majority nodes are down in mongo replica set. But we need to do this manually. For eg, forcing reconfig: cfg = rs.conf(); cfg....
-1
votes
1answer
38 views

MongoDb User with readWrite can create database

I dont understand why my user can create data base. The user "toto" with role "readwrite" on DB1 can create a DataBase (db2). And with the same account "toto" I can create a user and affect this user ...
-1
votes
1answer
41 views

MongoDB replica set configuration problem

I'm facing some issues when trying the following: I have a three-node MongoDB 4.0 cluster, no sharding, one mongodb instance as primary, the rest as secondaries. When I shut down the primary, one of ...
-1
votes
1answer
165 views

MongoDB RBAC to only one document

Is it possible to give access to a user to only one document in a collection which is in my Mongo Data Base ? I saw that this is possible for one collection.
-1
votes
1answer
578 views

MongoDB: Read Role Able to Write and Edit Collections

I have created a user in MongoDB and it has read permission to a db, which i verified it by db.getUser("username"). It confirms that it has read access. However i am able to create and update ...
-1
votes
1answer
591 views

Why does mongodb primary stops writing sometimes?

I have 3 mongodb servers in our production environment with replica set configured. All the 3 are running in 3 different Ec2 instances. The application server is running in another instance. The ...
-1
votes
1answer
140 views

Suggestions for type of DB to use (Elasticsearch vs MongoDB vs Hadoop)

I am hoping some of you highly skilled DBAs can provide some insight as to the best DB to use for this dataset. This is a relatively simple dataset with no relationship needed between the entries. ...
-1
votes
1answer
318 views

Regarding restarting instance mongodb

while restarting the mongodb instance the directory mongodb in /var/run is deleting after restarting the instance the again i am creating the directory in /var/run and restarting the service whats the ...
-1
votes
1answer
444 views

How to make mongos to be in a replica set?

I have a shard cluster: one mongos, three shard replica sets and one config replica set. My application only talks to the mongos for read/write to mongodb. I wonder whether I can make the mongos ...
-1
votes
1answer
268 views

Add mongodb cluster to a replica set

I have a database db on mongodb server s0 with collection coll which is not sharded. To shard this collection I set up a sharded cluster and add s0 to replica set rs0. Now I want to add the sharded ...
-1
votes
1answer
223 views

Duplicate data inserted while failover MongoDB

I'm inserting 3000 documents and in between my primary goes down and secondary becomes new primary I find my application has inserted 3002 documents, 2 documents are duplicate. What could be the ...
-1
votes
1answer
584 views

Benchmarking Mongodb Queries Without cache

I want to benchmark some Mongodb queries by calculating their execution time but I could not find a way to do so without caching : The first time I execute a query it takes a decent amount of time and ...
-1
votes
1answer
230 views

Selective synchronization between distributed clusters

What's the best practice for the following scenario: I've an embeded device with a single, lightweight database; a powerful server with a cluster; a cluster in the cloud. I'd like to synchronize the ...
-1
votes
2answers
225 views

MongoDB or ElasticSearch

Which one of them is good to use? I'm developing a application which will have the following functionalities. Multiple users Each user will have their own database Data objects will be different; ...
-1
votes
1answer
909 views

How many replica set members consitute majority in MongoDB?

MongoDB 3.2 manual is not very clear as to what constitutes a majority with regards to write concerns in a replica set e.g. w="majority". It is somewhat subjective. In a replica set of 10 members ...
-1
votes
2answers
226 views

Mongo HDD disk grows to fast when insert / deleting data

My Mongo version is 2.6.9 I have an application that is inserting, reading and removing data from Mongo. That's all working fine. However the disk space increases exponentially. My HDD is around 120 ...
-1
votes
1answer
1k views

Mysql InnoDB vs Mongodb write performance

I need to increment a counter each time a web page is rendered. When I use mongodb to do that, I can do about 16000 writes per second on a 4 cores/8 threads CPU on a regular disk. When I use Mysql ...
-1
votes
1answer
110 views

Data containing list of all the domain names. MongoDB or MySQL?

Data containing list of all the domain names (currently present in the Internet world), along with few attributes (5-6 or maybe 10, each attribute being a column) will be considered as Big Data? ...
-1
votes
1answer
110 views

Updating Document in MongoDB without Alphabetically order

I am making one project on MongoDB and inserted some documents and now i am updating the documents by this code.. bson_init( query ); bson_append_string(query, "First", "A"); bson_append_string(...
-1
votes
1answer
155 views

Installation problems

After a fresh install of mongodb following the instruction here https://docs.mongodb.com/manual/tutorial/install-mongodb-on-ubuntu/index.html I seem to have a problem: ludo@aegir:~$ sudo service ...
-1
votes
1answer
401 views

Mongodb upgrade from 3.0 to 3.2

I have upgraded the mongodb from 3.0.15 to 3.2 mongodb3.0.15 Configuration : Three shards Three config servers mongodb3.2 Configuration : Three shards Three config servers No replica sets I ...
-2
votes
1answer
76 views

How sharding of databases effect ACID property or transactions?

MySQL (and other Relational Databases) are known to be ACID compliant with respect to transactions. However, when databases are sharded, does the ACID property of transactions break since now ...
-2
votes
1answer
17 views

Please guide me to change 1 node standlone to 2 node 1 arbiter Replicate Set [closed]

Please guide me to change 1 node standlone (have data) to 2 node 1 arbiter Replicate Set
-2
votes
1answer
61 views

Is MongoDB an appropriate choice for storing large files as compared to MySQL? [closed]

I'm working on a project to store large JSON files (~1 MB each) in a database, with 10 of these files linked to one user profile. Normally I would use MySQL, and have two tables, one with the meta ...
-2
votes
1answer
181 views

MongoDB failed to start after adding keyFile config

I have issue with mongod service after adding keyFile in config. I follow instruction from here : https://docs.mongodb.com/manual/tutorial/deploy-replica-set-with-keyfile-access-control/ after adding ...
-2
votes
2answers
55 views

What DB should I use in my case? [closed]

I'm writing a software in C# that downloads some data from a website and stores it in a DB daily. The data is cases that were processed at that day. Each case has attributes like case_creation_date,...