Centos7.6 安装mongodb
cd ~
wget https://fastdl.mongodb.org/linux/mongodb-linux-x86_64-4.0.0.tgz
tar -zxvf ./mongodb-linux-x86_64-4.0.0.tgz
cd mongodb-linux-x86_64-4.0.0/bin/
ls
cd /opt/
mkdir db
cd db
mkdir data
cd ~/mongodb-linux-x86_64-4.0.0/bin/
./mongod --dbpath /opt/db/data/ --bind_ip 0.0.0.0 --fork --logpath /opt/db/log.log