0

I got an error like

error":"Unable to create directory

'/var/www/html/pub/media/tmp/catalog/product'.","errorcode" :0

While upload product images. I put 777 permission /var/www/html/pub/media folder. but i got the error. kindly help me.

1
  • Pls create manually folder structure at location pub/media/tmp/catalog/product and try again
    – Abdul
    Jan 2, 2017 at 7:49

2 Answers 2

0

Please check permission of media/catalog/products folder and try again.

3
  • Yes i checked. it also have 777 permission.
    – bala.skpm
    Jan 2, 2017 at 7:30
  • which php version you are using ?
    – Ashvini K
    Jan 2, 2017 at 7:41
  • i am using PHP 5.5.38. and magento 2.0.2 version
    – bala.skpm
    Jan 2, 2017 at 7:45
0

Your issue in ownership.

Your web user .. ( CentOS: apache and www-data ) does not have the ownership to create folder and files.

See http://devdocs.magento.com/guides/v2.0/install-gde/install/legacy-file-system-perms.html , how to apply ownership in magento2.

As you have using ,please check out http://devdocs.magento.com/guides/v2.0/install-gde/install/post-install-umask.html

https://github.com/magento/magento2/issues/2412

the 2.1 release candidate, and with 2.0.6+, if you need permissions for generated assets of 664 and 775

Little bad idea:

For a case, you can change file permission from Magento\Framework\Exception\FileSystemException\DriverInterface You need change WRITEABLE_DIRECTORY_MODE = 0770; to WRITEABLE_DIRECTORY_MODE = 0775;and WRITEABLE_FILE_MODE = 0660 to WRITEABLE_FILE_MODE = 0664.It is working for You.

1
  • I am following the instruction mentioned but not working
    – bala.skpm
    Jan 2, 2017 at 8:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.