Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Error 500 on creating any repository.

Patrick Wittke June 3, 2019

When I create a new repository it shows me error 500. 

The Bitbucket runs on the atlassian docker image and is a brand new setup with no customization other than the mysql-drivers. The project was also empty and has just been created.

 

Thanks for the help!

 

Patrick

2 answers

1 accepted

0 votes
Answer accepted
Stephen Sifers
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 5, 2019

Hello Patrick and welcome to the Community!

From the sound of the issue, unable to create a repo due to a 500 error being present, it sounds like Bitbucket is having an issue accessing the server itself. Could you ensure that the service account running Bitbucket is able to access your storage without error?

If this is not the case then we’ll need some outputs from your log files. We’ll need you to check your Bitbucket server logs for anything in regards to a “caused by” error. These errors will point us to what the problem may be. Here are resources to help you review the logs:

We look forward to hearing back to ensure you’re able to get Bitbucket up and running.
Regards,
Stephen Sifers

Patrick Wittke June 5, 2019

Hi Stephen,

thank you for the reply.
I run the docker container through plesk and mapped the home directory to /temp/var/....  I inserted both the jdbc 5 and 8 drivers on both I get the error 500 each time I recreated the container and deleted the database, so effectively it was a clean install every time. I updated my git from 2.17 to 2.21 and it still appears. As far as I could narrow it down it happens with MySQL and some data related to the repo can't be written/read in the database. I also did a rollback to the previous bitbucket version (6.3.0).

I enabled the debugging and profiling and accessed my repo again now in the support section I got one hit and it links to elasticsearch not being accessible. 

here is my docker overview with the message also

Opera Momentaufnahme_2019-06-06_084602_pwittke.de.png

https://confluence.atlassian.com/bitbucketserverkb/troubleshooting-connection-issues-for-elasticsearch-826900037.html?utm_medium=logScan&utm_source=STP

 

Thanks,

Patrick

Stephen Sifers
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 7, 2019

Hello Patrick,

Thank you for looking at and review the logs. While these errors are helpful for the elastic search, this won’t cause the 500 response you’re getting when creating a repo. If we did confirm permissions for the path are configured correctly then it would most likely be a database or connectivity issue that is causing your error. I would like to focus now on the MySQL configuration and JDBC file to ensure we’re correctly setup. Could you please review the Bitbucket MYSQL setup found at Connecting Bitbucket Server to MySQL and ensure the following is correct:

  • MySQL version supported under Supported platforms
  • The database was created with the correct collation and the character set.
  • The correct version of the JDBC is used.

Additionally, please check the log scanner and report any findings to us so we may see additional causes to the failure. Here is how to access and use the log scanner: Log Scanner and Scheduled Log Scanner.

We look forward to hearing back to help find the cause and resolve your issue when creating a repository.

Regards,
Stephen Sifers

Patrick Wittke June 10, 2019

Hello Stephen,

thank you for helping me. The JDBC i tried first was 8.0.16 as recommended from oracle. But this one was unable to connect to the Server. The current MySQL Version on that is running on Plesk is 5.7.26. It used to run standalone on that server before I upgraded from 16.04 to 18.04 and with the Upgrade I wanted to move it to Docker for easier upgrades. I also tried the JDBC Version 5.1.47

 

I also checked the database. Each time the repository was added to the table. But Accessing it is allways returning the error 500

image.png

 

The Logs only return as follows:

image.png

Best regards,

Patrick

Stephen Sifers
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
June 17, 2019

Hello Patrick,

Since we’ve confirmed the database is working properly and you see entries present this then leaves the directory as a candidate for the issue. I would like you to please change the directory from /temp/var to a more permanent directory (a dedicated one would work) for Bitbucket to use.

When you create/map a new directory please ensure the user has read/write permissions (if not the owner).

Additional resources to view would be as follows:

Please let us know if you’re able to test the above request and what the results are.

Regards,
Stephen Sifers

Patrick Wittke June 23, 2019

Dear @Stephen Sifers ,

thank you for the assistance. It was in fact the directory permissions. Even tho the ownership was correctly set up and also permissions were open on the directory... I moved it to the actual folder without the temp and it works flawlessly. 

Thank you!

Best,

Patrick

Like Stephen Sifers likes this
0 votes
Patrick Wittke June 12, 2019

OK I reinstalled another clean Bitbucket Docker Container 6.3.2 and also changed from MySQL 5.7 do MariaDB 10.3.15. Utilizing the JDBC (mysql-connector-java-8.0.16.jar). When I create a new Project and repo it still goes straight to the error 500 page. even tho it creates the repo in the database...


The error logs dont show anything :/

Best,

Patrick

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events