Hi
(Veeam version 12.2.0.334)
I want to move the PostGreSQL database from drive C to drive D.
Following my steps, the PostgreSQL service starts correctly. However, the Veeam service doesn't start.
I haven't found a clear procedure for this. Do you have any idea what's missing?
Here are the steps I followed:
I stopped all "Veeam" services and the "postgresql-x64-15" service.
I performed a robocopy.
From : C:\Program Files\PostgreSQL\15\data
Move to : D:\PostgreSQL\15\data
My script :
for /f "tokens=1-5 delims=:" %%d in ("%time%") do set tmptime2=%%dh%%e
set tmpTimeHeureMinute=%tmptime2: =0%
for /f "tokens=1-5 delims=/ " %%d in ("%date%") do set tmpDate=%%d-%%e-%%f
robocopy "C:\Program Files\PostgreSQL\15\data" "D:\PostgreSQL\15\data" /MIR /SEC /NP /ETA /LOG:C:\Robocopy\Log\MovePostGreSQL%tmpDate%-%tmpTimeHeureMinute%.log /R:1 /W:1
No errors, all files have been copied
I renamed the directory C:\Program Files\PostgreSQL\15\data to C:\Program Files\PostgreSQL\15\data-001
I changed the Windows service with this command:
sc config postgresql-x64-15 binPath= "\"C:\Program Files\PostgreSQL\15\bin\pg_ctl.exe\" runservice -N \"postgresql-x64-15\" -D \"D:\PostgreSQL\15\data\" -w"
I started the postgresql-x64-15 service: Success
I tried to manually start the "Veeam Backup Service" (VeeamBackupSvc): Failed
Reboot the server -> "Veeam Backup Service" (VeeamBackupSvc): Failed
Here is the error visible in the Windows Event Viewer (part of the error message was in French because my server is in Canadien French. So, I made a free translation!):
Veeam.Backup.DBCreator.DatabaseException: Failed to connect to PostgreSQL server localhost:5432. 42501: could not open the base file /5/1259 : Permission denied ---> Npgsql.PostgresException: 42501: could not open the base file /5/1259 : Permission denied
Original error :
Le service ne peut pas être démarré. Veeam.Backup.DBCreator.DatabaseException: Failed to connect to PostgreSQL server localhost:5432. 42501: n'a pas pu ouvrir le fichier base/5/1259 : Permission denied ---> Npgsql.PostgresException: 42501: n'a pas pu ouvrir le fichier base/5/1259 : Permission denied à Npgsql.Internal.NpgsqlConnector.<<ReadMessage>g__ReadMessageLong|223_0>d.MoveNext() --- Fin de la trace de la pile à partir de l'emplacement précédent au niveau duquel l'exception a été levée --- à System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() à System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) à Npgsql.Internal.NpgsqlConnector.<<Open>g__OpenCore|203_1>d.MoveNext() --- Fin de la trace de la pile à partir de l'emplacement précédent au niveau duquel l'exception a été levée --- à System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw() à System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) à Npgsql.Inte...
Do you have any suggestion?