# Warning "Encrypted credentials not found"

**URL:** <https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891>\
**Category:** General\
**Created:** [17 July 2023 17:05 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891 "2023-07-17T17:05:25Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [17 July 2023 17:05 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/1 "2023-07-17T17:05:25Z")

</div>

Hi all,

I successfully installed Node Red on a Windows VM and it works.  
Now I installed it on my Raspberry Pi and I always get the warning "Encrypted credentials not found" at startup and I cannot start any flows. I already tried to set/change the credentialsSecret, adminAuth and httpNodeAuth settings but that didn't change anything. Also also completely reinstalled the Raspberry OS and installed Node Red again. But nothing helps.  
Any ideas?  
Thank you

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [17 July 2023 19:30 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/2 "2023-07-17T19:30:29Z")

</div>

Can you stop and restart node red in a command window and post the full startup log here please. Copy/paste not screenshot please. You can stop it and restart using  
`node-red-stop`  
`node-red-start`

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [18 July 2023 04:07 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/3 "2023-07-18T04:07:19Z")

</div>

Here is the startup log:

```auto
admin@raspberrypi:~ $ node-red-pi
18 Jul 06:05:03 - [info] 

Welcome to Node-RED
===================

18 Jul 06:05:03 - [info] Node-RED version: v3.0.2
18 Jul 06:05:03 - [info] Node.js version: v16.20.1
18 Jul 06:05:03 - [info] Linux 6.1.21-v8+ arm LE
18 Jul 06:05:06 - [info] Loading palette nodes
18 Jul 06:05:11 - [info] Settings file : /home/admin/.node-red/settings.js
18 Jul 06:05:11 - [info] Context store : 'default' [module=memory]
18 Jul 06:05:11 - [info] User directory : /home/admin/.node-red
18 Jul 06:05:11 - [warn] Projects disabled : editorTheme.projects.enabled=false
18 Jul 06:05:11 - [info] Flows file : /home/admin/.node-red/flows.json
18 Jul 06:05:11 - [info] Creating new flow file
18 Jul 06:05:11 - [warn] Encrypted credentials not found
18 Jul 06:05:11 - [info] Server now running at http://127.0.0.1:1880/
18 Jul 06:05:11 - [info] Starting flows
18 Jul 06:05:11 - [info] Started flows

```

---

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [18 July 2023 07:23 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/4 "2023-07-18T07:23:55Z")

</div>

> I cannot start any flows.

Can you give some more detail?

That startup log says that Node-red has started, but there are no flows to deploy.

Are you trying to access the editor from a browser on your PC?  
The URL needs to be the IP address of the Pi, _not_ 127.0.0.1, and port 1880

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [18 July 2023 07:25 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/5 "2023-07-18T07:25:04Z")

</div>

> [@BitEater](#):
>
> I always get the warning "Encrypted credentials not found" at startup and I cannot start any flows

As you can see from the log the flows have been started. For some reason you have lost the credentials. That probably means that either the credentials secret in the pi is not the same as in the VM or you have not transferred the secrets file. To recover you can go to each of the nodes that have credentials in them and put them in again.  
If you want to work out why it does not work then tell us exactly how you transferred the setup from the VM to the Pi, and in particular tell us how you have setup the credential secret in the VM.

**[Edit]** Also note these lines in the log

> [@BitEater](#):
>
> ```auto
> 18 Jul 06:05:11 - [info] Flows file : /home/admin/.node-red/flows.json
> 18 Jul 06:05:11 - [info] Creating new flow file
> 
> ```

That means you have not copied the flows file across correctly. I suspect that you are not using the same version of node-red on the two systems. The default flows and credentials filename changed between versions at some point.

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [18 July 2023 08:50 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/6 "2023-07-18T08:50:28Z")

</div>

I only try to access from the Pi itself. I get the editor open but when I select "Restart Flows" I always get:

```auto
msg : string[31]
"Encrypted credentials not found"

```

in the debug window. I thought the flow does not work, but it does. Still I get this warning.

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [18 July 2023 08:52 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/7 "2023-07-18T08:52:44Z")

</div>

I did not try to transfer anything from my Windows PC. I do all on my Raspberry PI. And it seems to work (kind of) but I always get this warning. Also I get this warning in the debug window when restarting flows.

I just created a new flow and now the startup log looks like this:

```auto
Welcome to Node-RED
===================

18 Jul 10:49:40 - [info] Node-RED version: v3.0.2
18 Jul 10:49:40 - [info] Node.js version: v16.20.1
18 Jul 10:49:40 - [info] Linux 6.1.21-v8+ arm LE
18 Jul 10:49:41 - [info] Loading palette nodes
18 Jul 10:49:44 - [info] Settings file : /home/admin/.node-red/settings.js
18 Jul 10:49:44 - [info] Context store : 'default' [module=memory]
18 Jul 10:49:44 - [info] User directory : /home/admin/.node-red
18 Jul 10:49:44 - [warn] Projects disabled : editorTheme.projects.enabled=false
18 Jul 10:49:44 - [info] Flows file : /home/admin/.node-red/flows.json
18 Jul 10:49:44 - [warn] Encrypted credentials not found
18 Jul 10:49:44 - [info] Server now running at http://127.0.0.1:1880/
18 Jul 10:49:44 - [info] Starting flows
18 Jul 10:49:44 - [info] Started flows

```

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [18 July 2023 08:59 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/8 "2023-07-18T08:59:02Z")

</div>

Have you added credentials to any node & deployed?

Have you set the secret in your settings file?

Is something broke / not working or are you just curious about the message?

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [18 July 2023 17:00 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/9 "2023-07-18T17:00:35Z")

</div>

I added the credentialsSecret adminAuth and httpNodeAuth settings in the settings file.  
To be honest contrary to my assumption all seems to work. So I am just curious about this message since it disappeared on my Windows installation of Node Red after making the mentioned settings.

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [18 July 2023 17:26 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/10 "2023-07-18T17:26:08Z")

</div>

It disappeared because you actually created a credential that got written to disk (created the file).

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [18 July 2023 17:51 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/11 "2023-07-18T17:51:06Z")

</div>

That applies to the Windows VM installation but not to the Raspberry Pi. There is still have it and I don't know how to get rid of id.

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [19 July 2023 16:16 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/12 "2023-07-19T16:16:57Z")

</div>

Any further ideas?

---

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [19 July 2023 16:34 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/13 "2023-07-19T16:34:01Z")

</div>

> [@Steve-Mcl](#):
>
> Have you added credentials to any node & deployed?

For example add an mqtt node and enter an IP address for the broker (doesn't matter if it isn't running a broker) then deploy.

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [19 July 2023 16:40 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/14 "2023-07-19T16:40:53Z")

</div>

Deploying seems to work but with every restart of the flows I get the mentioned message in the debug window.

---

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [19 July 2023 16:47 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/15 "2023-07-19T16:47:47Z")

</div>

You aren't by any chance using the overlay filesystem?

When you deploy does it create a credential file?  
Is it still there when you reboot?

If you create a new flow and deploy, is that still there when you reboot?

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [19 July 2023 17:04 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/16 "2023-07-19T17:04:20Z")

</div>

I did not change configuration regarding filesystem. I am just using the original Raspberry Pi OS and installed Node Red.  
After reboot my flows are still there.  
I don't see a credentials file. Should it be located in ~/.node-red?  
While Node Red is running the folder contains these files:

```auto
admin@raspberrypi:~/.node-red $ ls -a
. .config.users.json.backup node_modules settings.js
.. flows.json package.json
.config.nodes.json .flows.json.backup package-lock.json
.config.users.json lib .sessions.json

```

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [19 July 2023 18:32 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/17 "2023-07-19T18:32:44Z")

</div>

Please answer definitively

Have you set any credential (any at all) and deployed on the problematic device?

After deploying a change with creds, you should see another file (named something ?creds?)

Then restart node-red - do you still see the warning?

Then restart the PI, does the file still exist?

---

<div class="post-metadata">

**Author:** ![jbudd](https://avatars.discourse-cdn.com/v4/letter/j/5f8ce5/32.png) [@jbudd](https://discourse.nodered.org/u/jbudd)\
**Post date:** [19 July 2023 18:37 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/18 "2023-07-19T18:37:52Z")

</div>

> [@BitEater](#):
>
> I don't see a credentials file. Should it be located in ~/.node-red?

If the flow file that Node-red is using is ~/.node-red/flows.json then the credentials file should be ~/.node-red/flows\_cred.json  
Can you please show us the output of these commands?

Edit: Added one more grep command.

```auto
whoami
grep WorkingDirectory /etc/systemd/system/multi-user.target.wants/nodered.service
grep User= /etc/systemd/system/multi-user.target.wants/nodered.service
find /home -name flows.json -ls
grep flowFile: /home/*/.node-red/settings.js
touch ~/.node-red/flows_cred.json

```

Now reboot, login and do  
`ls -l ~/.node-red/*.json`

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [19 July 2023 19:08 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/19 "2023-07-19T19:08:05Z")

</div>

In ~/.node-red/settings.js I have set the credentialSecret value.  
After deploying changes I don't see any file with "creds" in the name.

---

<div class="post-metadata">

**Author:** ![BitEater](https://avatars.discourse-cdn.com/v4/letter/b/dc4da7/32.png) [@BitEater](https://discourse.nodered.org/u/BitEater)\
**Post date:** [19 July 2023 19:10 UTC](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891/20 "2023-07-19T19:10:53Z")

</div>

```auto
admin@raspberrypi:~/.node-red $ whoami
admin
admin@raspberrypi:~/.node-red $ grep WorkingDirectory /etc/systemd/system/multi-user.target.wants/nodered.service
grep: /etc/systemd/system/multi-user.target.wants/nodered.service: No such file or directory
admin@raspberrypi:~/.node-red $ grep User= /etc/systemd/system/multi-user.target.wants/nodered.service
grep: /etc/systemd/system/multi-user.target.wants/nodered.service: No such file or directory
admin@raspberrypi:~/.node-red $ find /home -name flows.json -ls
   145741 4 -rw-r--r-- 1 admin admin 1144 Jul 19 21:06 /home/admin/.node-red/flows.json
admin@raspberrypi:~/.node-red $ grep flowFile: /home/*/.node-red/settings.js
    flowFile: "flows.json",
admin@raspberrypi:~/.node-red $ touch ~/.node-red/flows_cred.json

```

I will reply again for ls output after reboot

[Next page](https://discourse.nodered.org/t/warning-encrypted-credentials-not-found/79891.md?page=2)
