While we are trying to register the database on ArcGIS Server, we are facing the below issue. Meanwhile we are using Postgres as RDBMS.
ArcGIS Pro 2.8,
ArcGIS Enterprise 10.9
Have you tried to create a new connection on ArcGIS Pro before publishing the data?
Have you validated the connection on ArcGIS Server? Like Server Manager > Site > Data Store > Validate