NTFSSecurity icon indicating copy to clipboard operation
NTFSSecurity copied to clipboard

High memory usage

Open MorNando opened this issue 7 years ago • 3 comments

I appear to have memory issues when combining get-childitem2 and get-ntfsaccess. It is holding over 2gb ram when running it against 22gb of data, 1,200 folders and 15,000 files. I tried exporting the data to csv first but it made no difference. Is there anything else I can do or is this a bug?

MorNando avatar Aug 15 '17 06:08 MorNando

Could you provide a gist with the code you are using?

TechnicallyJoe avatar Aug 22 '17 10:08 TechnicallyJoe

Get-childitem2 $path -recurse | get-ntfsaccess | export-csv $outputpath -notypeinformation -append

On experimenting with the above, the ram usage increases when exporting to csv instead of throwing it away. When I remove export-csv the ram stays low.

That is fine for small to medium sized file structures but not for large ones. The problem is that this module is mainly geared for the larger ones in order to overcome the 260 character max_path limit.

The issue is get-ntfsaccess command holding memory when outputting to a csv.

MorNando avatar Aug 23 '17 16:08 MorNando

To expand further, it rose to 2gb ram when running my script instead of throwing that data away in the csv.

MorNando avatar Aug 23 '17 16:08 MorNando