AWS Lambda with IM7
Posted: 2019-10-18T01:48:16-07:00
Hi,
I am using ImageMagick in a AWS Lambda to crop png to tiles with that command:
Everything is working so far, I just have issues with huge png (I have a 8mo file, 26 000*10 000 pixels)
I am getting the following error :
I pretty much already know why : Lambda have only 512mb space available on /tmp file, and /tmp is the only FS we get the access to.
My question is, can I remove the disk pixel cache and only use memory cache ? (I can get up to 3gb)
Time is not really an issue, I just want it to get done.
Thank you for your help.
I am using ImageMagick in a AWS Lambda to crop png to tiles with that command:
Code: Select all
/opt/bin/magick convert /tmp/1571383180912/1571383180912_300dpi.png -monitor -crop 512x512 -set filename:tile %[fx:page.x/512]_%[fx:page.y/512] +repage +adjoin "/tmp/1571383180912/1571383180912_300dpi/tile-300-%[filename:tile].png"
I am getting the following error :
Code: Select all
convert: unable to write pixel cache '/tmp/magick-24phDuETFQt7OM': No space left on device @ error/cache.c/WritePixelCachePixels/5823.
convert: no images defined `/tmp/1571383180912/1571383180912_300dpi/tile-300-%[filename:tile].png' @ error/convert.c/ConvertImageCommand/3300.
My question is, can I remove the disk pixel cache and only use memory cache ? (I can get up to 3gb)
Time is not really an issue, I just want it to get done.
Thank you for your help.