Skip to content

Instantly share code, notes, and snippets.

@dmitchell
Last active August 29, 2015 14:07
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dmitchell/2f6c458d5eb64f30678a to your computer and use it in GitHub Desktop.
Save dmitchell/2f6c458d5eb64f30678a to your computer and use it in GitHub Desktop.
GridFS auth failure on Jenkins
File "/home/jenkins/workspace/edx-all-tests-auto-pr/SHARD/1/TEST_SUITE/bok-choy/common/lib/xmodule/xmodule/contentstore/mongo.py", line 40, in __init__
_db.authenticate(user, password)
File "/home/jenkins/edx-venv/local/lib/python2.7/site-packages/pymongo/database.py", line 902, in authenticate
self.connection._cache_credentials(self.name, credentials)
File "/home/jenkins/edx-venv/local/lib/python2.7/site-packages/pymongo/mongo_client.py", line 459, in _cache_credentials
auth.authenticate(credentials, sock_info, self.__simple_command)
File "/home/jenkins/edx-venv/local/lib/python2.7/site-packages/pymongo/auth.py", line 243, in authenticate
auth_func(credentials[1:], sock_info, cmd_func)
File "/home/jenkins/edx-venv/local/lib/python2.7/site-packages/pymongo/auth.py", line 222, in _authenticate_mongo_cr
cmd_func(sock_info, source, query)
File "/home/jenkins/edx-venv/local/lib/python2.7/site-packages/pymongo/mongo_client.py", line 693, in __simple_command
helpers._check_command_response(response, None, msg)
File "/home/jenkins/edx-venv/local/lib/python2.7/site-packages/pymongo/helpers.py", line 178, in _check_command_response
raise OperationFailure(msg % errmsg, code, response)
OperationFailure: command SON([('authenticate', 1), ('user', u'redacted'), ('nonce', u'redacted'), ('key', u'redacted')]) failed: auth fails
@dmitchell
Copy link
Author

MECHANISMS = frozenset(['GSSAPI', 'MONGODB-CR', 'MONGODB-X509', 'PLAIN'])
"""The authentication mechanisms supported by PyMongo."""

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment