I got locked out from my Cockpit and the login isn’t working.
Reseting through Username or Email doesn’t work either.
This is the error I’m receiving:
Invalid address: (From): root@localhost
I have access to the server. How to reset or recover the login data?
This means, that your mailer settings aren’t set. You have to add your SMTP credentials in your
config.yaml first. Than you are able to send recovery emails.
Example for mailer config: https://getcockpit.com/documentation/reference/configuration
If you use SQLite, the credentials are stored in
storage/data/cockpit.sqlite in the accounts table - but they are hashed.
If you have shell access to your server, you can create a new admin user via cli, login and change your password via ui.
# generate hash of SuperSecretPassword
php ./cp account/generate-password --passwd SuperSecretPassword
# create new user
php ./cp account/create --user tmpadmin --email firstname.lastname@example.org --passwd xxHashOfPasswordxx
Cli commands: https://github.com/agentejo/cockpit/tree/next/modules/Cockpit/cli/account