Start MongoDB
- <mongo-install>/bin/mongod --dbpath <mongo-dbpath>
This starts a MongoDB server using default port 27017.
- For Mac, increase ulimit with start arg ‘ulimit -n 2048’
If MongoDB is started after AEM, restart all AEM instances so they properly connect to MongoDB.
Demo Production Option: Setup MongoDB Replica Set
The following commands are an example of setting up a replica set with 3 nodes on localhost:
-
bin/mongod --port 27017 --dbpath data --replSet rs0&
-
bin/mongo
cfg = {"_id": "rs0","version": 1,"members": [{"_id": 0,"host": "127.0.0.1:27017"}]}
rs.initiate(cfg)
-
bin/mongod --port 27018 --dbpath data1 --replSet rs0&
-
bin/mongod --port 27019 --dbpath data2 --replSet rs0&
-
bin/mongo
rs.add("127.0.0.1:27018")
rs.add("127.0.0.1:27019")
rs.status()
Solr
Install Solr
-
Download Solr from Apache Lucene:
- Suitable for any OS.
- Solr version 7.0.
- Solr requires Java™ 1.7 or greater.
-
Basic configuration
- Follow ‘example’ Solr setup.
- No service is needed.
- The installed Solr folder is called <solr-install>.