Failed to open file for scanning

This article describes an issue which may occur when stressing (high load) MetaDefender ICAP Server on Windows OS.

Symptom

A lot of requests are blocked with reason "MetaDefender Core is overloaded" or "Failed to open file".

From MetaDefender ICAP Server log:

Copy

Cause

On Windows OS, the maximum number of files can be opened simultaneously is 512 by default. Anything exceeded will be blocked by Windows OS.

Reference: https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/setmaxstdio?view=msvc-170

Solution

Use new setting supported on MetaDefender ICAP Server called maxstdio to increase the limit (applicable to Windows only). Details: Configuration file

Type to search, ESC to discard
Type to search, ESC to discard
Type to search, ESC to discard