CDbException

CDbConnection failed to open the DB connection: SQLSTATE[08004] [1040] Too many connections

/home/coxixtul/domains/adswan.com/public_html/in/index.php(26)

14     (isset($_GET['r']) && $_GET['r'] == 'install/default') ||
15     (isset($_GET['r']) && $_GET['r'] == 'install/default/index') ||
16     (!file_exists(dirname(__FILE__) . '/protected/config/environment.php') && !isset($_GET['r'])) ||
17     (!file_exists(dirname(__FILE__) . '/protected/config/environment.php') && isset($_GET['r']) && strpos($_GET['r'], 'install/default') !== 0)
18 ) {
19     require_once (dirname(__FILE__) . '/protected/modules/install/install.php');
20 } else {
21     require_once ($yii);
22     //Set language
23     $app = Yii::createWebApplication($config);
24 
25     if (file_exists(dirname(__FILE__) . '/protected/config/environment.php'))
26         if (Yii::app()->db->createCommand("SHOW TABLES LIKE 'setting'")->query()->rowCount > 0) {
27             $language_params = SettingParam::model()->find('name=:name', array(':name' => 'LANG'));
28             if (!is_null($language_params)) {
29                 $current_language = $language_params->value;
30                 $list_language_items = Language::model()->findAll('lang=:lang', array(':lang' => $current_language));
31                 if (sizeof($list_language_items) > 0)
32                     Yii::app()->language = $current_language;
33                 else {
34                     $setting = SettingParam::model()->find("name = 'LANG'");
35                     $setting->value = Language::DEFAULT_LANGUAGE;
36                     $setting->save();
37                     Yii::app()->language = Language::DEFAULT_LANGUAGE;
38                 }

Stack Trace

#4
+
 /home/coxixtul/domains/adswan.com/public_html/in/index.php(26): CModule->__get("db")
21     require_once ($yii);
22     //Set language
23     $app = Yii::createWebApplication($config);
24 
25     if (file_exists(dirname(__FILE__) . '/protected/config/environment.php'))
26         if (Yii::app()->db->createCommand("SHOW TABLES LIKE 'setting'")->query()->rowCount > 0) {
27             $language_params = SettingParam::model()->find('name=:name', array(':name' => 'LANG'));
28             if (!is_null($language_params)) {
29                 $current_language = $language_params->value;
30                 $list_language_items = Language::model()->findAll('lang=:lang', array(':lang' => $current_language));
31                 if (sizeof($list_language_items) > 0)
2021-08-05 19:09:43 LiteSpeed Yii Framework/1.1.7