-p, --password PASSWORD
The encrypted password, as returned by crypt(3).
Note: This option is not recommended because the password (or encrypted password) will be visible by users listing the processes.
The password will be written in the local /etc/passwd or /etc/shadow file. This might differ from the password database configured
in your PAM configuration.
You should make sure the password respects the system's password policy.
which basically means that the
-p option needs a pre-encrypted password hash, not the actual value you're typing when logging in. This is a rarely-used option.
The recommended way to change your password from command line is to use
To fix things, now you need to boot into recovery mode, log in as root and change your password using