从命令行错误安装magento


Instaling magento from command line errors

我遵循这个指南。

http://devdocs.magento.com/guides/v2.1/install-gde/install/cli/install-cli-install.html

我尝试运行web安装,但它总是卡住,所以现在我尝试这个

当我以root用户访问mysql

mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema |
| mysql              |
| performance_schema |
| sys                |
+--------------------+
4 rows in set (0,00 sec)

没有magento的表

所以我运行链接

中给出的命令
magento setup:install --base-url=http://127.0.0.1/magento2/ '
--db-host=localhost --db-name=magento --db-user=magento --db-password=magento '
--admin-firstname=Magento --admin-lastname=User --admin-email=user@example.com '
--admin-user=admin --admin-password=admin123 --language=en_US '
--currency=USD --timezone=America/Chicago --use-rewrites=1

但是我的不能运行magento,所以我使用./magento

root@vegan:/var/www/html/magento2/bin# ./magento setup:install --base-url=http://127.0.0.1/magento2/ --db-host=localhost --db-name=magento --db-user=magento --db-password=magento --admin-firstname=Magento --admin-lastname=User --admin-email=user@example.com --admin-user=admin --admin-password=admin123 --language=en_US --currency=USD --timezone=America/Chicago --use-rewrites=1
SQLSTATE[HY000] [1045] Access denied for user 'magento'@'localhost' (using password: YES)

  [InvalidArgumentException]   
  Parameter validation failed  

及其他绿色文字

setup:install [--backend-frontname="..."] [--key="..."] [--session-save="..."] [--definition-format="..."] [--db-host="..."]

[- db名称="…"][——db-user = "…"] [- db引擎= "……")(——db-password = "……"][——db-prefix = "…"][——db-model = "……")(——db-init-statements = "……"][s |——skip-db-validation](——http-cache-hosts = "……"][——基url = "…"][——语言= "……")(——时区= "……"][——货币= "…"][——use-rewrites = "……")——使用安全="……"][——base-url-secure = "…"](——use-secure-admin = "……"][——admin-use-security-key = "…"][- admin用户切换="…"][——管理密码= "…"][——admin-email = "……")(——admin-firstname = "……"][——admin-lastname = "…"][——cleanup-database][——sales-order-increment-prefix = "……")[——use-sample-data][——magento-init-params = "……"]

信息

--db-user
User name of the Magento database instance owner.
Default is root.

所以我使用我的mysql密码和管理员名。这次成功了,但是又出现了错误

root@vegan:/var/www/html/magento2/bin# ./magento setup:install --base-url=http://127.0.0.1/magento/ --db-host=localhost --db-name=magentodb --db-user=root --db-password= root --admin-user=admin --admin-password=admin123 --language=en_US --currency=USD --timezone=America/Chicago --cleanup-database help

  [RuntimeException]   
  Too many arguments.  

SO, i减少参数。还是同样的

root@vegan:/var/www/html/magento2/bin# ./magento setup:install --base-url=http://127.0.0.1/magento/ --db-host=localhost --db-name=magentodb --db-user=root --db-password= root 

  [RuntimeException]   
  Too many arguments. 

i can see

http://localhost/magento2/setup//landing-install

页面。我认为没有错误。我也可以运行安装程序,但它停留在%66 %67。昨天我完成了这个,但它没有添加到购物卡,今天我删除了所有PHP 5.6 7.0在我的电脑和重新安装。但是现在,它不能安装…

什么是理由?我从web下载magento并提取到www/html

目录

/var/www/html/magento2/bin

即使出现这种错误

root@vegan:/var/www/html/magento2/bin# ./magento setup:install admin-user="root"

  [RuntimeException]   
  Too many arguments.

by the way i create user and daabase before installation
    mysql -u root -p
    CREATE DATABASE magentodb;
    CREATE USER magento@localhost IDENTIFIED BY 'magento';
    GRANT ALL PRIVILEGES on magentodb.* to magento@localhost;
    FLUSH PRIVILEGES;
    exit
    mysql bu
    11-  service apache2 restart
    12-  service mysql restart

我删除了所有的php,重新安装了php5.6,它工作了