
You can follow the steps mentioned there and install the software. You can find the downloaded file in the downloads directory. Ensure that the platform is Windows, and the package is MSI. At the time of writing, the latest version is 4.4.5. Make sure that the specifications to the right of the screen are correct. Under the Software section, click on the Community server version. Run the beneath commands one after the another from the console to remove MongoDB completely.Cross-check the Specifications and Download MongoDB Type the command ‘ mongo’ from the terminal to connect MongoDB $ mongoĪfter connecting to the Mongo shell, we will get following,Ībove confirms that mongodb installation is completed as we are able to connect mongo shell. $ sudo firewall-cmd -reload 4) Connect to MongoDB from Terminal $ sudo firewall-cmd -zone=public -add-port=27017/tcp -permanent In case OS firewall is enabled and running then open the MongoDB port ‘ 27017‘ using below firewalld-cmd command. Run the beneath commands to start and enable the mongodb service across reboot.

$ sudo sed -i s/^SELINUX=.*$/SELINUX=permissive/ /etc/selinux/config Run beneath command to set selinux as permissive. Note: During the demonstration, I have kept the SELinux status as permissive. /var/log/mongodb/mongod.log - Log file of MongoDB./var/lib/mongo - Data directory of MongoDB./etc/nf - Configuration file of MongoDB.

$ sudo yum install -y mongodb-orgĪbove command will install the followings MongoDB Packagesįollowing files and directory will be created once the MongoDB packages are installed. To install MongoDB and its dependent packages use the below dnf command. 2) Install MongoDB package with dnf / yum command $ sudo vi /etc//mongodb-org-4.repoīaseurl=$releasever/mongodb-org/4.4/x86_64/ So, to install mongodb with yum or dnf command, create the following repository file with beneath contents. MongoDB package and its dependencies are not available in RHEL 8 and CentOS 8 package repositories.
