Issue for bitbucket to connect an external postgres database

I want to connect in a external postgresql database and i have this message. 

 

 

 

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:159)
	...
Could not get JDBC Connection; nested exception is org.postgresql.util.PSQLException: Connection attempt timed out.
	org.springframework.jdbc.datasource.DataSourceUtils.getConnection(DataSourceUtils.java:80)
	com.atlassian.stash.internal.db.DefaultDatabaseValidator.validate(DefaultDatabaseValidator.java:44)
	com.atlassian.stash.internal.db.DefaultDatabaseManager.validateConfiguration(DefaultDatabaseManager.java:214)
	...
Connection attempt timed out.
	org.postgresql.Driver$ConnectThread.getResult(Driver.java:368)
	org.postgresql.Driver.connect(Driver.java:279)
	java.sql.DriverManager.getConnection(DriverManager.java:664)
	...

 

Thank you!!

2 answers

1 accepted

2 votes

It looks like the server where you have installed Bitbucket Server is unable to reach the external DB. I would start by checking the network and firewall settings.

Hello  Jobin, 

Good answer!!!

 

 

Actuely, i want to clone projet in stash to bibucket server  and i have this error. 

 

 

Best regards;

bitbuck.PNG

Sorry, can you translate that to English for me?

Import failed
This deposit was not imported. Ask your administrators to check the log files for more details bitbucket

Not sure what the issue is. You can check the logs, as mentioned in the error, and hopefully that will give you more details on why this is happening.

Suggest an answer

Log in or Sign up to answer
Atlassian Community Anniversary

Happy Anniversary, Atlassian Community!

This community is celebrating its one-year anniversary and Atlassian co-founder Mike Cannon-Brookes has all the feels.

Read more
Community showcase
Piotr Plewa
Published Dec 27, 2017 in Bitbucket

Recipe: Deploying AWS Lambda functions with Bitbucket Pipelines

Bitbucket Pipelines helps me manage and automate a number of serverless deployments to AWS Lambda and this is how I do it. I'm building Node.js Lambda functions using node-lambda&nbsp...

1,767 views 1 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you