CDbException

CDbConnection failed to open the DB connection: SQLSTATE[HY000] [1129] Host '172.31.32.82' is blocked because of many connection errors; unblock with 'mysqladmin flush-hosts'

/var/www/framework/db/CDbConnection.php(382)

370                 throw new CDbException('CDbConnection.connectionString cannot be empty.');
371             try
372             {
373                 Yii::trace('Opening DB connection','system.db.CDbConnection');
374                 $this->_pdo=$this->createPdoInstance();
375                 $this->initConnection($this->_pdo);
376                 $this->_active=true;
377             }
378             catch(PDOException $e)
379             {
380                 if(YII_DEBUG)
381                 {
382                     throw new CDbException('CDbConnection failed to open the DB connection: '.
383                         $e->getMessage(),(int)$e->getCode(),$e->errorInfo);
384                 }
385                 else
386                 {
387                     Yii::log($e->getMessage(),CLogger::LEVEL_ERROR,'exception.CDbException');
388                     throw new CDbException('CDbConnection failed to open the DB connection.',(int)$e->getCode(),$e->errorInfo);
389                 }
390             }
391         }
392     }
393 
394     /**

Stack Trace

#7
+
 /var/www/html/SiteOfertas/views/site/especiais/blackfriday2020.php(20): CActiveRecord->findAll(array("condition" => "id_of_situacao = 1 and id_of_oferta IN (5065,5054,5055,5056,5061...", "order" => "id_of_oferta DESC"))
15     <?php $ofertas = OfOferta::model()->findAll(array(
16                 'condition' => 'id_of_situacao = 1 and id_of_oferta IN ('.  implode(',', array(
17                     5065, 5054, 5055, 5056, 5061, 5059, 5057, 5043, 5044, 5060, 5037, 5023, 5014, 4991, 4989, 4973, 4603
18                 )).')',
19                 'order' => 'id_of_oferta DESC'
20         ));
21 
22         shuffle($ofertas);
23         ?>
24 
25     
#12
+
 /var/www/html/SiteOfertas/controllers/SiteController.php(237): CController->render("especiais/blackfriday2020")
232     }
233     public function action8tentaculos(){
234         $this->render('especiais/8tentaculos');
235     }
236     public function actionblackfriday(){
237         $this->render('especiais/blackfriday2020');
238     }
239     public function actionblackfridayTeste(){
240         $this->render('especiais/blackfridayTeste');
241     }
242     public function actionvivamaiscomopolvo(){
#20
+
 /var/www/html/ofertas.php(92): CApplication->run()
87 //    'condition' => 'id_ofc_situacao = 1',
88 //    'order' => 'porcentagem DESC'
89 //    ));
90 //Yii::app()->user->setState('desconto', $modelOfc->porcentagem);
91 
92 $app->run();
2024-03-28 10:58:08 Apache/2.4.52 (Amazon) OpenSSL/1.0.2k-fips PHP/5.4.45 Yii Framework/1.1.15