Lost hashed(?) MaraiDB/MySQL password after accedentally overwriting config.production.json file

Keywords: Ghost - AWS - Technical issue - Services (Apache, MariaDB, MySQL…)

bnsupport ID: 9dea4b05-1445-f458-25c0-06e0c471fdc9

bndiagnostic output:

? Apache: Found possible issues
? Mariadb: Found possible issues
? Resources: Found possible issues
? Processes: Found possible issues

bndiagnostic failure reason: The documentation did not make any significant change

I used the command to set the URL through the Ghost CLI and that ended up erasing all of the data from my config.production.json file. I was able to find the data from another instance of Ghost I have running, but the password for the bn_ghost user for MariaDB/MySQL is a long string that I can’t seem to find.

I was able to get into the MariaDB app and can see the password, but it’s formatted very differently that the password from the other instance. Moreover, it didn’t work when I updated the config doc with it.

Thank you!

Image one is the startup error
The second is the manually “recovered” config.production.json file, and the third is what I was able to lookup in MariaDB.

Hi @mdma,

Please create a new user and password in the database and grant it access to the Ghost’s database. Then use that user/password in the config file


Note: you do not need to create the database

Happy to help!

Was my answer helpful? Click on :heart:

Ok, so I followed those instructions, then restarted Ghost and Apache and ran the “ghost start” command. However, no when i type in the url: https://blog.md-ma.co, it redirects to what did I do wrong?

When I use the status command
sudo /opt/bitnami/ctlscript.sh status
I see the following:
Screen Shot 2021-12-13 at 11.38.53 AM
But when I run
sudo su ghost -c "ghost start"
It returns:

Ok, so I was able to get it working by changing the URL in the config file to http: rather than https:. I then re-ran the cert program to generate SSL and that completed successfully, so now the https: works when you type in the URL, but not when I update the URL to https in the config file.

The issue is that my subscribe buttons aren’t working now, and it says it’s because I need to update the URL to https which is the original issue that caused this problem.

How can I safely update the config file to https?

Hi @mdma,

Could you please ask the Ghost developers about the issues you are running into when updating the domain in the config file? If the application is not able to work properly when you set https, there should be something more to change in the app.


This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.