How can we help?

Help via Chat 24h from monday to friday

MongoDB at Umbler

Welcome to Umbler's MongoDB HUB  

Here you'll find plenty of tutorials about MongoDB at Umbler: From creating a database, to connecting it with your application. Check out the first steps to successfully host your MongoDB instance.

You may also want to check out our Node.js guide, click here.

The first step to create a database, is to access your Control Panel.

Once you're in the Control Panel, click on the option Domain > Site > Database.

An important tip is to select the MongoDB database on the top of the screen, where it's highlighted.

umbler_mongo_create

After filling all fields and choosing the size of your database, click on Finish and wait until it's created.

Click on the database you want to connect.

umbler_mongo_list

Use the host information that fits your application the best.

umbler_mongo_details_internal_acess

You need to focus on what's highlighted, just copy the URL and the authentication information from the database.

The internal access will only work for applications that are running inside Umbler.

Click on the database that you want to connect.

umbler_mongo_list

The following screen will show up:

umbler_mongo_details_external_acess

You'll see the internal and external connection information, since you want to connect from an external application, you need to focus on what's highlighed above.

The external access can be made using Database Management Tools, such as Robo 3T, MongoDB Compass and others.

In order to import your MongoDB database, you must have MongoDB installed in your computer, as well as the MongoDB dump file that you want to import.

The first step to restore the database is to open your CMD as administrator and access the folder where your MongoDB is installed.

As shown bellow:

The highlighted command is the default path where mongoDB is installed on Windows.

cd C:\Program Files\MongoDB\Server\3.4\bin
import_mongodb_umbler_terminal_1

Once you in the folder containing the files, issue following command:

mongorestore -h yourExternalHostname -d yourDbName -u yourDbUsername -p yourDbPassword --drop pathToYourDump
 

Here's an image with a real example:

import_mongodb_umbler_terminal_2

The highlighted field is the command itself, followed by the logs indicating that the restore was successful.

In order to export your MongoDB database, you must have MongoDB installed in your computer.

The first step to create the dump is to open your CMD as administrator, and access the folder where your MongoDB is installed.

As shown bellow:

The highlighted command is the default path where mongoDB is installed on Windows.

cd C:\Program Files\MongoDB\Server\3.4\bin
import_mongodb_umbler_terminal_1

Once you in the folder containing the files, issue following command:

mongodump -h yourExternalHostname -d yourDbName -u yourDbUsername -p yourDbPassword --out placeToSaveTheDump
 

Here's an image with a real example:

import_mongodb_umbler_terminal_3

The highlighted field is the command itself, followed by the logs indicating that the exportation was successful.