Questions tagged [mongodb]

MongoDB is a document oriented database (also known as NoSQL database).

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

MongoDB logrotate with occasional file size changed while zipping error

I use this script for rotating MongoDB v3.6.3 logs: /var/log/mongodb/mongod.log { weekly rotate 52 compress missingok notifempty sharedscripts ...
0
votes
0answers
288 views

MongoDB secondary crashes on initial sync because of too many journal files on RAID 10

My secondary DB server went down, so I'm booting up a replacement secondary and trying to perform the initial sync. I've been following the tutorials and advice out there to use RAIS 10 on Amazon EBS ...
0
votes
2answers
962 views

Why mongodb hangs after some time?

We have a problem with mongodb (3.6.3) PRIMARY server. After some time it gets to a state where it is still PRIMARY but it is not accepting connections. The problem is that it keeps PRIMARY role and ...
1
vote
0answers
467 views

MongoDB shuts down everyday - why and how to fix?

I have a ubuntu 16.04 server on OVH. I run mongod on it like this mongod -f /etc/mongod.conf & It gets down everyday and I am not able to find the reason. I tried checking the logs but it's a ...
4
votes
3answers
1k views

Why doesn't MongoDB automatically restart?

It seems like MongoDB 3.6 isn't automatically configured to restart if it crashes. Looking at the systemd service that is bundled with the latest .deb package for Ubuntu 16.04LTS it doesn't seem to ...
0
votes
1answer
270 views

Disconnected primary replica set adding back into replica set

I'm looking for some advice on what to do with a primary replica set that gets disconnected from the network (e.g. data center network outage) to the extent that we promote one of the secondaries to ...
2
votes
1answer
255 views

MongoDB on AWS (EBS): 3 replicas vs. 2 replicas + Arbiter

We have a fairly large Mongo DB running in AWS. Currently, we are running with a replica set with 3 instances. Each instance has 5TB of attached EBS storage. This comes out to over $1000/month per ...
-3
votes
1answer
123 views

how to initiate and maintain mongo shard replica set from mongos server? [closed]

I am trying to initiate a mongo shards replica set from mongos server, I want my mongos to maintain replica set and able to add new server to replication if needed.
0
votes
0answers
249 views

mongorestore on replicsets from non-replicated DB instance

I have 2 environments(say A and B). MongoDb on A is running without replication and on B replication is setup with following replicaset instances B1 - Primary B2 - secondary B3 - arbiter I ...
0
votes
0answers
972 views

MongoDB, Windows Server, SSL Certificate, Compass Connection Not Working

System Info: Microsoft Windows 2016 Server on an Azure VM. MongoDB Community Edition 3.6 (with SSL) OpenSLL 1.1.0g 2 Nov 2017 Compass Community 1.11.1 Issue: I can connect from a remote workstation ...
1
vote
0answers
175 views

PM2 running but socket.io stops responding at times

I am using a hostgator vps with apache, for backend, I am using node.js and socket.io, it works fine but at times it just stops working. Pm2 is showing it online but it just stops responding. Can ...
1
vote
1answer
354 views

Mongodb in Kubernetes Timeouts when inserting large amount of data

We have an api in running which receives once a day multiple batches of large data that are inserted in a mongodb. We use the cvallance/mongo-k8s-sidecar for the replicationset configuration This ...
2
votes
1answer
7k views

MongoDB Compass error. 'not master and slaveOk=false'

I have just created a MongoDB Atlas instance so that I can give MongoDB a try. I have also downloaded Compass so that I can visually manage the data as I am not familiar with the MongoDB command line ...
0
votes
1answer
288 views

Could not login to docker container

I am trying to run my node.js app and mongodb using docker compose. I could setup the containers successfully as follows. The site is also working. But I could not login into the containers. docker ...
1
vote
1answer
290 views

How to scale horizontally a Parse Server?

My current setup is: 1 Parse Server - 2.6.3 1 MongoDB Server - 3.4.9 Both running on Ubuntu VMs. In a few weeks, we are expecting our user base to grow significantly! We are currently using 2 VMs ...
0
votes
0answers
1k views

Mongodb aborting after fassert() failure

I tried to reboot my server with shutdown -rF now command. After that I noticed mongodb service is not running. I tried to run it with sudo service mongod start, but the status is : mongod.service - ...
0
votes
1answer
1k views

Unable to start MongoDB on Ubuntu

I recently upgraded an Ubuntu 14 server to 16, and now I'm unable to start the MongoDB service. I'm using MongoDB 3.4, from Mongo's Xenial PPA at http://repo.mongodb.org/apt/ubuntu xenial/mongodb-org/...
0
votes
2answers
1k views

MongoDB setup on NUMA machine

I installed MongoDB 3.6 on my centos 7 machine and in the startup log I see a warning because I am running NUMA hardware: 2018-02-05T00:13:23.889+0100 I CONTROL [initandlisten] ** WARNING: You are ...
0
votes
1answer
401 views

MongoDB - Efficient backup

I have an application running on a Parse Server and another server where MongoDB runs. Both VMs are under Azure (Ubuntu VMs). A few weeks back, I wrote a db backup bash script which is run by crontab ...
1
vote
1answer
1k views

Docker container unable to connect to MongoDB Replica set

I'm using Docker Swarm to create a cluster of web applications and databases. I've four containers running, three of them are a single mongodb replica set and the last is a asp.net core application ...
0
votes
1answer
2k views

“not authorized” with auth turned on in Mongo

I am following the directions here to try and install Mongo 3.6 w/ authentication turned on. I have added a "root" user and I am able to login using Mongo shell and I added a application user as well,...
1
vote
1answer
717 views

MongoDB - Bind_IP Breaking changes and Replica set broken

I'm running Replica set on 3 Windows server 2012 R2 in my VPN. The servers IPs are: 192.168.1.1,192.168.1.2,192.168.1.3. MongoDB version: 3.4.2 I want to limit the access to the MongoDB servers only ...
0
votes
3answers
2k views

What's causing Ubuntu to have BUG: soft lockup warning so often?

EDIT: it turns out that this is not the only instances of the bug happening. It happens so often in my computer. Sometimes it involved another seemingly random process, such as: chromium-browser, ...
1
vote
1answer
498 views

MongoDB in container on Mac not binding ports

I am trying to setup a local Mongo instance using Docker for development purposes. I need to turn on authentication, and according to the docs it is possible. The problem is, after I create the ...
0
votes
1answer
1k views

Azure cosmosDB incredibly poor performance

I have a mongoDB on Azure cosmos and the performance is horrible. I have below the time for a few requests that my app does on startup and as you can see Mlab is up to 150 times faster! I am using the ...
2
votes
1answer
262 views

MongoDB background indexing very slow

I am running MongoDB on an Ubuntu on a single AWS EC2 as m4.2xlarge. The disk is 1280GB io1 22000 IOPS on XFS file system, 73% full (it is only used for MongoDB). The MongoDB server version is 3.4.10. ...
1
vote
1answer
297 views

mongodb wiredtiger engine from ext4 to xfs

I am having performance issue related to mongodb wiredtiger engine on an ext4 filesystem (https://docs.mongodb.com/manual/administration/production-notes/#kernel-and-file-systems) I have a replicaset ...
-2
votes
1answer
181 views

Mongodb is running out space - how to increase it?

My mongo has stopped running: $ sudo systemctl status mongodb.service ● mongodb.service - High-performance, schema-free document-oriented database Loaded: loaded (/usr/lib/systemd/system/mongodb....
0
votes
1answer
230 views

How to set config file to percona-mongodb

I have an percona/percona-server-mongodb image of mongo. I tried to mount my mongod.conf. How to set config and run mongo with config file? docker run --name mongo1 -v /opt/mongo/mongod3.conf:/etc/...
2
votes
1answer
2k views

can't upgrade from mongo 3.4 to 3.6 - Server min and max wire version are incompatible

I have a mongodb 3.4 cluster that I want to upgrade to 3.6. on a test run (virtualbox), I was able to do so, but with the real cluster I'm getting this rs.status() after calling add: ...
0
votes
1answer
391 views

How does configuring bind ip to localhost secures MongoDB instance?

Starting in MongoDB 3.6, MongoDB binaries, mongod and mongos, bind to localhost by default. How does it ensure security of MongoDB database?
2
votes
2answers
2k views

MongoDB not starting: Unable to create/open lock file No space left on device Is a mongod instance already running

MongoDB was already running for a couple of months then stopped suddenly. I ran: service mongod restart Restarting mongod (via systemctl): Job for mongod.service failed because the control process ...
0
votes
1answer
55 views

Would a hpc and/or shard mongo cluster solve my system bottle neck?

OK so I have an application running on Node.js on the same desktop system that is running my mongo service. I have a certain query that takes about 20 seconds to complete, this entire system ...
0
votes
1answer
425 views

Mongo client connects with command-line params, but fails with equivalent URI

When I create a MongoDB database with this script: #!/bin/bash javascript=' db.dropUser("admin"); db.createUser({ user: "admin", pwd: "password", roles: [ {role: "...
2
votes
1answer
4k views

Best way to handle 'MongoError: failed to connect to server on first connect' in Mongoose

In this GitHub issue for mongoose the developer stated that it is intended behaviour to crash the Node.js process if the initial database connection to MongoDB fails. It does this instead of trying to ...
1
vote
1answer
812 views

Control external IP address range for nodes in kubernetes cluster on Google Cloud

I would like to provide a whitelisted range for connections to a MongoDB Atlas instance running on Google Cloud. VPC Peering isn't yet available on Atlas for Google Cloud - Is it possible to provide a ...
0
votes
0answers
64 views

Percona pmm agent Mongodb

I'm setting up percona pmm for mongodb but the agent is chewing a lot on cpu. I have pmm-admin 1.5.0 on CentOS Linux release 7.2.1511 and Mongodb 3.0.12 and I see the /usr/local/percona/qan-agent/bin/...
0
votes
1answer
734 views

Allow anonymous access locally but not remotely with MongoDB?

I have a MongoDB server, which I have enabled auth on. I want to enable anonymous access (full read/write access) if someone tries to authenticate on my server locally (meaning if someone SSH into the ...
0
votes
2answers
653 views

Setting up docker.compose.test : 3000 port already allocated

I have a project which includes a docker setup that I'm trying to get working. My Dockerfile is: FROM node:8-alpine EXPOSE 3000 ARG NODE_ENV ENV NODE_ENV $NODE_ENV RUN mkdir /app WORKDIR /app ADD ...
0
votes
1answer
43 views

Providing an interface to ArangoDb that allows mongoDb style querying?

Problem I have an ArangoDb and would like for code written for MongoDb to use it. Theory They are both noSQL databases. Question Before I write my own interface are there any existing tools? Is ...
1
vote
2answers
1k views

Unable to rsync due to broken pipe

I'm trying to mirror a large Mongo database between from a production server to a dev environment by stopping Mongo on both servers and then running the command: rsync --archive --delete --recursive -...
0
votes
0answers
286 views

centos dedicated server backup strategy for mongodb and elasticsearch db

I have a main server (dedicated CentOS 7, XFS file system, 2X1TB SSD, software RAID1) connected via LAN to my backup server (dedicated CentOS 7, XFS file system, 2X2TB HDD, software RAID1) in my setup....
1
vote
1answer
2k views

Speed up mongodump+mongorestore

I have created a script to copy a MongoDB database to my machine. I am creating an SSH tunnel (ssh -L ...) then I connect to the tunnelled port with mongodump then I pipe its output to mongorestore: ...
0
votes
1answer
37 views

Most cost effective splitting of DBs and EC2 instances for mongo on AWS?

We want to change how we deploy MongoDB on AWS because of three issues: the shared database is way too big (some clients are shared) even the separate databases are getting noisy-neighbour issues ...
0
votes
1answer
91 views

Can I set my mongodb read preference to secondary in a reliable way?

I am running a 5 node replica set as 1 primary 3 secondary and 1 arbiter node. When I check my replication status with db.printSlaveReplicationInfo() I see 1 or 2 seconds of replication lag and I ...
1
vote
1answer
267 views

MongoDB 2.6 change nsSize in configuration?

I am running Mongo 2.6.12 and have built up quite a number of collections. I am very close to hitting the namespace cap so I want to change the 'nsSize' parameter from the default 16M to 1GB. I ...
0
votes
1answer
129 views

Parse Server - Image files' path returns localhost

I have deployed 2 Ubuntu servers on Azure. First, I have installed the Parse Server and the second, I installed MongoDB. (I have also put a ready db there from my previous server via mongorestore) ...
4
votes
1answer
5k views

“Excess arguments.” while doing “systemd daemon-reload” during MongoDB configuration

I am following the instruction mentioned in : To install and configure the basic elements for MongoDB in Ubuntu. During "Configure MongoDB username and password", on phase 4 "Step 4 - Enable mongodb ...
-1
votes
1answer
324 views

Hosting a PHP application on Kubernetes (Google Container Engine) [closed]

I need to host a PHP application on the Kubernetes infrastructure of Google Cloud Container Engine but I do not know how to procees, where to begin etc. Basically the app was running on a VM with ...
0
votes
2answers
528 views

mongodb, does one *need* a replica set for a minimal production db?

I'm fairly new to mongodb, and am tackling some devops issues here. We have a b2b saas product deployed on AWS where there is no network effect between customers, and some customers have much, much ...