I’m trying to change the priority of the members of the replica set: cfg = rs.conf(); output: } cfg.members[5].priority = 0.5 cfg.members[4].priority = 0.5 but id:3 change normaly: cfg.members[3].priority = 0.5 what am I doing wrong? And why my version of the config too big? So many times that I couldn’t change the configuration) Answer You should address to elements
Tag: mongodb
Docker-compose – mongodb could not be authenticated
After installing Docker Toolbox on Windows 10 and starting docker-machine, I run docker-compose up, I run into this error: The following packages cannot be authenticated mongodb-org-shell The code in the dockerfile: RUN apt-key adv –keyserver hkp://keyserver.ubuntu.com:80 –recv EA312927 RUN echo “deb http://repo.mongodb.org/apt/ubuntu trusty/mongodb-org/3.2 multiverse” | tee /etc/apt/sources.list.d/mongodb-org-3.2.list RUN apt-get update RUN apt-get install -y mongodb-org-shell RUN apt-get install -y mongodb-org-tools
Can’t Write to /sys/kernel/ to disable Transparent Huge Pages (THP) for MongoDB on OVH CentOS 7
My Issue I am having trouble removing MongoDB warnings about Transparent Huge Pages (THP) on an OVH CentOS 7 installation, and the issue appears to be the inability to write to /sys/kernel/mm as root. First, I realize the OVH kernel is customized, and I know many of you will say to go with a fresh non-customized kernel, but that’s not
Remove string in file on linux
I am looking to remove the _id field and its value which changes: I would like to use sed or any other command. Answer It is easy with jq. O/P:
update mongo 2.4 to 2.6
I want to upgrade my mongodb to 3.2, but when I try to upgrade to 2.6 I already get error What I do: I have a test VM with restored dump database from production sever. I download mongodb 2.6 and extracted. I run mongo from /tmp/mongodb-linux-x86_64-2.6.11/bin/mongo In console mongodb run use admin db.upgradeCheckAllDBs() In there are no problem(I think), I
Allow MongoDB remote access for specific IP
I have an application server with some PHP code on it which needs to access a distant MongoDB server. In order to do this I want to allow remote access on my MongoDB server, but only for the application server IP. I understand that I need to change the bind_ip value located in /etc/mongodb.conf in order to do this. I
Why node.js+mongodb does not gives 100 req/sec throughput for 100 req sent in a second?
I kept node.js sever on one machine and mongodb sever on another machine. requests were mixture of 70% read and 30% write. It is observed that at 100 request in a second throughput is 60req/sec and at 200 requests second throughput is 130 req/sec. cpu and memory usage is same in both the cases. If application can server 130 req/sec
Cannot start mongodb service
I tried to start mongodb service from root user and it fails on the error that it cannot open file j._8, I checked the permissions as well. This was working fine before. This is the journal folder. I cannot open the file j._8 with cat or less as root. Please help to fix this. Thanks in advance Answer solved the
How do I know if MongoDB needs more CPU/RAM? [closed]
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers. This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question
Mongodb connection in PHP not working
I am using Ubuntu 12.04 LTS and installed pecl in /opt/lampp/bin/ . When installing second time its throwing error – Command run previously – pecl install mongo pecl/mongo is already installed and is the same as the released version 1.5.1 install failed Now when I am Checking by – echo extension_loaded(“mongo”) ? “loadedn” : “not loadedn”; It is showing not