Error connecting to PostgreSQL/PostGIS: "No such database: postgres"

Error connecting to PostgreSQL/PostGIS: "No such database: postgres"

Anonymous
Not applicable
2,260 Views
1 Reply
Message 1 of 2

Error connecting to PostgreSQL/PostGIS: "No such database: postgres"

Anonymous
Not applicable

Hi there,


when I try to connect to a PostgreSQL/PostGIS-Server (PostgreSQl 9.4.8, PostGIS 2.3) the way described here in Autocad Map 3d 2017, I get an error message "No such database: postgres". It only works with a local dump of the server content to localhost. It seems that the problem comes due to credentials as the "postgres" database on the server has usage only granted to admin. I get the same error when I click on the postgres database in pgAdmin III. With a local dump of the data to localhost where I have full rights, there's no error in Autocad Map 3d and in pgAdmin and I can connect to all databases on localhost in Autocad.
Does Autocad Map 3d always have to look on postgres database initially to read metadata? In other software like QGIS or pgAdmin, I have no problems creating a server connection because you select the (administration) database in advance. As it's not possible to change anything on server side in my company, I'm looking for a workaround or another possibility to connect to PostGIS without reading "postgres" database.

Thanks a lot for any help or idea!

 

Best regards, Benjamin

0 Likes
2,261 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable

I can add some further Information after testing for a while: The problem comes from PgBouncer, a connection pooler in front of the PostgreSQL/PostGIS-Server. In my case, the pooler is configured to direct several database-connections to the actual databases on the server. Not so with postgres-database as its not used in daily business. As we are a bigger company with complex server infrastructure, its not really practicable to change PgBouncer settings. The problem stays the same as mentioned above, there should be an alternative way to connect to PostgreSQL databases without mandatory  connecting to "postgres" database initially.

0 Likes