If you encounter some problems with your MongoDB server and trying to reinstall it or just want to uninstall it, the following will cover how to purge Mongo completely (including dependencies, configuration file, logs and database storage) on Debian/Ubuntu-based Linux distros (e.g. Linux Mint, Pop!_OS, Elementary OS).
MongoDB is one of the most popular NoSQL databases around. In this tutorial we'll be covering how to install the latest version of MongoDB Community Server from its official repository, and the following steps work for Ubuntu 20.04 LTS (Focal), 18.04 LTS (Bionic) and 16.04 LTS (Xenial).
TTL Indexes in MongoDB are very useful for storing data like logs or user sessions. The documents will remove itself after certain amount of time which specify by the index. This tutorial will be done in both JavaScript and TypeScript using Node.js with node-mongodb-native, which is the official MongoDB Node.js driver.