STEP 1:-
Configure Package Management System (YUM)
Create a /etc/yum.repos.d/10gen.repo file
[ nitin@nitin-ubuntu: ~ ] $ sudo vim /etc/yum.repos.d/10gen.repo
name=10gen Repository
baseurl=http://downloads-distro.mongodb.org/repo/redhat/os/x86_64
gpgcheck=0
enabled=1
[ nitin@nitin-ubuntu: ~ ] $ yum clean all
[ nitin@nitin-ubuntu: ~ ] $ sudo yum install mongo-10gen mongo-10gen-server
STEP 2:-
Configure MongoDB
These packages configure MongoDB using the /etc/mongod.conf file in conjunction with the control script. You can find the init script at/etc/rc.d/init.d/mongod.
This MongoDB instance will store its data files in the /var/lib/mongo and its log files in /var/log/mongo, and run using the mongod user account.
STEP 3:-
Start MongoDB
[ nitin@nitin-ubuntu: ~ ] $ sudo service mongod start
STEP 4:-
[ nitin@nitin-ubuntu: ~ ] $ sudo service mongod stop
It'sVery informative blog and useful article thank you for sharing with us , keep posting learn more
ReplyDeleteAWS Online Training Hyderabad