I have been having problems with getting Magento2 installed on LAMP CentOS VPS.

I setup everything via terminal on a Mac, logged in as the web account user, so ownership should be fine.

I have installed composer, and that is how I have installed Magento.

I cloned it from here: git clone https://github.com/magento/magento2.git

Installed via composer: composer install

Updated via composer: composer update

Ran the installer via visiting the domain and running through each section, which went through fine.

On visiting the site (front end) i get lots of 404 errors on /pub/static/frontend/Magento/luma etc etc.

So i run the suggested permissions:

find . -type d -exec chmod 770 {} \; && find . -type f -exec chmod 660 {} \; && chmod u+x bin/magento

Which then give me this error: You don't have permission to access / on this server.


So i try different permissions:

find . -type d -exec chmod 755 {} \; && find . -type f -exec chmod 644 {} \;

Which then returns lots of 404 errors on /pub/static/frontend/Magento/luma etc etc again

Where am i going wrong?

I have scrapped and tried to reinstall around about 100 times. I've tried every tutorial, read every documentation i can find. Can anyone shed any light on this and why I am having so many issues?

Have i missed an important step of the installation or something?

  • 1
    Is there any content in /pub/static/frontend/Magento/luma? Try bin/magento setup:static-content:deploy Commented Feb 22, 2016 at 16:48

1 Answer 1


R.S is right, you should run and run

bin/magento setup:static-content:deploy

and try this

chmod -R 777 pub

from your magento root to make sure it has writing permissions. Magento should generate static files on every request when in developer mode, so it might be a problem with permissions.

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.