The following guide provides a step-by-step on how to configure automatic backup in KenyaEMR;
Obtain the correct openmrs backup tool folder then open terminal and type the following;
- sudo cp -R openmrs-backup-tools/ /usr/share/
- cd /usr/share press enter
- sudo chown -R faciltyxx:facilityxx openmrs-backup-tools
- sudo chmod -R 755 openmrs-backup-tools
- sudo mkdir /var/backups/KenyaEMR/
- sudo chown -R facilityxx:facilityxx /var/backups/KenyaEMR/
Create a cron job to run the backup script on a daily basis by running crontab -e and select option 2. /bin/nano [ENTER]
- Add the line 00 11,16 * * * /usr/share/openmrs-backup-tools/openmrs_backup.sh
Then press Ctrl+x and press y and enter to save - Confirm by typing cd /usr/share/openmrs-backup-tools [ENTER]
Then type ./openmrs_backup.sh and press enter.
Comments are closed