Please consider the following command for the imagemagick package:
sudo convert -resize 460x200 /path/to/test1.jpg /path/to/test2.jpg
Now test1.jpg
is a fairly large image (12.5MB), but not unheard of sizes, but the server I am working from only has 1G of memory (Amazon EC2 t2.micro if it helps)
No error is being thrown, and yet no test2.jpg
is being created. I have tested this with smaller images and it works fine. I would have thought 1G if memory would be plenty to manage a resize, but perhaps not?
What are my options, do I have to get more memory or am I missing something?
Any suggestions are very welcome!
Requested Edits
strace output shows: +++ killed by SIGKILL +++
along with alot of commands that look normal (opening /usr/share/local
and reading long strings, which I assume is image data)
free gives me:
total used free shared buffers cached
Mem: 1016292 278348 737944 6412 460 13356
-/+ buffers/cache: 264532 751760
Swap: 0 0 0
So it looks as if swap is not enabled, so I will look into creating a swapfile to see if this sorts my issues.
File gives me:
testprint10Mbv2.jpg: JPEG image data, EXIF standard
I would also paste the full /path/to/img but unfortunately it contains sensitive data (client email addresses etc)
sudo
in this command? – Charles Green Jan 22 '16 at 17:15uname -a
? – Charles Green Jan 22 '16 at 17:18convert
withmogrify
on a copy of your image. – Takkat Jan 22 '16 at 19:31-limit memory 64MiB
(32MiB is a bit too small probably. Default is 1.5GiB). And it should give you some descriptive output in case it fails. – dadexix86 Jan 25 '16 at 12:46strace
appended in front of the command, see what system calls are made, errors thrown. Let us know – Sergiy Kolodyazhnyy Jan 25 '16 at 21:04free
and alsofile /path/to/test1.jpg
– Elder Geek Jan 26 '16 at 00:48