---
title: "How to solve Login issues caused by empty or NULL password in auth_users.yml?"
description: "Login issues in OP5 can occur due to empty or NULL passwords in the auth_users.yml file. The solution involves identifying users without passwords and resetting them using the op5-manage-users command."
url: "https://docs.itrsgroup.com/docs/faq/op5/360023976553-op5-monitor-how-to-solve-login-issues-caused-by-empty-or-null-password-in-auth-users-yml/index.html"
---
## The problem

If you get the following error message:

```
'NULL' is not valid for password 'password', in table: 'users'
```

This means there is a literal password value of NULL in `/etc/op5/auth_users.yml`.

## The Solution

### Step 1

From the Monitor shell, look for any users in `/etc/op5/auth_users.yml`that do not have a password entry (or simply run `grep -B 5 -i null /etc/op5/auth_users.yml`). In a valid entry, you will see both `password` and `password_algo` fields and values:

```
john:
  username: "john"
  password: "$1$7th39pXa$IV0PUeEJDY752corXIWGr."
  password_algo: "crypt"
  modules:
    - "Default"
  groups:
    - "admins"
  realname: "John Doe"
```

When you get a failing entry, you will not likely have a `password_algo` field and the password value will not be in double-quotes:

```
jane:
  username: "jane"
  password: null
  modules:
    - "Default"
  groups:
    - "admins"
  realname: "Jane Doe"
```

### Step 2

Copy each of the user entries that do not have passwords. You will need to re-enter this content when you add the password since any update via `op5-manage-users`will purge existing content. Please see <https://docs.itrsgroup.com/docs/faq/op5/360020252513-op5-monitor-how-to-reset-the-password-for-local-users/index.html> for details.

### Step 3

Use `/usr/bin/op5-manage-users` to set the password, and provide the original values along with the password. Based on the example above:

```
op5-manage-users --update --username=jane --password=PASSWORD--realname="Jane Doe" --group=admins
```


