Hello.
In the policy.xml file one can set the <policy domain="resource" name="time" value="3600"/>. Accoring to documentation(http://www.imagemagick.org/script/resources.php) this variable holds the number of seconds each IM process can take before it`s aborted. In our production system this was changed from nothing(i.e commented out) to "120" which resulted in numerous aborted jobs. We use a python wrapper for IM called Wand(http://docs.wand-py.org/en/latest/) I suspect the variable is actually interpreted as milliseconds and not seconds, as when we commented out the policy the problem disappeared. Can you confirm the variable is interpreted as seconds and not milliseonds. If so this might be a bug in the wrapper..
Regards Erik
[edit]
The problem was that IM aborted it`s constrctor
"python: time limit exceeded `' @ fatal/cache.c/GetImagePixelCache/2098."
It aborted after stalling for less then a second. I don`t have the exact time for the IM constrctor. But with fetching files over http and parsing some json most images where processed at around 0.4 seconds. This makes it quite plausible too belive that many files passed as long as they where processed in under 120 ms, but where aborted if they took longer. Most of these images where light, mostly JPEGs and PNGs.
[/edit]
Time limit variable
Time limit variable
Last edited by Eriken on 2014-10-01T06:22:32-07:00, edited 1 time in total.
Re: Time limit variable
The time resource in policy.xml is in seconds. We verified it against the source code in ImageMagick.
Re: Time limit variable
Thanks for the swift response. Is it plausible that the wrapper uses this variable directly and somehow warps the conversion to milliseconds?
Re: Time limit variable
What is your operating system and your IM version?
Re: Time limit variable
The server runs Ubuntu 12.04.2 LTS and has IM Version: 6.6.9-7.
The Python wrapper Wand, is version 0.3.7. Python 2.7.3.
See edit of first post for more info.
The Python wrapper Wand, is version 0.3.7. Python 2.7.3.
See edit of first post for more info.
Re: Time limit variable
That version of ImageMagick is more then 3 years old ('ancient'). Can you upgrade to the latest version and try again?
Re: Time limit variable
Might be due to availability og precise packages for 12.04 TLS, but thanks for the tips.