Recently I have migrated the magento-1 (ver: 22.214.171.124) data to magento-2 (Ver: ver: 2.1.2) fress version using data migration tool. And it working perfectly in our local computer (localhost).
I found an issue after upload it to server m2.hiddencamera.com.au that some product images not showing instead it showing blank image (http://m2.hiddencamera.com.au/hidden-cameras?cat=84). And this problem is for not generating the image cache in pub/media/catalog/product/cache/ folder.
But when I try to regenerate the image using php bin/magento catalog:image:resize it showing a warning;
Warning: imagecreatefromjpeg(): gd-jpeg, libjpeg: recoverable error: Premature end of JPEG file in /vendor/magento/framework/Image/Adapter/Gd2.php on line 65
However in the mean time before showing the Warning it generate some new images cache in the /pub/media/catalog/product/cache folder.
I have tried to show the new generated images after setup:upgrade, indexer:reindex, cache:clean, cache:flush But it not updating the image url for the new generated images cache.
Also I have contacted with the hosting support (siteground) but no luck.
N.B: I have checked after migrated the Magento1 data to Magento ver: 2.1.7 that it causing the same issue when upload to server, but working properly in localhost.
I don't know exactly where the problem is. Please help me to resolve the issue for regenerating the product images.