Hi Everyone, apologies if daft question!
I'm new to Magento and far from a developer but try and learn things as I go. My hosts have informed me I keep using up all of my disk space creating my new site on Magento2.When they've looked into it further they've found its mostly images that are clogging it up. When I look,a lot of my product images are being duplicated. Here comes the daft bit! I might have 20 products that are all using the same picture but the product is available in different sizes so I've chosen to make them as separate simple products. Can I not somehow get all 20 products to link and use the same pictures? My Magento is duplicating the pictures for every product. So for example, every product has 5 pictures, so instead of having 5 pictures being hosted, its duplicating them for each product and storing 50 pictures?
Should I hang my shame with embarrassment or am I not actually daft??
Thanks in advance.
Iain
Solved! Go to Solution.
I understand the problem you are facing !
But Its core functionality of magento. If one image(a.jpeg) have uploaded for some product(A). Again we upload the same image(a.jpg) for another product its uploaded (a_1.jpg). Its the default core functionality of magento
Hope it helps !
Glad to know that you have resolved your issue , Happy to help and keep helping
I understand the problem you are facing !
But Its core functionality of magento. If one image(a.jpeg) have uploaded for some product(A). Again we upload the same image(a.jpg) for another product its uploaded (a_1.jpg). Its the default core functionality of magento
Hope it helps !
Thanks so much Dave, just seemed weird as I keep running out of disk space but now I know its normal I can work around it.
Thanks again
Iain
Glad to know that you have resolved your issue , Happy to help and keep helping
Sorry to open this issue after long time, but I ran into same problem. Is there ANY way how to stop this magento functionality? We have approx 7K products online. Total size of the original images folder is approx 20GB. by duplicating same images over and over again we reached 180GB disk size. For example one particular image that I use for custom made product is coppied 231 times (custom-product_1, custom product_2 etc...), which consumed totally 175,7 MB of disk space. Image itfself is only 760 kB big.
Everytime I use some of my csv file for add/update, it creates fresh new sets of coppied images.
If there is any solution how to stop this, I'm all ears.
If I'm facing a similar issue, this is what I would do.
A- have a developer to patch the codebase and extend your Magento to make it NOT do that. And then freshly import all products images.
See https://magento.stackexchange.com/questions/226792/magento-2-2-product-images-duplicated
B- a work around:
1- I would gather info about the file names format for the images. Once that is confirmed.
2- Then I would go to the database and run a basic query on the catalog_product_entity_varchar table to replace and trim images names that has _x to their original image name assuming removing the _x is correct.
3- Then I would delete the images from the server.