# Best practice and recommendations

**URL:** <https://discourse.nodered.org/t/best-practice-and-recommendations/79932>\
**Category:** General\
**Created:** [19 July 2023 11:20 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932 "2023-07-19T11:20:23Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![SvenT](https://avatars.discourse-cdn.com/v4/letter/s/7bcc69/32.png) [@SvenT](https://discourse.nodered.org/u/SvenT)\
**Post date:** [19 July 2023 11:20 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/1 "2023-07-19T11:20:23Z")

</div>

Hey there,  
I am a complete newbie in Node Red so sorry for the very basic questions.

I have some devices that I want to handle with NR:

- a smart home system based on the homematic controller based on a a raspi (Raspberrymatic)
- a management system for solar power based on Venus OS from Victron (on a second Raspi)
- a Siemens Logo! SPS
- some Shelly devices

In the future I also want to combine all this with iobroker.

And now the first and initial question is:  
Where to install the NodeRed?  
I am a complete Linux newbie so Windows would be cool.

Is it feasible to install NR on a windows 10/11 VM on a QNAP NAS?

This has - in my eyes - the following advantages

- installed on a system that rins 24/7
- independent from all the devices that it shall handle
- easier to keep the NR most recent

Or woudld it be better to install it on a debian based Linux VM on the QNAP NAS?

Thanks for any hint  
Sven

---

<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 11:48 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/2 "2023-07-19T11:48:18Z")

</div>

> [@SvenT](#):
>
> Is it feasible to install NR on a windows 10/11 VM on a QNAP NAS?

Yes, but that is (IMO) overkill and posses difficulties (like which user runs Node-RED, how to setup a service, unnecessarily running a FULL OS + GUI etc) not to mention all the setup to get NodeJS installed, Node-RED installed etc.

> [@SvenT](#):
>
> Or woudld it be better to install it on a debian based Linux VM on the QNAP NAS?

Better, but not the best. You are still running a full(er) OS than a container would and you still need to manage OS updates etc.

Since you can run containers on QNAP NAS, installing Node-RED as a docker image would be far less power hungry and even easier to maintain than having to upgrade OS packages, security patches etc etc.

Here is an older video - but the process has not changed much: [https://www.youtube.com/watch?v=CSVWX4ccZ-s](https://www.youtube.com/watch?v=CSVWX4ccZ-s)

---

<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:** [19 July 2023 20:06 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/3 "2023-07-19T20:06:30Z")

</div>

> [@SvenT](#):
>
> Is it feasible to install NR on a windows 10/11 VM on a QNAP NAS?

Urk! Maybe feasible if your QNAP has loads of memory. But, as Steve says, not the optimal approach.

If you are already using Docker, that would be a more sensible and less resource hungry approach. Oops, I now see Steve already said that. I'm not a great Docker fan but this is certainly a valid use-case if ever there was one.

---

<div class="post-metadata">

**Author:** ![SvenT](https://avatars.discourse-cdn.com/v4/letter/s/7bcc69/32.png) [@SvenT](https://discourse.nodered.org/u/SvenT)\
**Post date:** [20 July 2023 07:46 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/4 "2023-07-20T07:46:34Z")

</div>

Hey guys,  
thanks for the hints.  
Okay so VMs (either Win or Linux are overkill - understood.

So I will go for Docker.  
Do I undertsand it right, that If I use a data folder that resides outside the container I can destroy and use a newer build (so update Node Red) without loosing any data ?

Regards  
Sven

---

<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:** [20 July 2023 08:00 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/5 "2023-07-20T08:00:43Z")

</div>

> [@SvenT](#):
>
> If I use a data folder that resides outside the container I can destroy and use a newer build (so update Node Red) without loosing any data ?

Yes, but you should have a backup of your flows too. Backup everything in the flows folder except the node\_modules folder.

---

<div class="post-metadata">

**Author:** ![SvenT](https://avatars.discourse-cdn.com/v4/letter/s/7bcc69/32.png) [@SvenT](https://discourse.nodered.org/u/SvenT)\
**Post date:** [20 July 2023 08:19 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/6 "2023-07-20T08:19:44Z")

</div>

Hey Colin,  
thanks for that hint.

As I am a complete newbie sorry for the question: where can I find this folder?  
I will install a testsystem this weekend and I can also do a search on my own to find the files....

S.

---

<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:** [20 July 2023 08:39 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/7 "2023-07-20T08:39:57Z")

</div>

> [@SvenT](#):
>
> where can I find this folder

It is the one you are mapping outside the container. It should contain your flows file, settings.js etc. In a normal install it is usually ~/.node-red, but I don't know about Docker. I presumed it was the data folder you mentioned. I was just pointing out that you should not rely on just mapping it out to the file system, you should also back it up (as should non-docker systems) in case of disc failure, or user error, for example.

---

<div class="post-metadata">

**Author:** ![SvenT](https://avatars.discourse-cdn.com/v4/letter/s/7bcc69/32.png) [@SvenT](https://discourse.nodered.org/u/SvenT)\
**Post date:** [20 July 2023 09:18 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/8 "2023-07-20T09:18:29Z")

</div>

Okay I will check where the files willl be stored.  
And as the docker container will run on a QNAP NAS I will backup the data regularily as I do with all my data.

Is it as it is always with backups:  
If you do backups, you never need them and yo always think "well the backups need a lot of space on the disks" but if you decide to stop data backup a week later the disaster happens 😉  
Happened to a friend 2 weeks ago and I was that sort of friend that told him "no backup no pity" 😉

S.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [18 September 2023 09:18 UTC](https://discourse.nodered.org/t/best-practice-and-recommendations/79932/9 "2023-09-18T09:18:32Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
