How Can We Help?
< All Topics

Using External Database

NirvaShare is bundled with in built Postgre database. In case if you wish to use an external database for better data management, you can do so by pointing to an existing external Postgre database by following the below steps. NirvaShare will automatically recreate the required schema with initial seed data. Make sure you use Postgre server version 13.2

  • Login to the server where NirvaShare is installed using SSH as root or a sudo user.
  • Create or edit if already exists, the file /var/nirvashare/config.properties
  • Add below database entries and make sure to specify correct hostname, db name, username and password.
  • Save the file
ns_db_jdbc_url=jdbc:postgresql://<db hostname>:5432/<db name>
ns_db_username=<db usrename>
ns_db_password=<db password>
Example
ns_db_jdbc_url=jdbc:postgresql://database-1.cfwgddssfdx.us-west-1.rds.amazonaws.com:5432/postgres
ns_db_username=postgres
ns_db_password=xxxxx

Restart services

After pointing to an external database, NirvaShare services have to be restarted. Use the below commands to stop both Admin Console and User Application.

docker restart nirvashare_admin
docker restart nirvashare_userapp

Stop Database service

Now that, NirvaShare is pointing to external database, the built-in database can be stopped using below command.

docker stop nirvashare_database
Previous Upgradation
Table of Contents