EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Support for NAS

Also by EldoS: Solid File System
A virtual file system that offers a feature-rich storage for application documents and data with built-in compression and encryption.
#23131
Posted: 01/10/2013 11:48:13
by Dan Martin (Standard support level)
Joined: 07/17/2011
Posts: 7

Hi Guys,
how does eldos support/work with NAS files? Do you know what kind of flags we see for read/write?

My experience:
- I see all files in callback filter
- but read/writes without NO_CACHE flag being set (for windows based applications -- i.e. explorer copy)
- In the above case (without NO_CACHE flag being set), how do we know if the read is going to system cache or to the actual file?

Any help would be much appreciated...

thanks,
#23132
Posted: 01/10/2013 13:00:22
by Vladimir Cherniga (EldoS Corp.)

Hi,
system caching for network shared resources is the question of interaction between redirector on client side and server file system. In local disk filtering we rely on IRP_PAGING_IO and IRP_NOCACHE flags specified in Irp packets for write and read requests. For network resources we interpret such flags as unreliable and alway return Cached = false in read/write callbacks.
#23147
Posted: 01/12/2013 14:45:47
by Vladimir Cherniga (EldoS Corp.)

Hi again,
i want to resume my previous post. From the Callback Filter side, we cannot make a decision about possible file caching. All work is hidden between redirector and remote file system. It does mean that we cannot decide does file cached locally or not, relying on intercepted Irp flags. To satisfy your tasks, you should set filter on the server part. Additionally, local caching on client machine is a question of opportunistic locks, that may be granted to the remote file. You may disable oplocks usage through the registry settings, in order to prevent local caching, or break already granted oplocks using file system requests. This is a one of the possible way to handle local caching for the network files. Hope it helps.
#23157
Posted: 01/14/2013 08:24:14
by Dan Martin (Standard support level)
Joined: 07/17/2011
Posts: 7

Hi Vladimir,
thanks for your response. From my readings, there are two possible places for caching:
- system cache
- redirector cache

In the case of NAS, does the "system cache" cache the data? How can I tell if the system is caching the data (as stated in OP, the NO_CACHE flag is not followed)? I am ok if the data is cached in the redirector.

thanks for your help.
#23160
Posted: 01/14/2013 13:54:23
by Vladimir Cherniga (EldoS Corp.)

In redirector on client side system cache is used when oplocks is granted to the file. On server side file is cached for sure, for performance purposes as well. In our filter we don't propagate Cached/NonCached flags in Read/Write callbacks, as it is no guaranty for the file opened for cached write, that redirector sends request to the cache, not directly to the network. If you want caching enabled on client side, then you must have enabled (by default) opportunistic locks. In this case system will do the work for caching files locally. But this is couldn't be seen from read/write callbacks. What is your final goal in filter usage ?
#23161
Posted: 01/14/2013 17:15:41
by Dan Martin (Standard support level)
Joined: 07/17/2011
Posts: 7

Vladimir,
thanks, again, for your input. I am trying to track all the reads/writes that is going to the actual file (not to the system cache). How can I do this? Can we move the altitude of the filter so that we are below System Cache. This would make sure that we only see requests going to NAS or redirection cache.


thanks,
#23162
Posted: 01/14/2013 18:27:05
by Vladimir Cherniga (EldoS Corp.)

Filter itself resides above file system or redirector/mup and always interrupt any read/write requests, but the problem is to detect the source and destination of data flow. In your case you may try to detect the process ID of requester, that is in the case of cache manager is equal to system process ID (in most windows systems this pid = 4)
#23216
Posted: 01/16/2013 10:17:53
by Dan Martin (Standard support level)
Joined: 07/17/2011
Posts: 7

Vladimir,
firs off, thanks for all your prompt responses.

I have another question for me to come up with a design: When is the cache Manager involved in the NAS Client? I.e. If I copy file using explorer (which is buffered -- means Cache Manager should be involved), I do not see Cache Manager activity in ProcMon. But if I do some other, say winrar, tasks (again buffered), I do see System Cache activity in ProcMon.

Do you know (or can you explain) when Cache Manager gets involved in on NAS Client. Any flag (in create) or special operation to let CM know?

thanks,
#23217
Posted: 01/16/2013 12:54:47
by Vladimir Cherniga (EldoS Corp.)

To my knowledge, it depends on rules of opportunistic locks granting. If file opened exclusively, then redirector decides to grant an exclusive or shared oplocks, an from this point local caching is activated. If any additional file handle requested from another process, then this locks will break, and it stops local caching of remote file. It does mean that you cannot rely on flags in create request or any others. You may check in some way if any oplocks currently held and then make further decisions.
Also by EldoS: SecureBlackbox
200+ components and classes for digital security, signing, encryption and secure networking.

Reply

Statistics

Topic viewed 3139 times

Number of guests: 1, registered members: 0, in total hidden: 0




|

Back to top

As of July 15, 2016 EldoS Corporation will operate as a division of /n software inc. For more information, please read the announcement.

Got it!