I\'ve already seen these answers, so please don\'t link em in solutions:
Installing MongoDB on Ubuntu 16.04 https://unix.stackexchange.com/questions/220
Download the MongoDB Community Server (.dbz) version
Extract it and move it to home directory
Edit the ~/.profile by running:
gedit ~/.profile
Then add this:
echo export PATH=mongodb-linux-x86_64-ubuntu1804-4.0.4/bin:$PATH
Save then update the system variables by running:
source ~/.profile
After that, start server by running:
mongod