COM, cache and multi-user environment

ImageMagickObject is a Windows COM+ interface to ImageMagick. COM+, Visual Basic, and Delphi users should post to this discussion group.
Post Reply
leww

COM, cache and multi-user environment

Post by leww »

We're using ImageMagick's COM interface on a Windows 2003 machine where it is called from classic ASP code (i.e. pre-.Net). There are multiple users uploading images, sometimes simultaneously. It's currently deployed using 6.2.8-Q8

Occasionally (but not consistently) IM COM will fail to open and process a file.

Convert returns the following errors (adjusted path and filename)

Code: Select all

convert: 445: unable to open cache `D:\InetPub\VirtualServers\Images\upload\filename.jpg': Permission denied: 
convert: 450: Application transferred too few scanlines `D:\InetPub\VirtualServers\Images\upload\filename.jpg':
The file is in fact valid and can be opened by IM Display on the console with no hesitation.

Given that at times, this and other files will process correctly I'm moderately confident that the TMP directories and the target directories have the appropriate permissions.

Is it possible that with the multiple ASP threads, that one picture's cache is corrupting anothers'? Or that there is some temporary filename collision problem?
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: COM, cache and multi-user environment

Post by magick »

Are you in a position to try the current release of ImageMagick, 6.4.2, and see if that fixes the problem?
leww

Re: COM, cache and multi-user environment

Post by leww »

I was hoping for a short term solution that would hold my users until I rolled out the server upgrade in September (which would have the latest IM build).
User avatar
magick
Site Admin
Posts: 11064
Joined: 2003-05-31T11:32:55-07:00

Re: COM, cache and multi-user environment

Post by magick »

The exception returned is due to a permission problem on the ImageMagick pixel cache on disk. Its a simple open() system call that fails when it should not. You could try adding -debug cache to your script command line and see if that provides additional information for analysis.
Post Reply