# How do I update to node \>14.0.0?

**URL:** <https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385>\
**Category:** General\
**Created:** [29 September 2022 12:36 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385 "2022-09-29T12:36:44Z")\
**Posts on this page:** 20\
**Page:** 2

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [29 September 2022 15:50 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/21 "2022-09-29T15:50:07Z")

</div>

Drastic. But.  
If you remove existing nodejs first then run the script  
Eg. sudo apt purge nodejs npm  
Check that node -v doesn’t see it anymore  
Then use the script to reinstall

PS Julian if the pi is arm 7 based the the script does install the nodesource version of nodejs so apt will update it within minor version upgrades.

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [29 September 2022 15:59 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/22 "2022-09-29T15:59:48Z")

</div>

Followed your instructions to the letter. Although I asked for node14, it installed version16 - is that OK ??  
 ![update_v16](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/0/4062667a8cf3be68222f68d1ee85edbc3daad187.png)

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [29 September 2022 16:01 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/23 "2022-09-29T16:01:12Z")

</div>

As long as it works 😅

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [29 September 2022 16:04 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/24 "2022-09-29T16:04:39Z")

</div>

Well it doesn't. This all started as I was trying to update a node from the palette manager.  
This is what I get when I try to update BigTimer or in fact any other node.

2022-09-29T16:02:08.111Z Install : node-red-contrib-bigtimer 2.8.3

2022-09-29T16:02:08.048Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production --engine-strict node-red-contrib-bigtimer@2.8.3

2022-09-29T16:02:09.274Z [err] npm

2022-09-29T16:02:09.275Z [err] WARN

2022-09-29T16:02:09.275Z [err] config production Use `--omit=dev` instead.

2022-09-29T16:02:12.291Z [err] (node:12907) Warning: Setting the NODE\_TLS\_REJECT\_UNAUTHORIZED environment variable to '0' makes TLS connections and HTTPS requests insecure by disabling certificate verification.

2022-09-29T16:02:12.291Z [err] (Use `node --trace-warnings ...` to show where the warning was created)

2022-09-29T16:02:15.795Z [err] npm ERR!

2022-09-29T16:02:15.796Z [err] code ERESOLVE

2022-09-29T16:02:15.805Z [err] npm

2022-09-29T16:02:15.805Z [err] ERR! ERESOLVE could not resolve

2022-09-29T16:02:15.805Z [err] npm

2022-09-29T16:02:15.806Z [err]

2022-09-29T16:02:15.806Z [err] ERR!

2022-09-29T16:02:15.806Z [err] npm ERR!

2022-09-29T16:02:15.806Z [err] While resolving: node-red-contrib-ui-mp4frag@0.1.0-beta.3

2022-09-29T16:02:15.806Z [err] npm ERR! Found: node-red-dashboard@3.1.7

2022-09-29T16:02:15.806Z [err] npm

2022-09-29T16:02:15.807Z [err] ERR!

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [29 September 2022 16:08 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/25 "2022-09-29T16:08:31Z")

</div>

In the .node-red dir I would run npm cache clear —force then npm rebuild

---

<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:** [29 September 2022 19:29 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/26 "2022-09-29T19:29:51Z")

</div>

I have seen problems such as you are having caused by out of date packages, or problems with the pi repositories. I suggest running  
`sudo apt update`  
and see if there are any errors. If not then run  
`sudo apt full-upgrade`  
to make sure all your packages are up to date.

Also show us what this gives  
`apt policy nodejs`

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [29 September 2022 20:54 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/27 "2022-09-29T20:54:39Z")

</div>

> [@dceejay](#):
>
> PS Julian if the pi is arm 7 based the the script does install the nodesource version of nodejs so apt will update it within minor version upgrades.

I probably should remember that, I'm sure you've said it before 🙂 and I should have anticipated that you would do it the "right" way anyway! 🤣

> [@TotallyInformation](#):
>
> See if it throws up some additional versions

I don't think I saw an answer to that one? But perhaps things have moved on anyway.

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [29 September 2022 20:59 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/28 "2022-09-29T20:59:10Z")

</div>

> [@dynamicdave](#):
>
> Although I asked for node14, it installed version16 - is that OK

I have node v16 installed on my live home Debian server and it works absolutely fine. I also use v16 on my Windows dev PC. I note that you even have v16.17.1 which I think came out in the ~~last day or 2~~ last Friday.

---

<div class="post-metadata">

**Author:** ![gerry](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/gerry/32/21604_2.png) [@gerry](https://discourse.nodered.org/u/gerry)\
**Post date:** [29 September 2022 22:33 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/29 "2022-09-29T22:33:57Z")

</div>

## Not to hijack this thread but..... I have the same problem @dynamicdave has when I try to update any node in palette manager. Specifically trying to go from 3.17 to 3.2 on node-red-dashboard, but the same issue arises when I try to update any node from palette manager. The system errors, won't update. I keep my system, PI4 raspbian up to date with all updates and nothing seems to fix this error on my system either. [edit] One further note for @dynamicdave - I accidentally updated one system to node 18 (as far as I can remember) and a lot seemed to quit working in node red. Rolled back to ver 16.something and it seems everything worked fine again. So ver 16.X should be OK in my limited experience. [next edit]

2022-09-29T22:40:38.846Z Install : node-red-dashboard 3.2.0

2022-09-29T22:39:11.347Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production --engine-strict node-red-dashboard@3.2.0

2022-09-29T22:39:12.629Z [err] npm

2022-09-29T22:39:12.630Z [err]

2022-09-29T22:39:12.630Z [err] WARN config production Use `--omit=dev` instead.

2022-09-29T22:39:15.447Z [err] npm

2022-09-29T22:39:15.448Z [err] ERR! code ENOTEMPTY

2022-09-29T22:39:15.448Z [err] npm ERR!

2022-09-29T22:39:15.448Z [err] syscall rename

2022-09-29T22:39:15.448Z [err] npm

2022-09-29T22:39:15.448Z [err] ERR! path /home/pi/.node-red/node\_modules/node-red-node-email

2022-09-29T22:39:15.449Z [err] npm ERR!

2022-09-29T22:39:15.449Z [err] dest /home/pi/.node-red/node\_modules/.node-red-node-email-eJQ2YdZ0

2022-09-29T22:39:15.451Z [err] npm ERR! errno -39

2022-09-29T22:39:15.453Z [err] npm ERR!

2022-09-29T22:39:15.453Z [err] ENOTEMPTY: directory not empty, rename '/home/pi/.node-red/node\_modules/node-red-node-email' -\> '/home/pi/.node-red/node\_modules/.node-red-node-email-eJQ2YdZ0'

2022-09-29T22:39:15.456Z [err]

2022-09-29T22:39:15.457Z [err] npm

2022-09-29T22:39:15.457Z [err] ERR! A complete log of this run can be found in:

2022-09-29T22:39:15.457Z [err] npm ERR! /home/pi/.npm/\_logs/2022-09-29T22\_39\_12\_543Z-debug-0.log

2022-09-29T22:39:15.474Z rc=217

---

<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:** [30 September 2022 00:33 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/30 "2022-09-30T00:33:34Z")

</div>

There were a bunch of reports recently of ENOTEMPTY errors when trying to install node-red-node-email.  
For example [https://discourse.nodered.org/t/enotempty-when-installing-node-from-palette-since-nodered-3-0-directory-not-empty/65968](https://discourse.nodered.org/t/enotempty-when-installing-node-from-palette-since-nodered-3-0-directory-not-empty/65968)  
(And it happened to me yesterday too, deleting the named directory fixed it)

I don't think it's the same issue as DynamicDave's.

---

<div class="post-metadata">

**Author:** ![dynamicdave](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dynamicdave/32/96_2.png) [@dynamicdave](https://discourse.nodered.org/u/dynamicdave)\
**Post date:** [30 September 2022 08:04 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/31 "2022-09-30T08:04:14Z")

</div>

This is the result I get... Is it what you expected?

pi@dev-super-server:~/.node-red $ apt policy nodejs  
nodejs:  
Installed: 16.17.1-deb-1nodesource1  
Candidate: 16.17.1-deb-1nodesource1  
Version table:  
\*\*\* 16.17.1-deb-1nodesource1 500  
500 [Index of /node\_16.x/](https://deb.nodesource.com/node_16.x) buster/main armhf Packages  
100 /var/lib/dpkg/status  
10.24.0~dfsg-1~deb10u1 500  
500 [Index of /raspbian](http://raspbian.raspberrypi.org/raspbian) buster/main armhf Packages

---

<div class="post-metadata">

**Author:** ![TotallyInformation](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/totallyinformation/32/31_2.png) [@TotallyInformation](https://discourse.nodered.org/u/TotallyInformation)\
**Post date:** [30 September 2022 08:35 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/32 "2022-09-30T08:35:08Z")

</div>

Don't forget that you also need to do an `npm rebuild` on all installed node.js packages after a major upgrade. That forces any C++ libraries to be rebuilt which is sometimes needed.

---

<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:** [30 September 2022 08:39 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/33 "2022-09-30T08:39:11Z")

</div>

> [@dynamicdave](#):
>
> Is it what you expected?

Yes, that is as it should be.

---

<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:** [30 September 2022 09:43 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/34 "2022-09-30T09:43:30Z")

</div>

Did the update and full-upgrade run without errors?

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [30 September 2022 09:44 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/35 "2022-09-30T09:44:15Z")

</div>

(Sorry, but this is why I am still fence sitting on updating from 22.x)

---

<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:** [30 September 2022 09:56 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/36 "2022-09-30T09:56:32Z")

</div>

> [@Trying\_to\_learn](#):
>
> this is why I am still fence sitting on updating from 22.x

What has that got to do with this thread?

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [30 September 2022 09:58 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/37 "2022-09-30T09:58:02Z")

</div>

I would not like to start/try to update and have it _crash_ as what I understand happened in this case.

---

<div class="post-metadata">

**Author:** ![zenofmud](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/zenofmud/32/316_2.png) [@zenofmud](https://discourse.nodered.org/u/zenofmud)\
**Post date:** [30 September 2022 10:12 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/38 "2022-09-30T10:12:34Z")

</div>

I just did an install of node-red-contrib-bigtimer on a Pi4 NR v3.02, node.js v14.20.0 and it installed fine:

```auto
-----------------------------------------------------------
2022-09-30T08:31:21.075Z Install : node-red-contrib-bigtimer 2.8.3

2022-09-30T08:31:21.284Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production --engine-strict node-red-contrib-bigtimer@2.8.3
2022-09-30T08:31:27.511Z [out] + node-red-contrib-bigtimer@2.8.3
2022-09-30T08:31:27.511Z [out] added 2 packages from 2 contributors in 4.465s
2022-09-30T08:31:27.535Z rc=0

```

I then ran the bash script with --node16 and started NR. It shows I'm at node.js v16.17.1

```auto
**pi@argonpi** : **~ $** node-red
30 Sep 04:37:23 - [info]
Welcome to Node-RED
===================
30 Sep 04:37:23 - [info] Node-RED version: v3.0.2
30 Sep 04:37:23 - [info] Node.js version: v16.17.1
30 Sep 04:37:23 - [info] Linux 5.10.103-v7l+ arm LE
30 Sep 04:37:24 - [info] Loading palette nodes
30 Sep 04:37:26 - [info] Dashboard version 3.1.5 started at /ui
30 Sep 04:37:26 - [info] Settings file : /home/pi/.node-red/settings.js
30 Sep 04:37:27 - [info] Context store : 'default' [module=memory]
30 Sep 04:37:27 - [info] User directory : /home/pi/.node-red
30 Sep 04:37:27 - [info] Projects directory: /home/pi/.node-red/projects
30 Sep 04:37:27 - [info] Server now running at http://127.0.0.1:1880/
30 Sep 04:37:27 - [info] Active project : project-1
30 Sep 04:37:27 - [info] Flows file : /home/pi/.node-red/projects/project-1/flows.json
30 Sep 04:37:27 - [warn] Using unencrypted credentials
30 Sep 04:37:27 - [info] Starting flows
30 Sep 04:37:27 - [info] Started flows

```

So I used the palette manager to remove then install `node-red-contrib-bigtimer` and everything worked fine.

```auto
-----------------------------------------------------------
2022-09-30T08:37:59.419Z Remove : node-red-contrib-bigtimer

2022-09-30T08:37:59.598Z npm remove --no-audit --no-update-notifier --no-fund --save node-red-contrib-bigtimer
2022-09-30T08:38:01.995Z [out] 
2022-09-30T08:38:01.995Z [out] removed 2 packages in 1s
2022-09-30T08:38:02.011Z rc=0

-----------------------------------------------------------
2022-09-30T08:38:10.634Z Install : node-red-contrib-bigtimer 2.8.3

2022-09-30T08:38:10.750Z npm install --no-audit --no-update-notifier --no-fund --save --save-prefix=~ --production --engine-strict node-red-contrib-bigtimer@2.8.3
2022-09-30T08:38:11.944Z [err] npm
2022-09-30T08:38:11.945Z [err]  
2022-09-30T08:38:11.945Z [err] WARN config production Use `--omit=dev` instead.
2022-09-30T08:38:13.522Z [out] 
2022-09-30T08:38:13.522Z [out] added 2 packages in 2s
2022-09-30T08:38:13.536Z rc=0

```

I suspect Dave's issue has something to do with the clarify node

---

<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:** [30 September 2022 10:46 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/39 "2022-09-30T10:46:19Z")

</div>

> [@Trying\_to\_learn](#):
>
> have it _crash_ as what I understand happened in this case

I think you are mixing this up with a different thread.

---

<div class="post-metadata">

**Author:** ![alexander77](https://avatars.discourse-cdn.com/v4/letter/a/3ec8ea/32.png) [@alexander77](https://discourse.nodered.org/u/alexander77)\
**Post date:** [5 October 2022 03:59 UTC](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385/40 "2022-10-05T03:59:21Z")

</div>

The Raspberry-Pi Homepage, hosting the images, gives the following information:  
latest version of 32bit OS (Release Notes): 2022-09-22:

- NodeRED removed from Recommended Software and full image - should only be installed via apt  
The 64 bit version is also affected.

When i tried to install it via software tool, i found, that only the version 12 of nodejs is in the list. The usual script denies installing nodered since version12 is no longer supported.

What i found and it worked for me (64bit Version):  
sudo su  
curl -fsSL [https://deb.nodesource.com/setup\_18.x](https://deb.nodesource.com/setup_18.x) | bash -

Then, as user pi, sudo apt install nodejs  
After that i used the normal script bash \<(curl -sL ....  
Node-red version 3 is running, also the command sudo systemctl enable nodered.service works, after node-red was started for at least one time.

[Previous page](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385.md?page=1)

[Next page](https://discourse.nodered.org/t/how-do-i-update-to-node-14-0-0/68385.md?page=3)
