Answers.Body: <p>Your --db setting might be wrong. It's not civicrm_user:myuser, it should be myuser:mypass. Also on some systems &quot;localhost&quot; doesn't work and you need to use <code>127.0.0.1</code>, e.g.</p>
  <p><code>--db=&quot;mysql://mysql_user:mysql_password@127.0.0.1:3306/mydb&quot;</code></p>
  <p>But also you don't need --db unless you need to install civi in a separate database from drupal. It will guess your drupal database.</p>
  <p>Also you usually need to specify --cms-base-url, since otherwise it might think your website is literally <code>http://default</code>.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T14:08:45.657Z
Answers.Text: Hi Demerito, i try without --db initially but e received the same error, so next i try with --db parameter.
  my DB is ok and the web site works properly, so i don't understand why i have this issue :(
Answers.UserDisplayName: Claudio
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T14:12:17.633Z
Answers.Text: Did drupal install ok? I mean are you able to visit the drupal site and it works?
Answers.UserDisplayName: Demerit
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T14:38:20.787Z
Answers.Text: Yes web site work properly (it's a new installation of Drupal). any suggestion ?  thanks
Answers.UserDisplayName: Claudio
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T14:56:34.393Z
Answers.Text: Try 127.0.0.1 instead of localhost? - have updated answer.
Answers.UserDisplayName: Demerit
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T15:04:41.217Z
Answers.Text: Hi, i tried with --cms-base-url parameter but i received the same error.
  Now i tried with another Drupal installation on my local with Acquia Dev Desktop and now i have this error: 
  [Drupal\Core\Database\ConnectionNotDefinedException]       
    The specified database connection is not defined: default  
  
  thai is similar to the previous.
Answers.UserDisplayName: Claudio
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T15:09:45.323Z
Answers.Text: Where to use 127.0.0.1 instead "localhost" ?
Answers.UserDisplayName: Claudio
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T15:12:51.067Z
Answers.Text: Have updated answer to give full example for --db.
Answers.UserDisplayName: Demerit
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T15:29:46.367Z
Answers.Text: i tried with your suggestion but nothing. Same error. I try many many combination of installation string. :(
Answers.UserDisplayName: Claudio
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-12-02T13:11:54.560Z
Answers.LastActivityDate: 2020-12-02T15:12:27.987Z
Answers.LastEditDate: 2020-12-02T15:12:27.987Z
Answers.UserDisplayName: Demerit
Body: <p>i try to install civiCRM on my Drupal 9 local website.
  I use Mamp 5.5 on Mac.</p>
  <p>I follow all install information and now I'm hold on this situation:</p>
  <p>% cv core:install --db=&quot;mysql://civicrm_user:myuser@localhost:3306/mydb&quot; --lang=it_IT -vv</p>
  <pre><code>Box Requirements Checker
  ========================
  
  &gt; Using PHP 7.4.10
  &gt; PHP is using the following php.ini file:
    /usr/local/etc/php/7.4/php.ini
  
  &gt; Checking Box requirements:
    .....
  
                                                                                  
   [OK] Your system is ready to run the application.                              
                                             
    [PDOException]                                    
    SQLSTATE[HY000] [2002] No such file or directory  
                                                      
  
  Exception trace:
   () at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php:150
   PDO-&gt;__construct() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php:150
   Drupal\Core\Database\Driver\mysql\Connection::open() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Database.php:380
   Drupal\Core\Database\Database::openConnection() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Database.php:169
   Drupal\Core\Database\Database::getConnection() at n/a:n/a
   call_user_func_array() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php:79
   Drupal\Component\DependencyInjection\PhpArrayContainer-&gt;createService() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/Container.php:171
   Drupal\Component\DependencyInjection\Container-&gt;get() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php:212
   Drupal\Component\DependencyInjection\PhpArrayContainer-&gt;resolveServicesAndParameters() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php:62
   Drupal\Component\DependencyInjection\PhpArrayContainer-&gt;createService() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/Container.php:171
   Drupal\Component\DependencyInjection\Container-&gt;get() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/DrupalKernel.php:546
   Drupal\Core\DrupalKernel-&gt;getCachedContainerDefinition() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/DrupalKernel.php:891
   Drupal\Core\DrupalKernel-&gt;initializeContainer() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/DrupalKernel.php:470
   Drupal\Core\DrupalKernel-&gt;boot() at phar:///usr/local/bin/cv/src/CmsBootstrap.php:251
   Civi\Cv\CmsBootstrap-&gt;bootDrupal8() at n/a:n/a
   call_user_func() at phar:///usr/local/bin/cv/src/CmsBootstrap.php:139
   Civi\Cv\CmsBootstrap-&gt;bootCms() at phar:///usr/local/bin/cv/src/Util/BootTrait.php:130
   Civi\Cv\Command\CoreInstallCommand-&gt;_boot_cms_only() at phar:///usr/local/bin/cv/src/Util/SetupCommandTrait.php:54
   Civi\Cv\Command\CoreInstallCommand-&gt;bootSetupSubsystem() at phar:///usr/local/bin/cv/src/Command/CoreInstallCommand.php:56
   Civi\Cv\Command\CoreInstallCommand-&gt;execute() at phar:///usr/local/bin/cv/vendor/symfony/console/Command/Command.php:257
   Symfony\Component\Console\Command\Command-&gt;run() at phar:///usr/local/bin/cv/vendor/symfony/console/Application.php:850
   Symfony\Component\Console\Application-&gt;doRunCommand() at phar:///usr/local/bin/cv/vendor/symfony/console/Application.php:193
   Symfony\Component\Console\Application-&gt;doRun() at phar:///usr/local/bin/cv/src/Application.php:46
   Civi\Cv\Application-&gt;doRun() at phar:///usr/local/bin/cv/vendor/symfony/console/Application.php:124
   Symfony\Component\Console\Application-&gt;run() at phar:///usr/local/bin/cv/src/Application.php:15
   Civi\Cv\Application::main() at phar:///usr/local/bin/cv/bin/cv:27
   require() at /usr/local/bin/cv:14
  
  core:install [--settings-path [SETTINGS-PATH]] [--setup-path [SETUP-PATH]] [--src-path [SRC-PATH]] [--plugin-path [PLUGIN-PATH]] [--cms-base-url [CMS-BASE-URL]] [--lang [LANG]] [--comp [COMP]] [--ext [EXT]] [--db [DB]] [-m|--model [MODEL]] [-A|--abort] [-K|--keep] [-f|--force] [--debug-event [DEBUG-EVENT]] [--debug-model] [--level LEVEL] [-t|--test] [-U|--user USER]
  </code></pre>
  <p>any suggestion ???
  i'm very sad :((</p>
  <p>thanks a lot
  claudio.</p>
  
Tags: <drupal><drupal-9>
Title: No such file or directory when install civiCRM
ThreadText: # No such file or directory when install civiCRM
  
  (Asked by: username_0 on 2020-12-02)
  
  i try to install civiCRM on my Drupal 9 local website.
  I use Mamp 5.5 on Mac.
  
  I follow all install information and now I'm hold on this situation:
  
  % cv core:install --db="mysql://civicrm\_user:myuser@localhost:3306/mydb" --lang=it\_IT -vv
  
  ```
  Box Requirements Checker
  ========================
  
  > Using PHP 7.4.10
  > PHP is using the following php.ini file:
    /usr/local/etc/php/7.4/php.ini
  
  > Checking Box requirements:
    .....
  
                                                                                  
   [OK] Your system is ready to run the application.                              
                                             
    [PDOException]                                    
    SQLSTATE[HY000] [2002] No such file or directory  
                                                      
  
  Exception trace:
   () at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php:150
   PDO->__construct() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Driver/mysql/Connection.php:150
   Drupal\Core\Database\Driver\mysql\Connection::open() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Database.php:380
   Drupal\Core\Database\Database::openConnection() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/Database/Database.php:169
   Drupal\Core\Database\Database::getConnection() at n/a:n/a
   call_user_func_array() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php:79
   Drupal\Component\DependencyInjection\PhpArrayContainer->createService() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/Container.php:171
   Drupal\Component\DependencyInjection\Container->get() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php:212
   Drupal\Component\DependencyInjection\PhpArrayContainer->resolveServicesAndParameters() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/PhpArrayContainer.php:62
   Drupal\Component\DependencyInjection\PhpArrayContainer->createService() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Component/DependencyInjection/Container.php:171
   Drupal\Component\DependencyInjection\Container->get() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/DrupalKernel.php:546
   Drupal\Core\DrupalKernel->getCachedContainerDefinition() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/DrupalKernel.php:891
   Drupal\Core\DrupalKernel->initializeContainer() at /Users/cmazzarago/Local_Sites/FondazionePico/fondazione_pico/web/core/lib/Drupal/Core/DrupalKernel.php:470
   Drupal\Core\DrupalKernel->boot() at phar:///usr/local/bin/cv/src/CmsBootstrap.php:251
   Civi\Cv\CmsBootstrap->bootDrupal8() at n/a:n/a
   call_user_func() at phar:///usr/local/bin/cv/src/CmsBootstrap.php:139
   Civi\Cv\CmsBootstrap->bootCms() at phar:///usr/local/bin/cv/src/Util/BootTrait.php:130
   Civi\Cv\Command\CoreInstallCommand->_boot_cms_only() at phar:///usr/local/bin/cv/src/Util/SetupCommandTrait.php:54
   Civi\Cv\Command\CoreInstallCommand->bootSetupSubsystem() at phar:///usr/local/bin/cv/src/Command/CoreInstallCommand.php:56
   Civi\Cv\Command\CoreInstallCommand->execute() at phar:///usr/local/bin/cv/vendor/symfony/console/Command/Command.php:257
   Symfony\Component\Console\Command\Command->run() at phar:///usr/local/bin/cv/vendor/symfony/console/Application.php:850
   Symfony\Component\Console\Application->doRunCommand() at phar:///usr/local/bin/cv/vendor/symfony/console/Application.php:193
   Symfony\Component\Console\Application->doRun() at phar:///usr/local/bin/cv/src/Application.php:46
   Civi\Cv\Application->doRun() at phar:///usr/local/bin/cv/vendor/symfony/console/Application.php:124
   Symfony\Component\Console\Application->run() at phar:///usr/local/bin/cv/src/Application.php:15
   Civi\Cv\Application::main() at phar:///usr/local/bin/cv/bin/cv:27
   require() at /usr/local/bin/cv:14
  
  core:install [--settings-path [SETTINGS-PATH]] [--setup-path [SETUP-PATH]] [--src-path [SRC-PATH]] [--plugin-path [PLUGIN-PATH]] [--cms-base-url [CMS-BASE-URL]] [--lang [LANG]] [--comp [COMP]] [--ext [EXT]] [--db [DB]] [-m|--model [MODEL]] [-A|--abort] [-K|--keep] [-f|--force] [--debug-event [DEBUG-EVENT]] [--debug-model] [--level LEVEL] [-t|--test] [-U|--user USER]
  
  ```
  
  any suggestion ???
  i'm very sad :((
  
  thanks a lot
  username_0.
  
  **Tags:** drupal, drupal-9
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2020-12-02. Score: 1
  
  Your --db setting might be wrong. It's not civicrm\_user:myuser, it should be myuser:mypass. Also on some systems "localhost" doesn't work and you need to use `127.0.0.1`, e.g.
  
  `--db="mysql://mysql_user:mysql_password@127.0.0.1:3306/mydb"`
  
  But also you don't need --db unless you need to install civi in a separate database from drupal. It will guess your drupal database.
  
  Also you usually need to specify --cms-base-url, since otherwise it might think your website is literally `http://default`.
  
  > **Comments:**
  > **username_0**: Hi Demerito, i try without --db initially but e received the same error, so next i try with --db parameter. my DB is ok and the web site works properly, so i don't understand why i have this issue :(  
  > **username_1**: Did drupal install ok? I mean are you able to visit the drupal site and it works?  
  > **username_0**: Yes web site work properly (it's a new installation of Drupal). any suggestion ?  thanks  
  > **username_1**: Try 127.0.0.1 instead of localhost? - have updated answer.  
  > **username_0**: Hi, i tried with --cms-base-url parameter but i received the same error. Now i tried with another Drupal installation on my local with Acquia Dev Desktop and now i have this error:  [Drupal\Core\Database\ConnectionNotDefinedException]          The specified database connection is not defined: default    thai is similar to the previous.  
  > **username_0**: Where to use 127.0.0.1 instead "localhost" ?  
  > **username_1**: Have updated answer to give full example for --db.  
  > **username_0**: i tried with your suggestion but nothing. Same error. I try many many combination of installation string. :(  
  
  ---
  
  