حلّ المجتمع

How to Reset a Forgotten CasaOS Username and Password

A 2023 CasaOS tutorial from BigBearTechWorld shows how to reset forgotten CasaOS login credentials. The source post is primarily a video tutorial, so the original YouTube walkthrough is embedded in this page.

If you are still logged in to CasaOS and simply want to change your password, use the account settings in the WebUI. If you are locked out because you forgot the CasaOS username or password, the community tutorial behind this page uses a separate recovery script to reset the CasaOS user database and return you to the setup/login flow.

The original September 2023 IceWhale Community post is primarily a video tutorial by BigBearTechWorld. The video is preserved below rather than replacing it with a text-only summary.

Original Community Video: Reset CasaOS Username and Password

The video covers the recovery script, running it on the CasaOS host, and returning to the CasaOS welcome screen so credentials can be configured again.

If You Can Still Log In: Change the Password in CasaOS

A later CasaOS GitHub discussion answered the simpler case: when the account is still accessible, open the CasaOS WebUI, choose Account from the top-left menu, and use the edit/pencil control next to the password field.

This is preferable to a reset script when you still know the current account and can enter the dashboard normally.

If You Are Locked Out: Use the BigBear Recovery Script

The BigBearTechWorld repository currently includes a dedicated reset-password-for-casaos script, and the same script was linked in a CasaOS GitHub discussion as the solution for a forgotten login.

The command shared there is:

bash -c "$(wget -qLO - https://raw.githubusercontent.com/bigbeartechworld/big-bear-scripts/master/reset-password-for-casaos/run.sh)"

Important: this command downloads remote code and executes it immediately with Bash. Before running a remote script on a server that contains important data, open the source and review it first. The current script repository is available here:

BigBearTechWorld scripts repository.

What the Recovery Does

The goal of this workflow is to reset the CasaOS WebUI account state so that the welcome/setup screen appears again. It is not the same as changing the Linux root password, an SSH password, or credentials used by applications installed inside CasaOS.

After the CasaOS user state is reset and the user service restarts, open the CasaOS WebUI and create the intended username and password again.

CasaOS WebUI Credentials Are Not Your Linux SSH Credentials

CasaOS account credentials belong to the CasaOS dashboard. A Linux account used for SSH is a separate authentication layer. Resetting the CasaOS WebUI username/password does not automatically reset:

  • the Ubuntu/Debian Linux user password;
  • the root password;
  • SSH keys;
  • passwords inside Docker applications such as qBittorrent, Jellyfin, or Nextcloud.

Manual Database Rename Is Another Recovery Pattern

Later CasaOS users have also recovered the WebUI by backing up the CasaOS user database and restarting the CasaOS user service:

sudo mv /var/lib/casaos/db/user.db /var/lib/casaos/db/user.db.backup
sudo systemctl restart casaos-user-service.service

This is a more explicit manual operation and changes CasaOS authentication state. Keep the backup file until you have confirmed the new CasaOS login works. Do not delete unrelated databases in /var/lib/casaos.

Before Resetting the Account

  1. Confirm you are resetting the CasaOS dashboard account, not an SSH or app password.
  2. If you can still log in, change the password from Account settings instead.
  3. If you are locked out, make sure you still have terminal/SSH access to the Linux host.
  4. Back up the CasaOS user database before manual database changes.
  5. Review remote scripts before executing them.
  6. After recovery, create a strong new password and store it in a password manager.

CasaOS Login Reset FAQ

Does this reset my Linux password?

No. The CasaOS WebUI account and the underlying Linux/SSH account are separate.

Can I change my CasaOS password without resetting anything?

Yes, if you can still log in. Use the CasaOS Account settings and edit the password there.

Why is the original YouTube video embedded here?

The source community post is fundamentally a video tutorial, so the original BigBearTechWorld walkthrough is retained as part of the migrated page.

Is running the remote script risk-free?

No remote shell script should be treated as risk-free. Review the current source before executing it and keep backups of important server configuration.