# Weird Httpstatic configuration in Setting.js in NR windows 11

**URL:** <https://discourse.nodered.org/t/weird-httpstatic-configuration-in-setting-js-in-nr-windows-11/69765>\
**Category:** General\
**Tags:** node-red-dashboard\
**Created:** [29 October 2022 10:12 UTC](https://discourse.nodered.org/t/weird-httpstatic-configuration-in-setting-js-in-nr-windows-11/69765 "2022-10-29T10:12:08Z")\
**Posts on this page:** 1\
**Showing post:** 34

<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:** [31 October 2022 12:58 UTC](https://discourse.nodered.org/t/weird-httpstatic-configuration-in-setting-js-in-nr-windows-11/69765/34 "2022-10-31T12:58:32Z")

</div>

> [@Robertotarga](#):
>
> If I am allowed to give an advice I will somehow emphasize on the official docs that NR in a windows machine should be operated from the terminal with its command "node-red" and not as a service created by NSSM unless you are a windows naughty programmer and can tweak it to behave like NR opened by the current user. Hopefully this hard learnt lesson will be useful to other NR users on windows machines!

I personally believe that is out of scope - NSSM is perfectly viable (in the right hands).

You issue was being unaware that NSSM chose by default to run under the `system` account. It does this for very good reason.

Like any user, the `system` account has a "home" directory.  
The reason you dont find any flow files using a regular search (from your own user account) is because the `system` users files are protected from other users (again - for good reason)

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/a/aa173a23bbf248083b1f79881e5a189eace66a2a.png)

If you want to find your old flows etc, you should have enabled the logging in NSSM...

> [@Steve-Mcl](#):
>
> Edit the nssm setup & get it to write stdout and stderr logs to files so that you can read the start up log - that will tell you everything you need to know

... then you would have seen something like ...

```auto
30 Oct 15:49:29 - [info] Flows file : C:\WINDOWS\ServiceProfiles\LocalService\blah\blah\flows.json

```

Or a quick search on the internet for [Where can I find system data stored by a Windows Service](https://www.google.com/search?q=Where+can+I+find+system+data+stored+by+a+Windows+Service) would have revealed the location `%systemroot%\ServiceProfiles`

The point is, you seem like (no offence) a "regular" user (not a power user / windows expert) and the NR docs are not really a place to teach or preach - it is not an easy balance.

**However, we would definitely consider a PR to the docs around this area.**

* * *

#### Moving forward...

My recommendation would be...

1. move your node-red userDir to `c:\something`
  - make sure the service account AND your user account have read-write access

2. set NSSM to run `node-red -p 1880 -u c:/something`
3. set the NSSM "log" tab up to output STDOUT and STDERR to write to log files in `c:/something` and enable log rotation
4. Enable NSSM

_NOTE: `c:\something` should really be something like `c:\node-red-1880` - the above was for illustration purposes_

#### Here are a few of threads that should help...

> [@Node red multiple instances](https://discourse.nodered.org/t/node-red-multiple-instances/9787/7):
>
> assuming windows (you didnt specify)... Create 4 folders... c:\node-red-1880 c:\node-red-1881 c:\node-red-1882 c:\node-red-1883 (avoid 1883) c:\node-red-1884 open 4 cmd windows Start \>\> Run \>\> cmd \>\> {enter} Start \>\> Run \>\> cmd \>\> {enter} Start \>\> Run \>\> cmd \>\> {enter} Start \>\> Run \>\> cmd \>\> {enter} In cmd1... node-red -p 1880 -u c:/node-red-1880 In cmd2... node-red -p 1881 -u c:/node-red-1881 In cmd3... node-red -p 1882 -u c:/node-red-1882 In cmd4... node-red -p 1884 -u c:/no…

> [@Running Multiple Instances of Node-red using NSSM](https://discourse.nodered.org/t/running-multiple-instances-of-node-red-using-nssm/57127/2):
>
> Assuming you setup your folders like described in that thread (a few posts above the one you linked to) ([this post](https://discourse.nodered.org/t/node-red-multiple-instances/9787/7)) then you would set your NSSM commands to run each instance in the same way as if you were running it from a cmd window example... NSSM1: node-red -p 1880 -u c:/node-red-1880 NSSM2: node-red -p 1881 -u c:/node-red-1881 NSSM3: node-red -p 1882 -u c:/node-red-1882 etc etc Just be sure that the account that runs the NSSM service has read/write access to these folders.

> [@Running as a service on a windows OS](https://discourse.nodered.org/t/running-as-a-service-on-a-windows-os/37639/4):
>
> Just for completeness, NSSM can also direct stdout/stderr etc to a logfile (and do rotation) [image] [image] NOTE: I split this thread from an old (unrelated thread [Copy Node-red Install on Windows server offline](https://discourse.nodered.org/t/copy-node-red-install-on-windows-server-offline/18135/4))

---

_[View the full topic](https://discourse.nodered.org/t/weird-httpstatic-configuration-in-setting-js-in-nr-windows-11/69765)._
