title: Yii 2.0 advanced error on yii migrate during setup
body: <p>In following the steps listed <a href="http://www.yiiframework.com/doc-2.0/guide-tutorial-advanced-app.html" rel="nofollow">here</a> to set up the advanced application. I get the following error when using <code>yii migrate</code>. </p>
  
  <pre><code>Yii Migration Tool (based on Yii v2.0.2)
  Exception 'yii\base\InvalidConfigException' with message 'Unknown component ID: db'
  in /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/di/ServiceLocator.php:136
  Stack trace:
  #0 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/console/controllers/MigrateController.php(96): yii\
  di\ServiceLocator-&gt;get('db')
  #1 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/base/Controller.php(149): yii\console\controllers\M
  igrateController-&gt;beforeAction(Object(yii\base\InlineAction))
  #2 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/console/Controller.php(91): yii\base\Controller-&gt;ru
  nAction('', Array)
  #3 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/base/Module.php(455): yii\console\Controller-&gt;runAc
  tion('', Array)
  #4 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/console/Application.php(161): yii\base\Module-&gt;runA
  ction('migrate', Array)
  #5 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/console/Application.php(137): yii\console\Applicati
  on-&gt;runAction('migrate', Array)
  #6 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/base/Application.php(375): yii\console\Application-
  &gt;handleRequest(Object(yii\console\Request))
  #7 /home/randall_l_smith_2_gmail_com/ngcOne/vendor/yiisoft/yii2/yii(41): yii\base\Application-&gt;run()
  #8 {main}
  </code></pre>
  
  <p>This is my config file</p>
  
  <pre><code>&lt;?php
  return [
      'components' =&gt; [
          'db' =&gt; [
              'class' =&gt; 'yii\db\Connection',
              'dsn' =&gt; 'mysql:host=127.0.0.1;port=3306;dbname=ngcOne',
              'username' =&gt; 'root',
              'password' =&gt; '############',
              'charset' =&gt; 'utf8',
          ],
          'mailer' =&gt; [
              'class' =&gt; 'yii\swiftmailer\Mailer',
              'viewPath' =&gt; '@common/mail',
              // send all mails to a file by default. You have to set
              // 'useFileTransport' to false and configure a transport
              // for the mailer to send real emails.
              'useFileTransport' =&gt; true,
          ],
      ],
  ];
  </code></pre>
  
  <p>MySQL seems to be operating properly (Connected using remote navicat, and the web based phpmyadmin without issue). This is all set up on a LEMP stack.</p>
  
  <p>Anyone have any insight as to how to deal with this error?</p>