|
@@ -42,7 +42,7 @@ class CmtsOctetsCommand extends BaseCmtsCommand
|
|
parent::execute($input, $output);
|
|
parent::execute($input, $output);
|
|
|
|
|
|
$key_cm_octets = "cm_octets_{$this->d_s}";
|
|
$key_cm_octets = "cm_octets_{$this->d_s}";
|
|
- $key_cmts_octets = "cmts_octets_{$this->d_s}";
|
|
|
|
|
|
+ //$key_cmts_octets = "cmts_octets_{$this->d_s}";
|
|
$saveHistoric = (int) $input->getOption('save-historic');
|
|
$saveHistoric = (int) $input->getOption('save-historic');
|
|
$cmtsDocs = (int) $input->getOption('cmts-docs');
|
|
$cmtsDocs = (int) $input->getOption('cmts-docs');
|
|
$inicio = microtime(true);
|
|
$inicio = microtime(true);
|
|
@@ -54,7 +54,7 @@ class CmtsOctetsCommand extends BaseCmtsCommand
|
|
$this->apiSNMP = $SNMP->$library();
|
|
$this->apiSNMP = $SNMP->$library();
|
|
|
|
|
|
$cmOctetsCached = $this->getData($key_cm_octets, true);
|
|
$cmOctetsCached = $this->getData($key_cm_octets, true);
|
|
- $cmtsOctetsCached = $this->getData($key_cmts_octets, true);
|
|
|
|
|
|
+ //$cmtsOctetsCached = $this->getData($key_cmts_octets, true);
|
|
|
|
|
|
$inBandTotal = $outBandTotal = $inAccTotal = $outAccTotal = 0;
|
|
$inBandTotal = $outBandTotal = $inAccTotal = $outAccTotal = 0;
|
|
|
|
|
|
@@ -63,10 +63,10 @@ class CmtsOctetsCommand extends BaseCmtsCommand
|
|
$cmOctetsCached = array();
|
|
$cmOctetsCached = array();
|
|
}
|
|
}
|
|
|
|
|
|
- if(empty($cmtsOctetsCached)) {
|
|
|
|
|
|
+ /* if(empty($cmtsOctetsCached)) {
|
|
$this->output->writeln("Se inicializa {$key_cmts_octets}.");
|
|
$this->output->writeln("Se inicializa {$key_cmts_octets}.");
|
|
$cmtsOctetsCached = array();
|
|
$cmtsOctetsCached = array();
|
|
- }
|
|
|
|
|
|
+ } */
|
|
|
|
|
|
switch($cmtsDocs) {
|
|
switch($cmtsDocs) {
|
|
|
|
|
|
@@ -170,8 +170,8 @@ class CmtsOctetsCommand extends BaseCmtsCommand
|
|
$consIn = number_format(($inAccTotal / $div),3);
|
|
$consIn = number_format(($inAccTotal / $div),3);
|
|
$consOut = number_format(($outAccTotal / $div),3);
|
|
$consOut = number_format(($outAccTotal / $div),3);
|
|
|
|
|
|
- $sendData["{$this->d_s}_inconsumption_cmts_x_cm"] = $consIn;
|
|
|
|
- $sendData["{$this->d_s}_outconsumption_cmts_x_cm"] = $consOut;
|
|
|
|
|
|
+ $sendData["{$this->d_s}_inconsumption_cmts_x_cm"] = "{$consIn}|g";
|
|
|
|
+ $sendData["{$this->d_s}_outconsumption_cmts_x_cm"] = "{$consOut}|g";
|
|
|
|
|
|
if($sendData && $saveHistoric) {
|
|
if($sendData && $saveHistoric) {
|
|
$t_start_script = microtime(true);
|
|
$t_start_script = microtime(true);
|