Scanning entity and method for scanning a netwrok attached storage system

The scanning entity prioritizes NAS directories by change timestamps, optimizing resource allocation and scan efficiency, reducing bandwidth and CPU usage while ensuring consistent results for important files, addressing the inefficiencies of conventional NAS scanning methods.

WO2024235428A1PCT designated stage expired Publication Date: 2024-11-21HUAWEI TECH CO LTD +1
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
PCT/EP2023/062809
Authority / Receiving Office
WO · WO
Patent Type
Applications
Current Assignee / Owner
Filing Date
2023-05-12
Publication Date
2024-11-21

AI Technical Summary

Technical Problem

Conventional NAS scanning methods waste CPU and network bandwidth by scanning frequently changed and infrequently changed directories equally, neglecting potentially important information in less frequently scanned locations and resulting in inefficient resource allocation.

Method used

A scanning entity that generates priority lists of file directories based on change timestamps, allowing for efficient scanning of important directories while predicting and controlling lag in non-prioritized ones, using a directory modification time database and client-side caching to reduce bandwidth and CPU usage.

Benefits of technology

This approach reduces network bandwidth and CPU power consumption, provides more frequent and accurate scan results, and ensures highly consistent values for important files while maintaining lower consistency for unimportant files, enhancing performance in applications like PII detection and malware scanning.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure EP2023062809_21112024_PF_FP_ABST
    Figure EP2023062809_21112024_PF_FP_ABST
Patent Text Reader

Abstract

A device and method for scanning a Network Attached Storage (NAS) system, the NAS system comprising a plurality of file directories of one or more users. The scanning entity is configured to access the plurality of file directories in the NAS system. Then, the scanning entity determines one or more of the file directories that were changed in the NAS system and a respective change timestamp for each of the one or more changed file directories. Further, the scanning entity generates one or more priority lists for the plurality of file directories. Each priority list comprises a listing of one or more file directories having a same directory scan priority and their respective change timestamps. Then, the scanning entity is configured to scan each file directory of the plurality of file directories in the NAS system using the one or more priority lists, and generate a scan result.
Need to check novelty before this filing date? Find Prior Art

Description

[0001] SCANNING ENTITY AND METHOD FOR SCANNING A NETWROK ATTACHED STORAGE SYSTEM

[0002] TECHNICAL FIELD

[0003] The present disclosure relates to a scanning entity for scanning a Network Attached Storage (NAS) system, the NAS system comprising a plurality of file directories of one or more users. The disclosure further provides a corresponding method for scanning a NAS system, and a computer program product to perform the method.

[0004] BACKGROUND

[0005] Network Attached Storage (NAS) is a type of storage device that provides access to files over a network. NAS implementations usually allow multiple clients to access the files and include methods for parallel access, coherency semantics, access control and other features that allow multiple users to access the files.

[0006] NAS protocol implementations include, for example, Server Message Block (SMB) originally developed by IBM in 1983, Common Internet File System (CIFS) which is a popular variant of SMB 1.0, Network File System (NFS) originally developed by Sun Microsystems, and currently an open standard for serving NAS.

[0007] Scanning NAS is performed for different reasons, which range from malware detection to file backup and auditing.

[0008] NAS Share describes a network location in which a shared file system is available using a network protocol. Scanning a NAS share requires network and compute resources that may be substantial if the NAS contains a large number of files or directories. The network resources are required in order to retrieve data and file / directory attributes, and the compute resources are required in order to process this data.

[0009] Further, eventual consistency is a consistency model used in distributed computing systems, and denotes that the data model will eventually contain the latest updates. Interim read of the data may return older results. A conventional solution creates a table in which file folder (directory) activity is maintained and used to create a "skip table database", which is then used to reduce the number of directories scanned during full scan of the NAS. Using the directory activity as a heuristic for scanning and skipping, however, looks at frequently changed locations that do not contain information that is interesting for a scan application. This results in wasted CPU and network bandwidth. In addition, there is no balance between frequently changed locations and locations that have not been scanned in a long time, and which may include interesting information to the scan application.

[0010] SUMMARY

[0011] In view of the above, this disclosure aims to improve conventional solutions for scanning NAS systems that reduce the network bandwidth to a minimum required to get the most necessary file updates without the need to do heavy sorting operations on all the list of changed files, which allows system resources to be focused mainly on scanning the most important files.

[0012] This and other objectives are achieved by the solutions of this disclosure as described in the independent claims. Advantageous implementations are further defined in the dependent claims.

[0013] According to a first aspect, a scanning entity for scanning a NAS system is provided. The NAS system includes a plurality of file directories of one or more users, and the scanning entity is configured to: access the plurality of file directories in the NAS system; determine one or more of the file directories that were changed in the NAS system and determine a respective change timestamp for each of the one or more changed file directories; generate one or more priority lists for the plurality of file directories, where each of the priority lists comprises a listing of one or more file directories having a same directory scan priority and their respective change timestamp; scan each file directory of the plurality of file directories in the NAS system using the one or more priority lists; and generate a scan result.

[0014] This provides the advantage of efficiently creating prioritized lists of scan directory locations that allows frequent scan of "important" directory locations without neglecting other locations that may not be known to be important but that need to be scanned. Further, the prioritization is determined in a way that it allows to predict a lag of non-prioritized file directories and controls this lag without affecting the performance of the scanning.

[0015] Moreover, the efficient prioritization according to the first aspect may provide better results for an end user, which receives more frequent and useful results from the scan. In addition, the reduced bandwidth to primary storage causes improved latency and bandwidth for other applications. This data model is eventually consistent by design in an attempt to give highly consistent values for important files, and lower consistency for unimportant files.

[0016] The solutions according to this disclosure are extremely useful for Personal Identifiable Information (PII) detection, file classification (e.g. classify files related to health, finance etc.), malware detection, incremental file backup, priority based backup and other solutions which are based on the NAS system scan.

[0017] In an implementation form of the first aspect, the scanning entity is further configured to create a directory modification time database by: initializing an empty database; performing an initial full scan of the NAS system; and for each changed file directory found in the NAS system, recording the changed file and a respective change timestamp in the database.

[0018] In an implementation form of the first aspect, determining the one or more file directories that were changed in the NAS system and their respective change timestamps includes: performing a scan of each file directory in the NAS system at one or more time frames, where each time frame comprises a predefined value; determining whether one or more file directories were changed within each time frame based on the scan of the NAS system at the time frame and based on the directory modification time database; and for each time frame, assigning to each of the one or more changed file directories a respective change timestamp, and storing the respective timestamp in the database.

[0019] This provides the advantage of enabling to efficiently locate the changed file directories and their respective timestamps even when a NAS protocol of the NAS system does not provide with notification of changes.

[0020] By listing only the changed file directories and the respective change timestamps, time and network bandwidth are further reduced. In an implementation form of the first aspect, determining the one or more file directories that were changed in the NAS system and determining their respective change timestamps, includes: receiving, from the NAS system at one or more time frames, one or more notifications of changes in the one or more file directories, where each time frame comprises a predefined value; and for each time frame, assigning a change timestamp to each of the one or more changed file directories.

[0021] This provides the advantage of accurately locating the changed file directly locations via the notifications enabled by the NAS protocol of the NAS system.

[0022] The notifications of changes may be performed by the NAS system as a part of a NAS protocol, which may allow client-side caching. Client-side caching is crucial for NAS performance since otherwise a server may become a bottleneck and may require several synchronization operations.

[0023] In an implementation form of the first aspect, determining the one or more file directories that were changed in the NAS system and determining their respective change timestamps further includes: generating a directory group table, wherein the directory group table comprises a listing of the determined one or more changed file directories for each time frame, and their respective change timestamps.

[0024] This provides the advantage of grouping the changed file directories spanned in an amount of time, which can be predefined, so that there is no more than a predefined time between the changes performed in the one or more file directories.

[0025] In an implementation form of the first aspect, the scanning entity is further configured to generate a directory priority table comprising a listing of the plurality of file directories and a respective directory scan priority.

[0026] The directory priority table maps each changes file directory name to a priority. Further, the directory priority table may be periodically updated according to scan results. This is beneficial, since each changed file directory is assigned a different priority according to its importance to the scan.

[0027] In an implementation form of the first aspect, the scanning entity is further configured to: generate, for each time frame, one or more directory buckets based on the directory priority table and based on the directory group table. Each directory bucket includes a listing of one or more changed file directories for each time frame of the directory group table having a same directory scan priority and their respective change timestamps. Each directory bucket has a bucket priority and a bucket timestamp.

[0028] This enables to further create multiple groups of changed file directories based on their respective scan priority for each time frame. Further, each file directory bucket is assigned a timestamp which matches either the smallest or largest change timestamp of the changed directories comprised in the bucket, which may be used to further determine a bucket to be scanned.

[0029] In an implementation form of the first aspect, each bucket priority corresponds to one directory scan priority.

[0030] This enables to further group the changed file directors, for each time frame, having the same scan priority.

[0031] In an implementation form of the first aspect, the bucket timestamp of each directory bucket is a smallest change timestamp of the one or more file directories in the directory bucket, or a largest change timestamp of the one or more file directories in the directory bucket.

[0032] In an implementation form of the first aspect, each of the priority lists further comprises a listing of one or more directory buckets having a same bucket priority and their respective bucket timestamp for each time frame.

[0033] The scanning entity may add, for each time frame, each of the one or more directory buckets to the end of the one or more priority lists. As a result, the one or more directory buckets in each priority list are inherently sorted by time, and each directory bucket comprises one or more changed file directories that may be unsorted. Hence, the scanning entity according to the first aspect may provide with a semi-sorted listing of the changed files directories without actually performing a sorting operation that is costly in time and CPU power.

[0034] In an implementation form of the first aspect, scanning each file of the one or more users in the NAS system based on the one or more priority lists, includes: for each of the one or more directory buckets in each of the priority lists, determining a respective weight based on the bucket priority and based on the bucket timestamp; selecting each directory bucket in the one or more priority lists based on the respective weight; and removing the selected bucket form the respective priority list and scanning the selected directory bucket.

[0035] This provides the advantage of efficiently enabling the prioritized scan of the NAS system by using the above-mentioned semi-sorted listing of the changed files directories. This reduces the time and CPU power required to perform the scan.

[0036] In an implementation form of the first aspect, the weight for each of the one or more directory buckets is determined by calculating a weight function, the weight function including at least the bucket timestamp and the bucket priority.

[0037] This enables to further enhance the accuracy on determining a relevance to the scan for each of the changed file directories comprised in the directory buckets.

[0038] In an implementation form of the first aspect, the scanning entity is further configured to store the directory priority table. Additionally or alternatively, the scanning entity is further configured to store the one or more priority lists.

[0039] In the first aspect and its implementations, the functions described may be implemented in hardware, software, firmware, or any combination thereof.

[0040] According to a second aspect, a method for scanning a NAS system is provided. The NAS system includes a plurality of file directories of one or more users, and the method includes: accessing the plurality of file directories in the NAS system; determining one or more of the file directories that were changed in the NAS system and determine a respective change timestamp for each of the one or more changed file directories; generating one or more priority lists for the plurality of file directories, wherein each of the priority lists comprises a listing of one or more file directories having a same directory scan priority and the respective change timestamp; scanning each file directory of the plurality of file directories in the NAS system using the one or more priority lists; and generating a scan result.

[0041] This provides the advantage of efficiently creating prioritized lists of scan directory locations that allows frequent scan of "important" directory locations without neglecting other locations that may not be known to be important but that need to be scanned.

[0042] Further, the prioritization is determined in a way that it allows to predict a lag of non-prioritized file directories and controls this lag without affecting the performance of the scanning.

[0043] The solutions according to this disclosure are extremely useful for PII detection, file classification (e.g. classify files related to health, finance etc.), malware detection, incremental file backup, priority based backup and other solutions which are based on the NAS system scan.

[0044] In an implementation form of the second aspect, the method further includes creating a directory modification time database by: initializing an empty database; performing an initial full scan of the NAS system; and for each changed file directory found in the NAS system, recording the changed file and a respective change timestamp in the database.

[0045] In an implementation form of the second aspect, determining the one or more file directories that were changed in the NAS system and their respective change timestamps includes: performing a scan of each file directory in the NAS system at one or more time frames, where each time frame comprises a predefined value; determining whether one or more file directories were changed within each time frame based on the scan of the NAS system at the time frame and based on the directory modification time database; and for each time frame, assigning to each of the one or more changed file directories a respective change timestamp, and storing the respective timestamp in the database.

[0046] This provides the advantage of enabling to efficiently locate the changed file directories and their respective timestamps even when a NAS protocol of the NAS system does not provide with notification of changes. By listing only the changed file directories and the respective change timestamps, time and network bandwidth are further reduced.

[0047] In an implementation form of the second aspect, determining the one or more file directories that were changed in the NAS system and determining their respective change timestamps, includes: receiving, from the NAS system at one or more time frames, one or more notifications of changes in the one or more file directories, where each time frame comprises a predefined value; and for each time frame, assigning a change timestamp to each of the one or more changed file directories.

[0048] This provides the advantage of accurately locating the changed file directly locations via the notifications enabled by the NAS protocol of the NAS system.

[0049] The notifications of changes may be performed by the NAS system as a part of a NAS protocol, which may allow client-side caching. Client-side caching is crucial for NAS performance since otherwise a server may become a bottleneck and may require several synchronization operations.

[0050] In an implementation form of the second aspect, determining the one or more file directories that were changed in the NAS system and determining their respective change timestamps further includes: generating a directory group table, wherein the directory group table comprises a listing of the determined one or more changed file directories for each time frame, and their respective change timestamps.

[0051] This provides the advantage of grouping the changed file directories spanned in an amount of time, which can be predefined, so that there is no more than a predefined time between the changes performed in the one or more file directories.

[0052] In an implementation form of the second aspect, the method further includes generating a directory priority table comprising a listing of the plurality of file directories and a respective directory scan priority.

[0053] The directory priority table maps each changes file directory name to a priority. Further, the directory priority table may be periodically updated according to scan results. This is beneficial, since each changed file directory is assigned a different priority according to its importance to the scan.

[0054] In an implementation form of the second aspect, the method further includes generating, for each time frame, one or more directory buckets based on the directory priority table and based on the directory group table. Each directory bucket includes a listing of one or more changed file directories for each time frame of the directory group table having a same directory scan priority and their respective change timestamps. Each directory bucket has a bucket priority and a bucket timestamp.

[0055] This enables to further create multiple groups of changed file directories based on their respective scan priority for each time frame. Further, each file directory bucket is assigned a timestamp which matches either the smallest or largest change timestamp of the changed directories comprised in the bucket, which may be used to further determine a bucket to be scanned.

[0056] In an implementation form of the second aspect, each bucket priority corresponds to one directory scan priority.

[0057] This enables to further group the changed file directors, for each time frame, having the same scan priority.

[0058] In an implementation form of the second aspect, the bucket timestamp of each directory bucket is a smallest change timestamp of the one or more file directories in the directory bucket, or a largest change timestamp of the one or more file directories in the directory bucket.

[0059] In an implementation form of the second aspect, each of the priority lists further comprises a listing of one or more directory buckets having a same bucket priority and their respective bucket timestamp for each time frame.

[0060] The scanning entity may add, for each time frame, each of the one or more directory buckets to the end of the one or more priority lists. As a result, the one or more directory buckets in each priority list are inherently sorted by time, and each directory bucket comprises one or more changed file directories that may be unsorted. Hence, the scanning entity according to the second aspect may provide with a semi-sorted listing of the changed files directories without actually performing a sorting operation that is costly in time and CPU power.

[0061] In an implementation form of the second aspect, scanning each file of the one or more users in the NAS system based on the one or more priority lists, includes: for each of the one or more directory buckets in each of the priority lists, determining a respective weight based on the bucket priority and based on the bucket timestamp; selecting each directory bucket in the one or more priority lists based on the respective weight; and removing the selected bucket form the respective priority list and scanning the selected directory bucket.

[0062] This provides the advantage of efficiently enabling the prioritized scan of the NAS system by using the above-mentioned semi-sorted listing of the changed files directories. This reduces the time and CPU power required to perform the scan.

[0063] In an implementation form of the second aspect, the weight for each of the one or more directory buckets is determined by calculating a weight function, the weight function including at least the bucket timestamp and the bucket priority.

[0064] This enables to further enhance the accuracy on determining a relevance to the scan for each of the changed file directories comprised in the directory buckets.

[0065] In an implementation form of the second aspect, the method further includes storing the directory priority table. Additionally or alternatively, the method further includes storing the one or more priority lists.

[0066] The method according to the second aspect comprises the features of the corresponding implementation forms of the device of the first aspect.

[0067] According to a third aspect, a computer program product is provided, including a program code for carrying out, when implemented on a processor, the method according to the second aspect and its implementation forms. The computer program product according to the third aspect comprises the features of the corresponding implementation forms of the method of the second aspect.

[0068] The method according to the second aspect and the computer program product according to the third aspect and their implementation forms provide the same advantages and effects as described above for the device of the first aspect and its respective implementation forms.

[0069] It has to be noted that all devices, elements, units and means described in the present application could be implemented in the software or hardware elements or any kind of combination thereof. All steps which are performed by the various entities described in the present application as well as the functionalities described to be performed by the various entities are intended to mean that the respective entity is adapted to or configured to perform the respective steps and functionalities. Even if, in the following description of specific embodiments, a specific functionality or step to be performed by external entities is not reflected in the description of a specific detailed element of that entity which performs that specific step or functionality, it should be clear for a skilled person that these methods and functionalities can be implemented in respective software or hardware elements, or any kind of combination thereof.

[0070] BRIEF DESCRIPTION OF DRAWINGS

[0071] The above described aspects and implementation forms will be explained in the following description of specific embodiments in relation to the enclosed drawings, in which:

[0072] FIG. 1 shows a scanning entity for scanning a NAS system, according to this disclosure;

[0073] FIG. 2 schematically depicts an example of a directory group table according to this disclosure;

[0074] FIG. 3 schematically depicts an example of a directory group table, an example for a directory scan priority, and examples of directory buckets according to this disclosure;

[0075] FIG. 4 schematically depicts examples of priority lists according to this disclosure;

[0076] FIG. 5 shows a scanning entity for scanning a NAS system, according to this disclosure;

[0077] FIG. 6 shows a method for scanning a NAS system according to this disclosure; FIG. 7A-B show examples of locations in a file system in which PIIs are found. DETAILED DESCRIPTION OF EMBODIMENTS

[0078] Different scanning applications can be performed in a NAS system, for example and not as a limitation, to search for PII. FIG. 7A shows an example of locations within a file system in a NAS system 720 where, for example, a PII scanning is performed. The file system of FIG. 7A may be, for example, a Linux file system. As it can be observed in FIG. 7A, PII information may be found by previous scans in three exemplary locations 702 / home / Marry / Customers, / home / John / Records, and / home / Ellison / Projects.

[0079] Preforming PII detection on files changed in these directories 702 may be a good heuristic to get a knowledge of the files containing PIIs as well as the PIIs that are contained in each file for regulation purposes.

[0080] FIG. 7B shows an example in which an additional, unexpected location of PII for the file directories of the NAS system 720 of FIG. 7 A is found inside the caches of an application, for example in the location / opt / Data Processor / cache 702.

[0081] If only the expected locations in the NAS system 720 are scanned, the PIIs in the unexpected or less frequently scanned directories 702, for example in the cache of FIG. 7B, may be missed. This may result in incompliance with regulations of storing PIIs. This may further cause fines to a company and may even result in PII information being stolen and exposed.

[0082] Hence, conventional scans should be improved by allowing frequent scan of "important" locations without neglecting other locations which are not frequently scanned as being considered "not important" but that need to be scanned. Furthermore, the improved scanning may be eventually consistent so that highly consistent values may be given for important files and lower consistent values for unimportant files are achieved. This is achieved by the present disclosure as explained in the following.

[0083] FIG. 1 shows an exemplary embodiment of a scanning entity 100 for scanning a NAS system 120 according to this disclosure.

[0084] The scanning entity 100 according to this disclosure may comprise a processor or processing circuitry (not shown) configured to perform, conduct or initiate the various operations of the device 100 described herein. The processing circuitry may comprise hardware and / or the processing circuitry may be controlled by software. The hardware may comprise analog circuitry or digital circuitry, or both analog and digital circuitry. The digital circuitry may comprise components such as application-specific integrated circuits (ASICs), field- programmable arrays (FPGAs), digital signal processors (DSPs), or multi-purpose processors. The scanning entity 100 may further comprise memory circuitry, which stores one or more instruction(s) that can be executed by the processor or by the processing circuitry, in particular under control of the software. For instance, the memory circuitry may comprise a non-transitory storage medium storing executable software code which, when executed by the processor or the processing circuitry, causes the various operations of the scanning entity 100 to be performed. The processing circuitry may comprise one or more processors and a non-transitory memory connected to the one or more processors. The non-transitory memory may carry executable program code which, when executed by the one or more processors, causes the scanning entity 100 to perform, conduct or initiate the operations or methods described herein.

[0085] The scanning entity 100 may be included or may be part of the NAS system 120. Alternatively, the scanning entity 100 may be implemented outside the NAS system 120.

[0086] The NAS system 120 comprises a plurality of file directories 101 of one or more users, and the scanning entity 100 may perform a scanning application. The scanning application may comprise an application based on a scan of the NAS system 120. For example and not as a limitation, the scanning application may comprise an application configured to perform PII detection, or file classification (for example, to classify files related to health, finance, etc.), or malware detection, or incremental file backup, or priority based backup, or the like.

[0087] The scanning entity 100 is configured to access the plurality of file directories 101 in the NAS system 120.

[0088] Then, the scanning entity 100 is configured to determine one or more of the file directories 102 that were changed in the NAS system 120, and to determine a respective change timestamp 103 for each of the one or more changed file directories.

[0089] Further, the scanning entity 100 is configured to generate one or more priority lists 104 for the plurality of file directories 102. Each of the priority lists 104 comprises a listing of one or more changed file directories 102 having a same directory scan priority, and their respective change timestamp 103.

[0090] Then, the scanning entity 100 is configured to scan each file directory 101 of the plurality of file directories in the NAS system 120 using the one or more priority lists 104. Further, the scanning entity 100 is configured to generate a scan result.

[0091] The scan result is generated according to the scanning application. Without limitation, for the exemplary scanning applications aforementioned, the scan result may respectively comprise one or more PIIs, or a classification of files related to e.g. health or finance, or a notification of a malware detected in the NAS system, or information about to an increment in file backup, or information about a priority-based backup, or the like.

[0092] Further, to determine the one or more of the file directories 102 that were changed in the NAS system 120 and their respective change timestamps 103, the scanning entity is configured to receive, from the NAS system 120 at one or more time frames, one or more notifications of changes in the one or more file directories 102.

[0093] That is, the scanning device 100 may receive the notifications of changes, which span an amount of time determined by the time frame. Each time frame may comprise a predefined value. The predefined value may be an amount of time X, for example 1 second interval. The time frame, thus, means that there are no more than X seconds between a changed or modification performed in the one or more changes files 120.

[0094] The notifications of changes may be performed by the NAS system 120 as a part of a NAS protocol, which may allow client-side caching. Client-side caching is crucial for NAS performance since otherwise a server may become a bottleneck and may require several synchronization operations.

[0095] A method of receiving the notifications of changes may be based on the NAS protocol of the NAS system 120 and may comprise, for example, a SMB CHANGE NOTIFY feature, or an NFSv4 CHANGE attribute. The NAS protocol may further send, to the scanning entity 100, information related to the one or more changed file directories 120.

[0096] When the NAS system 120 provides notifications of change, the scanning entity 100 may then determine the exact location of the file directories 102 that were changed in the NAS system 120.

[0097] Then, for each time frame, the scanning entity 100 is configured to assign a change timestamp 103 to each of the one or more changed file directories 102.

[0098] Further, to determining the one or more file directories 102 that were changed in the NAS system 120 and determining their respective change timestamps 103, the scanning entity 100 is further configured to generate a directory group table 206. The directory group table 206 comprises a listing of the determined one or more changed file directories 102 for each time frame X, and their respective change timestamps 103.

[0099] That is, changed file directories 102 which span the predefined amount of time X are grouped.

[0100] FIG. 2 schematically depicts an example of the directory group table 206 according to this disclosure. This example shows seven changed file directories 102, exemplary Dir 1 to Dir 7, each with a different change timestamp. The exemplary timestamps 103 shown in FIG 2 are arbitrary and for illustrative purposes. The largest or maximum timestamp is Tk+5, corresponding to Dir 2, and the minimal timestamp is Tk-2, corresponding to Dir 3. Since the grouping of file directories 102 is limited to the creation to the timespan X, the largest (maximum) and smallest (minimum) timestamps of the changed file directories 102 obey Tk+5 - Tk-2 < X.

[0101] In addition, the largest (maximum) timestamp in a previous time frame (i.e., in a previous group) is smaller than the smallest time stamp of a current time frame, i.e., is smaller than Tk-2 in this example.

[0102] Since some file directories 101 of the NAS system 120 contain files that are more interesting to the scan application than others (for a PII detection scan, the interesting or important file directories are those where files with PIIs have been found in previous scans), files from these file directories 101 may be scanned before others.

[0103] Hence, each file directory 102 may have a different scan priority 308 according to its importance or relevance to the scan.

[0104] Each scan of the NAS system 120 performed by the scanning entity 100 may contain one or more parameters for determining the file directories that are important. Additionally or alternatively, in this disclosure, a map where each file directory name is mapped to a priority is created.

[0105] That is, in the embodiment of FIG. 1, the scanning entity 100 is further configured to generate a directory priority table 307. The directory priority table 307 comprises a listing of the one or more file directories 102 and a respective directory scan priority 308.

[0106] The directory priority table 307 may be updated periodically according to scan results.

[0107] FIG. 3 schematically depicts the exemplary directory group table 206 for the seven file directories 102 according to FIG. 2, and an example for the directory priority table 307. In this example, the changed file directories 102 Dir 1, Dir 3 and Dir 6 have assigned a same scan priority 308, having the exemplary priority value 1. The changed file directories 102 Dir 2 and Dir 7 have a scan priority 308 with an exemplary value 2, and Dir 4 and Dir 5 have a scan priority 308 with an exemplary value 3. This is not limiting in the present disclosure. For example, the changed file directories 102 may have each a different directory scan priority.

[0108] In other words, each changed file directory 102 is assigned a priority 308 that determines an order in which the changed file directories 102 will be scanned in the NAS system 120 according to the scanning application.

[0109] The values for the directory scan priorities 308 may be different than exemplary values 1 to 3. Moreover, the value of the scan priorities 308 may indicate the priority or relevance in ascending or descending order. Further, values for the directory scan priorities 308 may be defined by a user or may be defined automatically by the scanning application. Further, in the embodiment of FIG. 1, the scanning entity 100 is configured to generate, for each time frame, one or more directory buckets 309 based on the directory priority table 307 and based on the directory group table 206, as schematically depicted in FIG. 3.

[0110] Each directory bucket 309 comprises, for each time frame, a listing of one or more of the changed file directories 102 of the directory group table 206 that have a same directory scan priority 308, as well as their respective change timestamps 103. Further, each directory bucket 309 has a bucket priority 310 and a bucket timestamp 311.

[0111] Each bucket priority 310 corresponds to one directory scan priority 308. The bucket timestamp 311 of each directory bucket 309 is a smallest change timestamp 103 of the one or more file directories 102 in the directory bucket 309, or a largest change timestamp 103 of the one or more file directories 102 in the directory bucket 309.

[0112] That is, each bucket 309 is assigned a bucket timestamp 310 which matches either the smallest or the largest change timestamp 103 of the changed file directories 102 comprised in the bucket 309. The bucket timestamp 310 may be further used to select a next bucket to be scanned by the scanning entity 100, as it will be explained later in this disclosure.

[0113] Thereby, in this embodiment, instead of creating a single group for all the changes in the time frame X, multiple groups or directory buckets 309 can be created, where each directory bucket 309 may have a different priority 310 according to its importance to the scan.

[0114] The scanning entity 100 may be configured to choose the bucket 309 in which a changed file directory 102 may be placed, by reading the respective file directory priority 308 from the directory priority table 307, and then listing the changed file directory 102 in the directory bucket 309 which matches the file directory priority 308.

[0115] FIG. 3 depicts schematically an example showing that the changed file directors for each time frame X (i.e. the directory group) is split into three priority buckets, exemplary buckets 309-1, 309-2, and 309-3, each having a respective bucket priority 310, and each directory bucket 309 takes the timestamp of the largest or maximum change timestamp 103 of its changed directories 102. In this example, the changed file directories 102 Dir 1, which has the changed timestamp Tk, Dir 3, which has the changed timestamp Tk-2, and Dir 6, which has the changed timestamp Tk- i, may be listed in a same directory bucket, for example the directory bucket 309-1, since they have the same directory scan priority 308 with the exemplary priority value 1. Accordingly, the directory bucket 309-1 may be assigned the bucket priority 1. Further, the directory bucket 309-1 has a bucket timestamp 311 that is the maximum (largest) changed file stamp 103 of the changed file directories 102, i.e., the directory bucket 309-1 has the bucket timestamp 311 Tk (corresponding to the changed timestamp 103 of the file directory Dir 1).

[0116] In the example of FIG. 3, the changed file directories 102 Dir 2, which has the changed timestamp Tk+5, and Dir 7, whit the changed timestamp Tk, may be listed in the same directory bucket, for example the directory bucket 309-2, since they have the same directory scan priority 308 with the exemplary priority value 2. Accordingly, the directory bucket 309-2 is assigned the bucket priority 2, and the directory bucket 309-2 has the bucket timestamp 311 Tk+5, which is the maximum (largest) changed timestamp 103 and corresponds to the file directory Dir 2.

[0117] Further, the changed file directories 102 Dir 4, having the changed timestamp Tk-i and Dir 5, having a changed timestamp Tk+3 may be listed in the same directory bucket, for example the directory bucket 309-3, since they have the same directory scan priority 308 with the exemplary priority value 3. Accordingly, the directory bucket 309-3 is assigned the bucket priority 3, and the directory bucket 309-3 has the bucket timestamp 311 Tk+3, which is the maximum (or largest) changed timestamp 103 and corresponds to the file directory Dir 4.

[0118] Then, in the embodiment of FIG. 1, the scanning entity 100 may be configured to add each of the one or more directory buckets 309 to the one or more priority lists 104. The addition may be performed by listing (or placing), for each time frame X, each directory bucket 309 at the end of one of the priority lists 104. Thereby, a complexity of this operation is 0(1) per priority list 104.

[0119] Each of the priority lists 104, thus, comprises, for each time frame, a listing of one or more directory buckets 309 having a same bucket priority 310 as well as their respective bucket timestamp 311. In other words, each entry of each of the one or more priority lists 104 comprises a directory bucket 309 and its respective bucket timestamp 311.

[0120] As a result, each of the priority lists 104 comprises one or more directory buckets 309 that are inherently sorted by time, since each directory bucket 309 is obtained at each closed timespan X, as disclosed above, and each directory bucket 309 comprises one or more changed file directories 102 that may be unsorted. Thus, the scanning entity 100 according to this disclosure allows to generate a semi-sorted listing of the changed files directories 102 without actually performing a sorting operation, which is costly in time and CPU power. This is due to the fact that the scanning entity 100 generates the one or more priority lists 104 by adding a priority bucket 309 at the end of a list 104; since the directory buckets 309 are processed by time, it is an inherent attribute of the list 104 that adding a bucket 309 to its respective tail may sort them by time.

[0121] Optionally, each directory bucket 309 may further comprise information of each of the one more changed file directories 102.

[0122] In the embodiment of FIG. 1, the time frame X can be controlled so that a number of the one or more changed file directories 102 in each directory bucket 309 equals a predefined amount of work; thereby, each priority list 104 may be a sorted list of approximately a same work definition.

[0123] Further, in the embodiment of FIG. 1, scanning each file directory 101 of the one or more users in the NAS system 120 based on the one or more priority lists 104, comprises determining, for each of the one or more directory buckets 309 in each priority list 104, a respective weight based on the bucket priority 310 and based on the bucket timestamp 311.

[0124] Further, the scanning each file directory 101 of the one or more users in the NAS system 120 comprises selecting each directory bucket 309 in the one or more priority lists 104 based on the respective weight. Next, it comprises removing the selected bucket 309 form the respective priority list 104 and scanning the selected the selected directory bucket 309.

[0125] The scanning the selected directory bucket 309 may comprise scanning, at the NAS system 120, the one or more changed files 102 of the selected directory bucket 309. That is, the scanning entity 100 selects a directory bucket 309 to be scanned based on its weighted priority, and effectively scan, at the NAS system 120, the one or more changed files 102 of comprised in the selected directory bucket 309.

[0126] The weight for each of the one or more directory buckets 309 is determined, by the scanning entity 100, by calculating a weight function. The weight function comprises at least the bucket timestamp 311 and the bucket priority 310.

[0127] The weight function, thus, refers to a way to achieve prioritization of important file directories without neglecting other file directories in the NAS system 120.

[0128] In an example, the weight function may first subtract a current time from the bucket timestamp 310. Then, a value of the current time may be normalized using a mathematical function. Further, a value of the bucket priority 310 may be normalized. Next, the normalized time and the normalized priority may be added, resulting in the weight for each directory bucket 309.

[0129] A method for performing the time difference normalization and the bucket priority 310 normalization can vary according to user requirements. Further, a relation between the bucket priority 310 normalization and the time difference normalization above-mentioned may be way to cap a time during which a file directory may be un-scanned.

[0130] The weight function for each directory bucket 309 may change during the scanning of the NAS system 120 by the scanning entity 100, since it uses attributes of the directory buckets 309 and the one or more priority lists 104.

[0131] That is, once the one or more priority lists 104 are generated, the scanning entity 100 may start scanning the NAS system 120. If information of each of the one more changed file directories 102 is not present in the directory buckets 309, the scanning entity 100 may perform a check on each file directory 101 of the NAS system 120 in order to determine whether one or more of the file directories 102 were changed.

[0132] The algorithmic complexity of selecting each directory bucket 309 in the one or more priority lists 104 is 0(1) assuming a fixed number of directory buckets 309. In a practical scenario, fixing a small number of directory buckets 309 may allow capping the amount of time needed to select a directory bucket 309 for scanning.

[0133] FIG. 4 schematically depicts an example for three priority lists 104, each comprising one or more directory buckets 309 and their respective bucket timestamps 311, according to the examples shown in FIGS. 2 and 3.

[0134] Assuming that priority 1 is the highest priority and priority 3 is the lowest priority, and that To is the smallest bucket timestamp 310 and Tnis a higher timestamp, where n=l, 2, ..., the head of the priority list 104 having priority 1, may be first selected for scanning, as it comprises both the smallest timestamp To and the highest priority value.

[0135] The next directory bucket 309 to be selected for scanning depends particularly on the respective determined weight function; however, it may be the second directory bucket 309 (from left to right) in the priority 1 list 104, which has the exemplary bucket timestamp T2>To, or the first (head) directory bucket 309 in the priority 2 list 104, which has the exemplary bucket timestamp T3, (with TS>T2>TO), i.e., the second directory bucket 309 in the priority 1 list 104 has a larger priority and lower timestamp 310 than the priority and timestamp 310 of the first directory bucket 309 in the priority 2 list 104; however, it may have a lower weight than the first directory bucket 309 in the priority 2 list 104.

[0136] FIG. 5 shows an exemplary embodiment of the scanning entity 100 for scanning a NAS system 120 according to this disclosure, which builds on the scanning entity 100 of FIG. 1. Same elements are labelled with the same reference signs.

[0137] The afore-detailed description may be applied to scanning entity 100 of FIG. 1, except for the hereinafter-mentioned noticeable differences. In the exemplary embodiment of FIG. 5, the NAS protocol of the NAS system 120 may not provide notifications of changes of the one or more file directories 102. Thus, the scanning entity 100 may create and maintain a database of file directories 102 and their modification times. Thereby, the scanning entity 100 may be able to identify changed directories 102 as compared to a previous scan.

[0138] In this embodiment, before determining the one or more file directories 102 that were changed in the NAS system 120 and their respective change timestamps 103, the scanning entity 100 is further configured to create a directory modification time database 512 by initializing an empty database 512. Then, the scanning entity 100 is configured to perform an initial full scan of the NAS system 120.

[0139] Next, for each file directory 102 that were found to be changed in the NAS system 120, the scanning entity 100 is further configured to record in the database 512 the changed file directory 102 and its respective change timestamp 103.

[0140] By listing only the changed file directories and the respective change timestamps, time and network bandwidth are further reduced.

[0141] Then, determining the one or more file directories 102 that were changed in the NAS system 120 and their respective change timestamps 103 comprises performing a scan of each file directory 101 in the NAS system 120 at one or more time frames, where each time frame comprises a predefined value. Then, it is determined whether one or more file directories 102 were changed within each time frame based on the scan of the NAS system 120 at the time frame and based on the directory modification time database 512.

[0142] Further, for each time frame, each of the one or more changed file directories 192 is assigned a respective change timestamp 103. Next, the respective timestamp 103 is stored in the database 512.

[0143] In other words, every fixed timeframe X, the scanning entity 100 may perform a directory scan at the NAS system 120 and use the database 512 to locate the changes that were performed in the one or more file directories 101, in a similar manner as implementing a client-side cache. The result of the directory scan may comprise the changed directories 102 in the timeframe X, similarly as by receiving the one or more notifications of changes from the NAS system 120 in the embodiment of FIG. 1.

[0144] Further, to determine the one or more file directories 102 that were changed in the NAS system 120 and determining their respective change timestamps 103, the scanning entity 100 of FIG. 5 is configured to generate the directory group table 206. The directory group table 206 comprises a listing of the determined one or more changed file directories 102 for each time frame, and their respective change timestamps 103, as disclosed above. Then, the scanning entity 100 is configured to generate the directory priority table 307 that comprises a listing of the plurality of file directories 102 and a respective directory scan priority 308.

[0145] Further, the scanning entity 100 is configured to generate, for each time frame, the one or more directory buckets 309 based on the directory priority table 307 and based on the directory group table 206, where each directory bucket 309 comprises a listing of one or more changed file directories 102 for each time frame of the directory group table 206 having a same directory scan priority 308 and their respective change timestamps 103, and each directory bucket 309 has a bucket priority 310 and a bucket timestamp 311.

[0146] Each bucket priority 310 corresponds to one directory scan priority 308. Further, the bucket timestamp 311 of each directory bucket 309 is a smallest change timestamp 103 of the one or more file directories 102 in the directory bucket 309, or a largest change timestamp 103 of the one or more file directories 102 in the directory bucket 309.

[0147] Details regarding the directory group table 206, the directory priority table 307 and the directory buckets 309, the bucket priorities 310 and the bucket timestamps 311 are the same as in the embodiment of FIG. 1 disclosed above, and are not repeated again in this embodiment.

[0148] Further, in the exemplary embodiment of FIG. 5, each of the priority lists 104 further comprises a listing of one or more directory buckets 309 having a same bucket priority 310 and their respective bucket timestamp 311 for each time frame.

[0149] Then, the scanning each file 101 of the one or more users in the NAS system 120 based on the one or more priority lists 104 comprises determining, for each of the one or more directory buckets 309 in each of the priority lists 104, a respective weight based on the bucket priority 310 and based on the bucket timestamp 311. Next, each directory bucket 309 in the one or more priority lists 104 is selected based on the respective weight. Further, the selected bucket 309 is removed from the respective priority list 104, and the selected directory bucket 309 is scanned at the NAS system 120. Details regarding the weight for each directory bucket 309 are the same as for the embodiment of FIG. 1 and are not repeated here.

[0150] The scanning entity 100 of FIG. 5 is further configured to store the directory priority table 307. Additionally or alternatively, the scanning entity 100 is configured to store the one or more priority lists 104.

[0151] Further, the scanning entity 100 is configured to generate a scan result 105.

[0152] The advantages of the solutions of the scanning entity 100 of FIGS. 1 and 5 according to this disclosure may be summarized as follows:

[0153] • It provides with an efficient creation of priority-based scan lists balancing between known "interesting" file directories location at the NAS system and a full scan of changed files.

[0154] • The solutions enable a frequent scanning of "important" files providing more up to date information for the user.

[0155] • The scanning entity 100 is able to scan all the changed file directory locations including changes in unlikely locations.

[0156] • The solutions enable a reduction in both network bandwidth and compute resources used during the scan.

[0157] • The solutions are eventually consistent by design in an attempt to give highly consistent values for important files, and lower consistency for unimportant files.

[0158] FIG. 6 shows an exemplary embodiment of a method 600 for scanning a NAS system 120, the NAS system 120 comprising a plurality of file directories 101 of one or more users. The method 600 may be performed by the exemplary embodiments of the scanning entity 100 of FIG. 1 and FIG. 5 as disclosed above.

[0159] The method 600 comprises a step 601 of accessing the plurality of file directories 101 in the NAS system 120.

[0160] Then, the method 600 comprises a step 602 of determining one or more of the file directories

[0161] 102 that were changed in the NAS system 120 and determine a respective change timestamp

[0162] 103 for each of the one or more changed file directories 102. Further, in step 603, the method 600 comprises generating one or more priority lists 104 for the plurality of file directories 102, wherein each of the priority lists 104 comprises a listing of one or more file directories 102 having a same directory scan priority and the respective change timestamp 103.

[0163] The method 600 further comprises a step 604 of scanning 604 each file directory 101 of the plurality of file directories in the NAS system 120 using the one or more priority lists 104.

[0164] Further, in step 605, the method 600 comprises generating 605 a scan result.

[0165] The method 600 may further comprise actions according to the exemplary embodiments of the scanning entity 100 of FIG. 1 and FIG. 5. Hence, the method 600 achieves the same advantages as the scanning entity 100 disclosed above.

[0166] This disclosure further provides a computer program product comprising a program code for carrying out, when implemented on a processor, the method 600. The computer program may be included in a computer readable medium of the computer program product. The computer readable medium may comprise essentially any memory, such as a ROM (Read-Only Memory), a PROM (Programmable Read-Only Memory), a 15 EPROM (Erasable PROM), a Flash memory, an EEPROM (Electrically Erasable PROM), or a hard disk drive.

[0167] The present disclosure has been described in conjunction with various embodiments as examples as well as implementations. However, other variations can be understood and effected by those persons skilled in the art and practicing the claimed matter, from the studies of the drawings, this disclosure and the independent claims. In the claims as well as in the description the word "comprising" does not exclude other elements or steps and the indefinite article "a" or "an" does not exclude a plurality. A single element or other unit may fulfill the functions of several entities or items recited in the claims. The mere fact that certain measures are recited in the mutual different dependent claims does not indicate that a combination of these measures cannot be used in an advantageous implementation.

Claims

CLAIMS1. A scanning entity (100) for scanning a Network Attached Storage, NAS, system (120), the NAS system (120) comprising a plurality of file directories (101) of one or more users, and the scanning entity (100) being configured to: access the plurality of file directories (101) in the NAS system (120); determine one or more of the file directories (102) that were changed in the NAS system (120) and determine a respective change timestamp (103) for each of the one or more changed file directories; generate one or more priority lists (104) for the plurality of file directories (102), wherein each of the priority lists (104) comprises a listing of one or more file directories (102) having a same directory scan priority and their respective change timestamp (103); scan each file directory (101) of the plurality of file directories in the NAS system (120) using the one or more priority lists (104); and generate a scan result (105).

2. The scanning entity (100) according to claim 1, further configured to create a directory modification time database (512) by: initializing an empty database (512); performing an initial full scan of the NAS system (120); and for each changed file directory (102) found in the NAS system (120), recording the changed file (102) and a respective change timestamp (103) in the database (512).

3. The scanning entity (100) according to claim 2, wherein determining the one or more file directories (102) that were changed in the NAS system (120) and their respective change timestamps (103) comprises: performing a scan of each file directory (101) in the NAS system (120) at one or more time frames, wherein each time frame comprises a predefined value; determining whether one or more file directories (102) were changed within each time frame based on the scan of the NAS system (120) at the time frame and based on the directory modification time database (512); and for each time frame, assigning to each of the one or more changed file directories a respective change timestamp (103), and storing the respective timestamp (103) in the database (512).

4. The scanning entity (100) according to claim 1, wherein determining the one or more file directories (102) that were changed in the NAS system (120) and determining their respective change timestamps (103), comprises: receiving, from the NAS system (120) at one or more time frames, one or more notifications of changes in the one or more file directories (102), wherein each time frame comprises a predefined value; and for each time frame, assigning a change timestamp (103) to each of the one or more changed file directories (102).

5. The scanning entity (100) according to claim 3 or 4, wherein determining the one or more file directories (102) that were changed in the NAS system (120) and determining their respective change timestamps (103) further comprises: generating a directory group table (206), wherein the directory group table (206) comprises a listing of the determined one or more changed file directories (102) for each time frame, and their respective change timestamps (103).

6. The scanning entity (100) according to any one of claims 1 to 5, further configured to: generate a directory priority table (307) comprising a listing of the plurality of file directories (102) and a respective directory scan priority (308).

7. The scanning entity (100) according to any one of claims 1 to 6, further configured to: generate, for each time frame, one or more directory buckets (309) based on the directory priority table (307) and based on the directory group table (206); wherein each directory bucket (309) comprises a listing of one or more changed file directories(102) for each time frame of the directory group table (206) having a same directory scan priority (308), and their respective change timestamps (103); and wherein each directory bucket (309) has a bucket priority (310) and a bucket timestamp (3 H).

8. The scanning entity (100) according to any one of claims 1 to 7, wherein each bucket priority (310) corresponds to one directory scan priority (308).

9. The scanning entity (100) according to any one of claims 1 to 8, wherein the bucket timestamp (311) of each directory bucket (309) is a smallest change timestamp (103) of the one or more file directories (102) in the directory bucket (309), or a largest change timestamp (103) of the one or more file directories (102) in the directory bucket (309).

10. The scanning entity (100) according to any one of claims 1 to 9, wherein each of the priority lists (104) further comprises a listing of one or more directory buckets (309) having a same bucket priority (310) and their respective bucket timestamp (311) for each time frame.

11. The scanning entity (100) according to any one of claims 1 to 10, wherein scanning each file directory (101) of the one or more users in the NAS system (120) based on the one or more priority lists (104), comprises: for each of the one or more directory buckets (309) in each of the priority lists (104), determining a respective weight based on the bucket priority (310) and based on the bucket timestamp (311); selecting each directory bucket (309) in the one or more priority lists (104) based on the respective weight; and removing the selected bucket (309) form the respective priority list (104) and scanning the selected directory bucket (309).

12. The scanning entity (100) according to any one of claims 1 to 11, wherein the weight for each of the one or more directory buckets (309) is determined by calculating a weight function, the weight function comprising at least the bucket timestamp (311) and the bucket priority (310).

13. The scanning entity (100) according to any one of claims 1 to 12, further configured to: store the directory priority table (307); and / or store the one or more priority lists (104).

14. A method (600) for scanning a Network Attached Storage, NAS, system (120), the NAS system (120) comprising a plurality of file directories of one or more users, and the method comprising: accessing (601) the plurality of file directories (101) in the NAS system (120);determining (602) one or more of the file directories (102) that were changed in the NAS system (120) and determine a respective change timestamp (103) for each of the one or more changed file directories (102); generating (603) one or more priority lists (104) for the plurality of file directories (102), wherein each of the priority lists (104) comprises a listing of one or more file directories (102) having a same directory scan priority and the respective change timestamp (103); scanning (604) each file directory (101) of the plurality of file directories in the NAS system (120) using the one or more priority lists (104); and generating (605) a scan result.

15. A computer program product comprising a program code for carrying out, when implemented on a processor, the method (600) according to claim 14.

Citation Information

Patent Citations

  • Dynamic discovery of executing applications

    US20200076770A1

  • Fast algorithm to find file system difference for deduplication

    US20210064580A1

  • On the fly summarization of file walk data

    US7630994B1