This article provides a solution for resolving the vPostgres service failed to start issue in vCenter Server Appliance (vCSA) 7.0 and later when incorrect file permissions are applied to PostgreSQL configuration files.
1 On a vCenter Server Appliance (vCSA) 7.0 environment, the vmware-vpostgres service fails to start.
2 Reviewing /var/log/vmware/vmon/vmon.log shows error similar to below which contains "Permission denied: '/storage/db/vpostgres/postgresql.conf'":
3 Checking /storage/db/vpostgres/postgresql.conf file permission and found it was owned by root user:
vCenter Server 7
vCenter Server 8
The file postgresql.conf was manually modified or its ownership was incorrectly changed to root:root.
The vmware-vpostgres service requires the configuration file to be owned by the vpostgres user and users group.
Incorrect ownership prevents the service from reading the file, causing startup failure.
1. Log in to the vCSA via VM Console or SSH as root.
2. Navigate to the PostgreSQL configuration directory:
#
cd /storage/db/vpostgres
3. Verify the file ownership by typing:
#ls -l postgresql.conf
If ownership shows root:root, it needs to be corrected.
4. Correct the ownership back to the default user and group by:
#chown vpostgres:users postgresql.conf
5. Confirm the ownership:
#ls -l postgresql.conf
Expected output:
6. Start the vPostgres service again:
#service-control --start vpostgres
Verify service status again by "#
service-control --status vpostgres".
The service should now show Running.