Magento on MAMP custom module install fails “Unknown database 'magento'”How do I create a simple 'Hello World' module in Magento?About database custom module in magentoMagento 2: system.xml in custom moduleMagento 2 : Custom Module not workingMagento 2 - Correct way of Module InstallationMagento 2 fail during installationMagento 2.1 Custom module relationshipMagento 2 : get customer groups custome moduleMagento 2 Installation fails at 27%Magento DHL Shipping Module fail PHP version

Why is C# in the D Major Scale?

What happens to matryoshka Mordenkainen's Magnificent Mansions?

How could a planet have most of its water in the atmosphere?

Why do money exchangers give different rates to different bills?

Was there ever a Kickstart that took advantage of 68020+ instructions that would work on an A2000?

To customize a predefined symbol with different colors

Is this homebrew life-stealing melee cantrip unbalanced?

Would glacier 'trees' be plausible?

What is the most remote airport from the center of the city it supposedly serves?

Type-check an expression

Moving the subject of the sentence into a dangling participle

A non-technological, repeating, phenomenon in the sky, holding its position in the sky for hours

Theorem won't go to multiple lines and is causing text to run off the page

Why is `abs()` implemented differently?

What actually is the vector of angular momentum?

What is a "listed natural gas appliance"?

Accidentally deleted the "/usr/share" folder

Missed the connecting flight, separate tickets on same airline - who is responsible?

Number of seconds in 6 weeks

Besides the up and down quark, what other quarks are present in daily matter around us?

Python password manager

How can I get a job without pushing my family's income into a higher tax bracket?

Identifying my late father's D&D stuff found in the attic

If prion is a protein. Why is it not disassembled by the digestive system?



Magento on MAMP custom module install fails “Unknown database 'magento'”


How do I create a simple 'Hello World' module in Magento?About database custom module in magentoMagento 2: system.xml in custom moduleMagento 2 : Custom Module not workingMagento 2 - Correct way of Module InstallationMagento 2 fail during installationMagento 2.1 Custom module relationshipMagento 2 : get customer groups custome moduleMagento 2 Installation fails at 27%Magento DHL Shipping Module fail PHP version






.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty height:90px;width:728px;box-sizing:border-box;








0















I have created a custom module, but when I go to run php bin/magento setup:upgrade it fails and returns SQLSTATE[HY000] [1049] Unknown database 'magento'.



I have tried other stackover flow solutions to no avail. And I have uninstalled and reinstalled magento instances.



enter image description here



/app/etc.php



<?php
return [
'backend' => [
'frontName' => 'admin'
],
'crypt' => [
'key' => 'e6e76a3bc072a8ccf6c12282b78db401'
],
'db' => [
'table_prefix' => '',
'connection' => [
'default' => [
'host' => 'localhost',
'dbname' => 'magento',
'username' => 'root',
'password' => 'root',
'active' => '1'
]
]
],
'resource' => [
'default_setup' => [
'connection' => 'default'
]
],
'x-frame-options' => 'SAMEORIGIN',
'MAGE_MODE' => 'default',
'session' => [
'save' => 'files'
],
'cache_types' => [
'config' => 1,
'layout' => 1,
'block_html' => 1,
'collections' => 1,
'reflection' => 1,
'db_ddl' => 1,
'compiled_config' => 1,
'eav' => 1,
'customer_notification' => 1,
'config_integration' => 1,
'config_integration_api' => 1,
'full_page' => 1,
'config_webservice' => 1,
'translate' => 1,
'vertex' => 1
],
'install' => [
'date' => 'Fri, 22 Mar 2019 20:36:14 +0000'
]
];









share|improve this question




























    0















    I have created a custom module, but when I go to run php bin/magento setup:upgrade it fails and returns SQLSTATE[HY000] [1049] Unknown database 'magento'.



    I have tried other stackover flow solutions to no avail. And I have uninstalled and reinstalled magento instances.



    enter image description here



    /app/etc.php



    <?php
    return [
    'backend' => [
    'frontName' => 'admin'
    ],
    'crypt' => [
    'key' => 'e6e76a3bc072a8ccf6c12282b78db401'
    ],
    'db' => [
    'table_prefix' => '',
    'connection' => [
    'default' => [
    'host' => 'localhost',
    'dbname' => 'magento',
    'username' => 'root',
    'password' => 'root',
    'active' => '1'
    ]
    ]
    ],
    'resource' => [
    'default_setup' => [
    'connection' => 'default'
    ]
    ],
    'x-frame-options' => 'SAMEORIGIN',
    'MAGE_MODE' => 'default',
    'session' => [
    'save' => 'files'
    ],
    'cache_types' => [
    'config' => 1,
    'layout' => 1,
    'block_html' => 1,
    'collections' => 1,
    'reflection' => 1,
    'db_ddl' => 1,
    'compiled_config' => 1,
    'eav' => 1,
    'customer_notification' => 1,
    'config_integration' => 1,
    'config_integration_api' => 1,
    'full_page' => 1,
    'config_webservice' => 1,
    'translate' => 1,
    'vertex' => 1
    ],
    'install' => [
    'date' => 'Fri, 22 Mar 2019 20:36:14 +0000'
    ]
    ];









    share|improve this question
























      0












      0








      0








      I have created a custom module, but when I go to run php bin/magento setup:upgrade it fails and returns SQLSTATE[HY000] [1049] Unknown database 'magento'.



      I have tried other stackover flow solutions to no avail. And I have uninstalled and reinstalled magento instances.



      enter image description here



      /app/etc.php



      <?php
      return [
      'backend' => [
      'frontName' => 'admin'
      ],
      'crypt' => [
      'key' => 'e6e76a3bc072a8ccf6c12282b78db401'
      ],
      'db' => [
      'table_prefix' => '',
      'connection' => [
      'default' => [
      'host' => 'localhost',
      'dbname' => 'magento',
      'username' => 'root',
      'password' => 'root',
      'active' => '1'
      ]
      ]
      ],
      'resource' => [
      'default_setup' => [
      'connection' => 'default'
      ]
      ],
      'x-frame-options' => 'SAMEORIGIN',
      'MAGE_MODE' => 'default',
      'session' => [
      'save' => 'files'
      ],
      'cache_types' => [
      'config' => 1,
      'layout' => 1,
      'block_html' => 1,
      'collections' => 1,
      'reflection' => 1,
      'db_ddl' => 1,
      'compiled_config' => 1,
      'eav' => 1,
      'customer_notification' => 1,
      'config_integration' => 1,
      'config_integration_api' => 1,
      'full_page' => 1,
      'config_webservice' => 1,
      'translate' => 1,
      'vertex' => 1
      ],
      'install' => [
      'date' => 'Fri, 22 Mar 2019 20:36:14 +0000'
      ]
      ];









      share|improve this question














      I have created a custom module, but when I go to run php bin/magento setup:upgrade it fails and returns SQLSTATE[HY000] [1049] Unknown database 'magento'.



      I have tried other stackover flow solutions to no avail. And I have uninstalled and reinstalled magento instances.



      enter image description here



      /app/etc.php



      <?php
      return [
      'backend' => [
      'frontName' => 'admin'
      ],
      'crypt' => [
      'key' => 'e6e76a3bc072a8ccf6c12282b78db401'
      ],
      'db' => [
      'table_prefix' => '',
      'connection' => [
      'default' => [
      'host' => 'localhost',
      'dbname' => 'magento',
      'username' => 'root',
      'password' => 'root',
      'active' => '1'
      ]
      ]
      ],
      'resource' => [
      'default_setup' => [
      'connection' => 'default'
      ]
      ],
      'x-frame-options' => 'SAMEORIGIN',
      'MAGE_MODE' => 'default',
      'session' => [
      'save' => 'files'
      ],
      'cache_types' => [
      'config' => 1,
      'layout' => 1,
      'block_html' => 1,
      'collections' => 1,
      'reflection' => 1,
      'db_ddl' => 1,
      'compiled_config' => 1,
      'eav' => 1,
      'customer_notification' => 1,
      'config_integration' => 1,
      'config_integration_api' => 1,
      'full_page' => 1,
      'config_webservice' => 1,
      'translate' => 1,
      'vertex' => 1
      ],
      'install' => [
      'date' => 'Fri, 22 Mar 2019 20:36:14 +0000'
      ]
      ];






      php magento magento2






      share|improve this question













      share|improve this question











      share|improve this question




      share|improve this question










      asked Mar 22 at 20:54









      NicholasByDesignNicholasByDesign

      411519




      411519






















          2 Answers
          2






          active

          oldest

          votes


















          1














          Did you get it working?



          From what I can see your .env is just referencing the wrong port number for mysql.



          Try this (change the host to localhost:8889):



          'default' => [
          'host' => 'localhost:8889',
          'dbname' => 'magento',
          'username' => 'root',
          'password' => 'root',
          'active' => '1'
          ]





          share|improve this answer






























            0














            I ended up calling the command this by explicitly calling the path to my version of PHP: /Applications/MAMP/bin/php/php7.2.1/bin/php bin/magento setup:upgrade






            share|improve this answer























              Your Answer






              StackExchange.ifUsing("editor", function ()
              StackExchange.using("externalEditor", function ()
              StackExchange.using("snippets", function ()
              StackExchange.snippets.init();
              );
              );
              , "code-snippets");

              StackExchange.ready(function()
              var channelOptions =
              tags: "".split(" "),
              id: "1"
              ;
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function()
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled)
              StackExchange.using("snippets", function()
              createEditor();
              );

              else
              createEditor();

              );

              function createEditor()
              StackExchange.prepareEditor(
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: true,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: 10,
              bindNavPrevention: true,
              postfix: "",
              imageUploader:
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              ,
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              );



              );













              draft saved

              draft discarded


















              StackExchange.ready(
              function ()
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55307636%2fmagento-on-mamp-custom-module-install-fails-unknown-database-magento%23new-answer', 'question_page');

              );

              Post as a guest















              Required, but never shown

























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              1














              Did you get it working?



              From what I can see your .env is just referencing the wrong port number for mysql.



              Try this (change the host to localhost:8889):



              'default' => [
              'host' => 'localhost:8889',
              'dbname' => 'magento',
              'username' => 'root',
              'password' => 'root',
              'active' => '1'
              ]





              share|improve this answer



























                1














                Did you get it working?



                From what I can see your .env is just referencing the wrong port number for mysql.



                Try this (change the host to localhost:8889):



                'default' => [
                'host' => 'localhost:8889',
                'dbname' => 'magento',
                'username' => 'root',
                'password' => 'root',
                'active' => '1'
                ]





                share|improve this answer

























                  1












                  1








                  1







                  Did you get it working?



                  From what I can see your .env is just referencing the wrong port number for mysql.



                  Try this (change the host to localhost:8889):



                  'default' => [
                  'host' => 'localhost:8889',
                  'dbname' => 'magento',
                  'username' => 'root',
                  'password' => 'root',
                  'active' => '1'
                  ]





                  share|improve this answer













                  Did you get it working?



                  From what I can see your .env is just referencing the wrong port number for mysql.



                  Try this (change the host to localhost:8889):



                  'default' => [
                  'host' => 'localhost:8889',
                  'dbname' => 'magento',
                  'username' => 'root',
                  'password' => 'root',
                  'active' => '1'
                  ]






                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered Mar 26 at 11:11









                  giolliano sulitgiolliano sulit

                  8271611




                  8271611























                      0














                      I ended up calling the command this by explicitly calling the path to my version of PHP: /Applications/MAMP/bin/php/php7.2.1/bin/php bin/magento setup:upgrade






                      share|improve this answer



























                        0














                        I ended up calling the command this by explicitly calling the path to my version of PHP: /Applications/MAMP/bin/php/php7.2.1/bin/php bin/magento setup:upgrade






                        share|improve this answer

























                          0












                          0








                          0







                          I ended up calling the command this by explicitly calling the path to my version of PHP: /Applications/MAMP/bin/php/php7.2.1/bin/php bin/magento setup:upgrade






                          share|improve this answer













                          I ended up calling the command this by explicitly calling the path to my version of PHP: /Applications/MAMP/bin/php/php7.2.1/bin/php bin/magento setup:upgrade







                          share|improve this answer












                          share|improve this answer



                          share|improve this answer










                          answered Mar 26 at 19:22









                          NicholasByDesignNicholasByDesign

                          411519




                          411519



























                              draft saved

                              draft discarded
















































                              Thanks for contributing an answer to Stack Overflow!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid


                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.

                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function ()
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55307636%2fmagento-on-mamp-custom-module-install-fails-unknown-database-magento%23new-answer', 'question_page');

                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Kamusi Yaliyomo Aina za kamusi | Muundo wa kamusi | Faida za kamusi | Dhima ya picha katika kamusi | Marejeo | Tazama pia | Viungo vya nje | UrambazajiKuhusu kamusiGo-SwahiliWiki-KamusiKamusi ya Kiswahili na Kiingerezakuihariri na kuongeza habari

                              SQL error code 1064 with creating Laravel foreign keysForeign key constraints: When to use ON UPDATE and ON DELETEDropping column with foreign key Laravel error: General error: 1025 Error on renameLaravel SQL Can't create tableLaravel Migration foreign key errorLaravel php artisan migrate:refresh giving a syntax errorSQLSTATE[42S01]: Base table or view already exists or Base table or view already exists: 1050 Tableerror in migrating laravel file to xampp serverSyntax error or access violation: 1064:syntax to use near 'unsigned not null, modelName varchar(191) not null, title varchar(191) not nLaravel cannot create new table field in mysqlLaravel 5.7:Last migration creates table but is not registered in the migration table

                              은진 송씨 목차 역사 본관 분파 인물 조선 왕실과의 인척 관계 집성촌 항렬자 인구 같이 보기 각주 둘러보기 메뉴은진 송씨세종실록 149권, 지리지 충청도 공주목 은진현