In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-02-24 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Centos6.4 x64 simple installation of MongoDB
Download the MongoDB2.4.9 version
Download MongoDB
Wget http://fastdl.mongodb.org/linux/mongodb-linux-x86_64-2.4.9.tgz
Decompress MongoDB
Tar-zxvf mongodb-linux-x86_64-2.4.9.tgz-C / usr/src
Move the MongoDB directory
Mv / usr/src/mongodb-linux-x86_64-2.4.9 / usr/local/mongodb
II. Deploy MongoDB
Enter the MongoDB directory
Cd / usr/local/mongodb
Create a data directory and log directory
Mkdir-p / data/mongodb/db
Mkdir-p / data/mongodb/log
Vi / etc/profile
PATH=$PATH:/usr/local/mongodb/bin
Source / etc/profile
Start MongoDB in the background
Mongod-dbpath=/data/mongodb/db-logpath=/data/mongodb/log/mongodb.log-fork
About to fork child process, waiting untilserver is ready for connections.
Forked process: 6440
All output going to:/data/mongodb/log/mongodb.log
Child process started successfully, parentexiting
Set up the boot MongoDB
Echo "mongod-dbpath=/data/mongodb/db-logpath=/data/mongodb/log/mongodb.log-fork" > > / etc/rc.local
Check to see if it is running
Pgrep mongo-l
6440 mongod
Access to the database
Mongo
MongoDB shell version: 2.4.9
Connecting to: test
Welcome to the MongoDB shell.
For interactive help, type "help".
For more comprehensive documentation, see
Http://docs.mongodb.org/
Questions? Try the support group
Http://groups.google.com/group/mongodb-user
>
> show dbs
Local 0.078125GB
> exit
Bye
View Port
Netstat-nalupt | grep mongo
Tcp 0 0 0.0.0.0 28017 0.0.0. 0 LISTEN 6440/mongod
Tcp 0 0 0.0.0 0 27017 0.0.0 0 15 * LISTEN 6440/mongod
Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.
Views: 0
*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.