MongoDB Error Codes
You can use this page to learn more about FileCloud Server error codes.
MongoDB is a cross-platform document database. Classified as a NoSQL database, MongoDB does not use the traditional table-based relational database structure.
Instead, MongoDB uses JSON-like documents with dynamic schemas, making the integration of data in certain types of applications easier and faster.
FileCloud requires MongoDB for database creation and management.
You can also troubleshoot these errors by reading MongoDB documentation.
MongoDB Errors | ||
---|---|---|
Code | What it means | How to Fix it |
01000 mongodb exception | In general, an exception breaks the normal flow of execution in a software application. This occurs when there are unexpected conditions, for example, trying to open a file that does not exist.
| Verify you have enough resources to run MongoDB. Check to see if you need to repair the database. Verify that Apache is running. Check the Mongo logs to reveal issues. By default, MongoDB creates the Windows log file at this path: C:\xampp\mongodb\bin\log\mongodb.log By default, MongoDB creates the Linux log file at this path: /var/log/mongodb/mongodb.log If the log file is not found, then check the MongoDB config file for the location. |
01001 cannot connect to mongodb server | A connect command to get to the server fails. For example: [root@xxxx bin]# ./mongo MongoDB shell version: 2.0.1 connecting to: test Mon Oct 31 18:41:32 Error: couldn't connect to server 127.0.0.1 shell/mongo.js:84 exception: connect failed | 1. Verify that MongoDB server is running. Try to open this in your web browser: If you can't, this means that you have to start MongoDB server.
2. Ensure all paths to the MongoDB server are absolute. An absolute or full path points to the same location in a file system, regardless of the current working directory. To do that, it must include the root directory.
3. Add your server IP to the Bind list. Open the file /etc/mongod.conf Find the bind_ip line Add the IP address of the machine from where you are connecting bind_ip = 127.0.0.1, your Remote Server Machine IP Address Here For example: bind_ip = 127.0.0.1,192.168.1.5 Then restart mongodb service: sudo service mongod restart Make sure mongodb port is opened in the firewall. You can also comment the line, if you are not worried about security.
4. Verify you are running MongoDB as root user. start: Rejected send message, 1 matched rules; type="method_call", sender=":1.86" (uid=1000 pid=3215 comm="start mongodb ") interface="com.ubuntu.Upstart0_6.Job" member="Start" error name="(unset)" requested_reply="0" destination="com.ubuntu.Upstart" (uid=0 pid=1 comm="/sbin/init") tester@TesterPC:/var/lib/mongodb$ mongosh You must be trying to start the mongodb service as user other than root. You must be root user. Log in as root and then run following command: sudo bash followed by service mongodb start
Check if the following file exists: /var/mongo/mongod.lock exists If it exists, check to see if it has content. If it is not empty, then remove the file. Then restart MongoDB. service mongodb start 6. Check the Mongo logs to reveal other issues By default, MongoDB creates the Windows log file at this path: C:\xampp\mongodb\bin\log\mongodb.log By default, MongoDB creates the log file at this path: /var/log/mongodb/mongodb.log If the log file is not found, then check the MongoDB config file for the location. For example, other connection issues can include: Wed Dec 21 03:35:04 [initandlisten] connection refused because too many open connections: 819 |
01002 cannot backup db | By default, FileCloud installs the Mongo database server on the same machine as the webserver without any authentication settings. If you need to enable authentication for added security or if you are hosting the database on a different machine than the web server, then these settings can cause this backup error if they are not configured correctly. For more information, read the MongoDB Manual on Backup | 1 Verify whether MongoDB Authentication is Enabled. If it is, ensure the settings are correct, or disable authentication to troubleshoot the backup error. Enable MongoDB Bind IP and Authentication 2. Ensure all paths to the MongoDB server are absolute. An absolute or full path points to the same location in a file system, regardless of the current working directory. To do that, it must include the root directory. |
01003 cannot get host string | Host String refers to the URI format used for defining connections between applications and MongoDB instances. The format is the same for all official MongoDB drivers. mongodb://[username:password@]host1[:port1][,host2[:port2],...[,hostN[:portN]]][/[database][?options]] host1 parameter is required. It identifies a server address to connect to. It identifies either a hostname, IP address, or UNIX domain socket. For more information, read the MongoDB Manual on | If you see this error, then either the host1 parameter is not specified correctly or the server address is not available. 1. Check the Mongo logs to inspect the host1 parameters. By default, MongoDB creates the Windows log file at this path: C:\xampp\mongodb\bin\log\mongodb.log By default, MongoDB creates the log file at this path: /var/log/mongodb/mongodb.log If the log file is not found, then check the MongoDB config file for the location. 2. Verify the host1 parameters are correct:
3. Verify that host1 server is available. 4. Ensure all paths to the MongoDB server are absolute. An absolute or full path points to the same location in a file system, regardless of the current working directory. To do that, it must include the root directory.
|
01004 this feature is not implemented | The version of MongoDB that you are running is not compatible with the version required by FileCloud. MongoDB lists potential version issues on its Website. Windows Subsystem for Linux (WSL) is Unsupported The mongodb-org package is officially maintained and supported by MongoDB Inc. and kept up-to-date with the most recent MongoDB releases. This installation procedure uses the mongodb-org package. | 1. Run the correct version.
2. Remove incorrect versions.
Run the following command to check if the mongodb package is already installed on the system. sudo apt list --installed | grep mongodb To completely remove and purge the mongodb package before attempting this procedure in FileCloud: sudo apt remove mongodb sudo apt purge mongodb |
01005 cannot insert record | ||
01006 cannot update record | ||
01007 cannot delete record | ||
01008 cannot fetch record | ||
01009 instance is down |