Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Magento not generating images in cache for some stores

I'm using Magento 1.5 with 3 different stores (same products, though targetted at different audiences etc). For one of the stores (the second store that was added), the small_images, thumbnails etc are generated in the cache directory. For the others, the images are not generated (although the directory structure is, so the permissions are set correctly). Anybody know if this is a setting that is wrong in the other two stores?

like image 483
Frank Groeneveld Avatar asked Feb 25 '23 04:02

Frank Groeneveld


2 Answers

The issue here is that each time you clear your cache or add a new image, Magento wants to create/add directories as the "apache" user, which prevents it from writing the generated images upon loading a page.

If you run this from the root of your install each time you visit the different pages in Magento (cart, product detail page, main page), you should be ok. Other than that, I'm still looking for a fix:

chown -R correctuser:correctgroup media/*

That should do it.

like image 134
Barbagallo Avatar answered Mar 03 '23 03:03

Barbagallo


Set up the php memory limit to something like 256 MB ... it is because the server does not have enough memory to properly manage the whole cache rebuild (flush)

like image 42
Mugur Avatar answered Mar 03 '23 01:03

Mugur