Postgre. How to install someones db

Simple swap of the data folders on turned off services of postgres

if you have someones db files like this

go to registry and find there smth with postgres words


you can open registry and find where your server on disk, in my case it is here

C:\Program Files (x86)\PostgreSQL\10\bin\

for that, look carefully at ImagePath

"C:\Program Files (x86)\PostgreSQL\10\bin\pg_ctl.exe" runservice -N "postgresql-10" -D "C:\Program Files (x86)\PostgreSQL\10\data" -w

Now, you have to stop corresponding service or services in windows services

Now, swap data folders and start service! You will find your data at this computer.

Building new postgres service from the scratch !

Use this file to add a new record in your registry

edit ImagePath and put in the corresponding windows folders your data

now try restart and start your new service

if all correct you should find your data on new service !

Good luck, anyway !!!

This entry was posted in Без рубрики. Bookmark the permalink.