1

I have install and configured magento 2 in ubantu 18.04. Everything work fine but when i am run magento2 command using cli than every time it will display file permission issue in "cache_dir" and "generated" folder.

I am try to give permission using this link Permission solution

But no luck.

Sanjay Gohil
  • 2,200
  • 1
  • 14
  • 29

1 Answers1

0

umask feature is specially made of new files permission.

default umask in magento2 is 002
If you want to change it then just create a file name magento_umask and put your value in it.

For more information you can check
https://devdocs.magento.com/guides/v2.0/install-gde/install/post-install-umask.html

  • 1
    I am create one file "magento_umask" and put value 002 and store in root and after that i am deploy my project and same issue arrive. – Sanjay Gohil Dec 18 '18 at 08:51
  • make sure you have setuped magento user in correct way also the files ownership and group permissions are correct. and never run magento commands through sudo or root user. – satya prakash patel Dec 18 '18 at 09:05
  • 1
    I have run command 2 times using sudo(root), So if i am remove this magento 2 setup folder and make new one and install new setup and run command without sudo than it will resolve this issue ? – Sanjay Gohil Dec 18 '18 at 09:47
  • create one user for magento and run commands through magento user. https://devdocs.magento.com/guides/v2.1/install-gde/prereq/file-system-perms.html – satya prakash patel Dec 18 '18 at 10:20