Install MongoDB on both 32-bit and 64-bit

As of 03/02 updated: version 4.2 replaced with 4.4

[64-bit Raspberry OS Buster]

We are going to use instruction for Ubuntu 64-bit:

curl -s | sudo apt-key add -
echo "deb [ arch=arm64 ] bionic/mongodb-org/4.4 multiverse" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list
sudo apt update

Now we can install MongoDB server:

sudo apt install mongodb-org

# enable and start
sudo systemctl enable mongod
sudo systemctl start mongod


MongoDB + Python

Depends on the version you are using:

python -m pip install pymongo
python3 -m pip install pymongo

In my case, because I’ve change the default version of Python,

python -m pip install pymongo

will be installed for python3