Describe the bug
After a file is deleted on a folder monitored by LogMonitor.exe, it keeps on getting attempted to be used by it unless the LogMonitor.exe process is stopped.
This causes a lot of reads if you delete files that you no longer need, like for example you're looking to only keep log files older than a month in storage.
To Reproduce
- Create a container that has the following LogMonitor.exe configuration:
{
"LogConfig": {
"sources": [
{
"directory": "C:\\my\\folder\\appserverlogs",
"filter": "*.txt",
"includeFileNames": true,
"includeSubdirectories": true,
"type": "File"
}
]
}
}
- Add multiple files into that folder
- Delete some of the files in that folder
- Open procmon.exe and monitor for the deleted files, you'll get the following entries, which would result in Cloud providers, like for example Azure, charge the customer with additional writes for every attempt of the deleted files to be read via a CreateFile Operation
-
Expected behavior
Deleted files from the monitored locations should stop being monitored if they no longer exist.
Screenshots
Screenshot provided of procmon.exe, a memory dump and a procmon.exe PML file are available to be sent to your team for analysis
Configuration
-Tool: Log Monitor
-Version: 2.0.0.0 or 2.0.0._LM_BUILDMIINNOVERSION
Additional context
NA