Keep session on windows file server

Hi there,

I have written my own node, which should copy files into several directories. In terms of function, there are no problems. However, the file system admin reports that hundreds of login and logoff events per second are registered on the file server during a run. Since these events have to be saved, the admin asked me to reduce the number of events.
In fact, I'm working on relatively few files. There should be about 30 files per minute. Nevertheless, hundreds of login and logoff events are generated.
I only use the standard functions of nodejs (fs.lstatSync, fs.accessSync, fs.readdir, fs.statSync, fs.createWriteStream, fs.copyFileSync, fs.unlinkSync, ...). I think that every function call creates a login and a logoff event.

Is it possible to cash this authorization? Is it possible to use the authorization of the main process for the file functions? The main process of NodeRed runs on a Windows server as a service in the context of its own user. The file system to be accessed is accessed via a network (UNC) and is based on a Windows server. The NodeRed server is not the same as the file server.

Are there any options to reduce the permanent login and logout to the file server to an absolute minimum?

Not by any means an expert here but you might want to look to see if there are any Windows-specific libraries on npm that might help.

Typically, for current generation network file access on Windows servers, you would probably be looking at Kerberos authentication so look for libraries that have support for that or the older NTLM (AKA Samba) authentication.

Actually, I'm not looking for an alternative library, but was hoping that the standard functions for the NodeJs would have the potential to solve my problem.

Or do I absolutely need another library?

Sorry, I don't know the answer I'm afraid. If you found a library, it would indicate that others have hit the same issue. You would really be better off asking this question on a node.js forum I think.