How to install MongoDB GUI Compass and connect to a remote server
If you want to try MongoDB, here is a GUI to make it easier. Jack Wallen shows you how to install it.
MongoDB is one of the most popular NoSQL databases on the market (over 50% market share). This database is a great option for enterprise business or any company that wants to take advantage of huge data sets.
Views: Recruitment Kit: Database Engineer (TekriPublic Premium)
For those who just want to get MongoDB, you can look for a GUI tool to make it easy to work with data. One of the best options you can get is a compass. With this graphical database manager, you can create, import and search data, create integrated pipelines, visually explore and analyze your data, and even run commands within a shell.
Compass is free and open source, and can be installed on Linux, macOS and Windows.
I want to show you how to install Compass on Pop! _OS Linux, because the installation of both MacOS and Windows is as easy as installing any application on any platform. For those who use different tastes of Linux, the developers have made binary packages installable for both Ubuntu and RHEL-based distributions. Once we have it installed, I will show you how to connect it to a remote MongoDB server. Keep in mind that using the MongoDB Compass is the same regardless of the platform you are using.
What you will need
Pop! _OS To install Compass on Linux, you will need a user with a running example of the OS and the sudo feature. You will also need an instance of MongoDB running on a remote server. That’s it. Let’s start this DB party.
How to install Compass
The first thing we will do is download the .deb file for the compass. Save the file to your ~ / download directory and then open a terminal window. The command from the terminal issue:
sudo dpkg -i ~/Downloads/mongodb-compass*.deb
The installation will go off without a hitch. You will find the Compass Launcher on your desktop menu.
How to connect a compass to your remote server
Before we fire the compass, we need to configure our MongDB server for remote access. Return to the terminal window SSH on your MongDB server and open the MongDB configuration file with the command:
sudo nano /etc/mongodb.conf
In that file, you should see the line:
bind_ip = 127.0.0.1
You can change that line to either:
bind_ip = 0.0.0.0
bind_IP = 127.0.0.1, SERVER
Where SERVER is the IP address of the compass hosting machine. Use the first configuration option to allow connections from any machine on your network, and use the second option to specify only those machines that have access to the MongoDB service.
Save and close the file. Restart the MongoDB service with:
sudo systemctl restart mongodb
Open the compass and walk through the welcome screen. You will finally find yourself in a privacy configuration window (Figure A), Where you can enable / disable certain features and privacy-related options
Click Start using Compass and you will be greeted by a new connection screen (Figure B)
The only thing you need to change is the localhost address. Instead, type the IP address of the MongoDB hosting server and then click Connect. The compass should immediately connect to your server and present to you a list of databases hosted by MongoDB (Figure C)
Congratulations, you now have a great GUI that makes managing your remote MongoDB databases easy enough. Enjoy the ride.
Subscribe to TechRepublic How to do tech work on youtube From Jack Wallen to Business Professionals for all the latest technology advice.