This page was last edited on August 23, 2019, at 15:29.
Comments or questions about this documentation? Contact us for support!
This topic provides recommendations for keeping your MongoDB database up-to-date and working correctly. It includes sections covering the following:
MongoDB data can grow quite large depending on the size of your environment and how you configure Predictive Routing. By default, the docker-compose.yml file (which you obtain from Docker.com) specifies /datadir/ as the MongoDB storage location. If you expect to write a lot of data on the MongoDB server, Genesys recommends that you create a separate mount point for that purpose.
The instructions below assume you are using Logical Volume Manager (LVM) to handle your disks. This example shows how to create a 20G logical volume for your data:
sudo lvcreate -L 20G -n mongoVolume LVMVolGroup
mkfs.ext4 /dev/LVMVolGroup/mongoVolume
mkdir /new-datadir
mount /dev/LVMVolGroup/projects /new-datadir
volumes:
- /datadir:/data/db
with
volumes:
- /new-datadir:/data/db
cd ./scripts/
bash stop.sh
mv /datadir/* /new-datadir/
bash start.sh
This section supplies the commands needed to back up and restore MongoDB in a single-site/single-server AICS deployment. For backup and restore instructions for HA environments, see Backing Up Your Data in the Deploying: High Availability topic.
The procedure below is for MongoDB with SSL enabled. Genesys recommends that you use SSL.
Use the following procedure to back up MongoDB in a single-server (single node) environment:
docker exec -it mongo bash
mongodump --ssl --out /data/db/backup --host localhost:27017
Use the following procedure to restore MongoDB on single node installation:
cd "IP_JOP_PRR_<version_number>_ENU_linux/scripts/"
bash stop.sh
../docker-compose -f "docker-compose.yml" up -d mongo
docker exec -it mongo bash
mongo solariat_bottle --ssl --eval "db.dropDatabase()"
mongorestore --ssl --drop /data/db/backup --host localhost:27017
exit
bash install.sh
and then:
bash start.sh