Created
January 27, 2022 03:41
-
-
Save macroramesh6/c35897d8722c8ea874ec986419b16eb8 to your computer and use it in GitHub Desktop.
AG Batch.bat
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
:: copy pg_hba.conf to the E:/postgres location | |
:: this is to allow the postgres user to connect to the database | |
@echo off | |
:: XCOPY Docs https://docs.microsoft.com/en-us/windows-server/administration/windows-commands/xcopy#syntax | |
XCOPY /F /Y /D "C:\Program Files\PostgreSQL\9.3\pg_hba.conf" "E:\postgres\pg_hba.conf" | |
:: Restart PostgresSQL server | |
@REM pg_ctl restart | |
@REM call | |
::net stop postgresql | |
::net start postgresql | |
:: run this on every hour |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment