添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
相关文章推荐
打酱油的稀饭  ·  ConvertFrom-Json ...·  4 月前    · 
俊秀的瀑布  ·  urequests — ...·  6 月前    · 
坏坏的牛排  ·  Speech by Chairman ...·  9 月前    · 
Create

Hi,

I am trying to setup Bitbucket with PostGres.

Unfortunately, I have a connection error at the beginning

"""

The configuration entered is not valid. A database connection could not be established. Please check your configuration and try again.
	com.atlassian.stash.internal.db.DefaultDatabaseManager.validateConfiguration(DefaultDatabaseManager.java:217)
	com.atlassian.stash.internal.db.DefaultDatabaseManager.prepareDatabase(DefaultDatabaseManager.java:183)
	com.atlassian.stash.internal.maintenance.SpringMaintenanceTaskFactory.setupTask(SpringMaintenanceTaskFactory.java:151)
Failed to obtain JDBC Connection; nested exception is org.postgresql.util.PSQLException: Connection to 192.168.1.29:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
	org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:82)
	com.atlassian.stash.internal.db.DefaultDatabaseValidator.validate(DefaultDatabaseValidator.java:43)
	com.atlassian.stash.internal.db.DefaultDatabaseManager.validateConfiguration(DefaultDatabaseManager.java:214)
Connection to 192.168.1.29:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.
	org.postgresql.Driver$ConnectThread.getResult(Driver.java:405)
	org.postgresql.Driver.connect(Driver.java:263)
	java.sql.DriverManager.getConnection(DriverManager.java:664)
"""

I am installing Bitbucket Server (7.3) (via Docker) under MacOs.
I have followed the step for PostGres installation. PostGres is fine (I can manage it with pgAdmin)
I am new to PostGres and Docker.
Thanks for your help

Hi @MARTIN Régis ,

the error is because of connectivity issues to your database :

Connection to 192.168.1.29:5432 refused. Check that the hostname and port are correct and that the postmaster is accepting TCP/IP connections.

There is probably a setting to change in pg_hba.conf as explained here in the paragraph Create the Bitbucket Server database : https://confluence.atlassian.com/bitbucketserver/connecting-bitbucket-server-to-postgresql-776640389.html

This specific KB explains what to do : https://confluence.atlassian.com/bitbucketserverkb/bitbucket-is-unable-to-connect-to-postgresql-due-to-unconfigured-pg_hba-conf-file-969533185.html

Let me know if this helps,

--Alexis