Version-Release number of selected component (if applicable): devenv-fedora_2387 centos/mongodb-26-centos7 17d33d90862d rhscl/mongodb-26-rhel7 027d85807877 Description of problem: when login in mongodb26 in container, appears error "open for '//.mongorc.js' failed with errno:13 Permission denied" How reproducible: Always Steps to Reproduce: 1.Run the mongodb-26-centos7 image $ mkdir -p /home/user/database && chown -R 234523:998 /home/user/database $ docker run -d -u 234523 -e MONGODB_USER=user -e MONGODB_PASSWORD=pass -e MONGODB_DATABASE=test_db -e MONGODB_ADMIN_PASSWORD=pass -v /home/user/database:/var/lib/mongodb/data:Z centos/mongodb-26-centos7 2.Access into container $docker ps | grep mongo (to get the container id) $docker inspect <container_id> | grep IPAddress $docker exec -ti <container_id> scl enable rh-mongodb26 /bin/bash 3. Create SQL queries in container bash-4.2$ mongo test_db -u user -p pass MongoDB shell version: 2.6.9 connecting to: test_db Welcome to the MongoDB shell. For interactive help, type "help". For more comprehensive documentation, see http://docs.mongodb.org/ Questions? Try the support group http://groups.google.com/group/mongodb-user 2015-09-24T03:17:01.840+0000 In File::open(), ::open for '//.mongorc.js' failed with errno:13 Permission denied > Actual results: when Login in mongodb26 in container, appear errors Expected results: login in successfully ,no errors
wewang: for images being provided by the SCL team, i'll be reassigning these bugs to their components, is that going to cause a problem for your processes/reporting? SCL team: the openshift QE team expects you'll move the bug to ON_QA once it is ready for them to re-test.
Ben Parees:ok,and give similar errors like : bash-4.2$ mongo sampledb -u userTP7 -p3mTi1WiM4EBGa1KT MongoDB shell version: 2.6.9 connecting to: sampledb Welcome to the MongoDB shell. For interactive help, type "help". For more comprehensive documentation, see http://docs.mongodb.org/ Questions? Try the support group http://groups.google.com/group/mongodb-user 2015-09-25T01:57:32.520+0000 In File::open(), ::open for '//.mongorc.js' failed with errno:13 Permission denied > show dbs; 2015-09-25T01:57:49.423+0000 listDatabases failed:{ "ok" : 0, "errmsg" : "not authorized on admin to execute command { listDatabases: 1.0 }", "code" : 13 } at src/mongo/shell/mongo.js:47 >
Should be fixed in upstream by this pull request - https://github.com/openshift/mongodb/pull/91 I am going to sync it to the dist-git soon...
verified in devenv_fedora_2444 centos/mongodb-26-centos7 image_id:3c37801bcaa6 rhscl/mongodb-26-rhel7 image_id:fccbcf0c20d7 bash-4.2$ mongo test_db -u user -p pass MongoDB shell version: 2.6.9 connecting to: test_db Welcome to the MongoDB shell. For interactive help, type "help". For more comprehensive documentation, see http://docs.mongodb.org/ Questions? Try the support group http://groups.google.com/group/mongodb-user > show collections; > doc={"a":"test1"}; { "a" : "test1" }
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2015-2056.html