I've installed Magento 2.1 Community Edition through composer (there was just an alert about some utility). I use Ubuntu 16.04, PHP 5.6, Apache2, MYSQL.
After installing I went to the admin panel but got just -
Not Found
The requested URL /admin_admin was not found on this server.
Apache/2.4.18 (Ubuntu) Server at magento.support.loc Port 80
Site settings in apache
<Directory home/ivan/sites/magento>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
When I load my front page, I just see HTML markup and no one font or style loading. They are in not existing folders like
http://magento.loc/pub/static/version1499045285/frontend/Magento/luma/en_US/css/styles-l.css
There is no version1499045285 folder.
What i did wrong? Maybe i did not activate some Apache mods?
-
check in this url and that folder location magento.loc/pub/static/frontend/Magento/luma/en_US/css/…Emipro Technologies Pvt. Ltd.– Emipro Technologies Pvt. Ltd.2017年07月03日 13:34:29 +00:00Commented Jul 3, 2017 at 13:34
-
@EmiproTechnologiesPvt.Ltd. there is such path, yesBitrix24– Bitrix242017年07月03日 14:05:57 +00:00Commented Jul 3, 2017 at 14:05
-
yes i think. you are not activate mod_rewrite . enable apace rewrite and reinstallRama Chandran M– Rama Chandran M2017年07月03日 18:49:55 +00:00Commented Jul 3, 2017 at 18:49
-
@RamaChandran reistall magento? Or apache? How to test it? Maybe i can see if it's activated or nor first?Bitrix24– Bitrix242017年07月03日 19:24:03 +00:00Commented Jul 3, 2017 at 19:24
-
First enable Apache and reinstall the magento it will work :)Rama Chandran M– Rama Chandran M2017年07月03日 19:24:46 +00:00Commented Jul 3, 2017 at 19:24
2 Answers 2
1- Make sure mod_rewrite is enabled on the server.
2 -After installation if css is not loading then please run deploy command from the root of magento
php bin/magento setup:static-content:deploy
3- Set permission var pub/ static folder to 777
chmod -R 777 var pub/static
This issue because of AllowOverride All is not set and sudo a2enmod rewrite is not enable
<Directory home/ivan/sites/magento>
Options Indexes FollowSymLinks
AllowOverride All
Require all granted
</Directory>
Deploy:
php bin/magento setup:static-content:deploy
Permission set:
chmod -R 777 var pub/static
-
It's set. Rewrite mod enabled. Read the topic please.Bitrix24– Bitrix242017年07月06日 14:13:59 +00:00Commented Jul 6, 2017 at 14:13
-
I updated the answerRama Chandran M– Rama Chandran M2017年07月06日 14:29:17 +00:00Commented Jul 6, 2017 at 14:29