In this post i am going to show " How to install MongoDB 3.2.4 in CentOS/ RHEL 7.1"
- Download required rpm files from https://repo.mongodb.org/yum/redhat/
- Place those files in a particular folder (in my case RPMS in folder and repo data in folder)
- Start simple python server using below code
python
-m SimpleHTTPServer 8900
- To access above port, we need to turn-off firewall
- Access above files from http://hostname:8900/ in any web browser
- Create local repo for above files
Note: Create one directory called repos and move all the other repos to that directory exceprt mongorepo.repo
- After above step to recognize this custom repo, we need to clean and update the repolist
- Now we are ready to install the downloaded packages
- Changing mongoDB data directory
Note: Before changing the db path, we need to stop Mongos service
Find “dbpath (line 14)” and add
custome dbpath
Find Port 27017 (line: 28) and add
custome port
- After changing the db path or port address start the mongod service
- Now you can run mongo agent
Sign up here with your email
ConversionConversion EmoticonEmoticon