admin - Convenience command

This command gives you various system information for FIWARE Orion, Cygnus, Perseo. You can use these information for troubleshooting.

Common Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--help show help (default: true)

log

This command allows you to print or set logging level for FIWARE Orion.

ngsi admin [command options] log [options]

Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--level VALUE, -l VALUE log level
--logging, -L logging (default: false)
--pretty, -P pretty format (default: false)
--help show help (default: true)

Example

Request:

ngsi admin log
{"level":"DEBUG"}

Request:

ngsi admin log --level info

Trace

This command allows you to print, set or delete trace level for FIWARE Orion.

ngsi admin [common options] trace [options]

Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--level VALUE, -l VALUE log level
--set, -s set (default: false)
--delete, -d delete (default: false)
--logging, -L logging (default: false)
--help show help (default: true)

Example

Request:

ngsi admin trace
{"tracelevels":"empty"}

Request:

ngsi admin trace --level t1
ngsi admin trace --level t1-t2
ngsi admin trace --level t1-t2,t3-t4
ngsi admin trace --level 180-199

Request:

ngsi admin trace --delete
ngsi admin trace --delete --level t1
ngsi admin trace --delete --level t1-t2
ngsi admin trace --delete --level t1-t2,t3-t4

Semaphore

This command prints semaphore for FIWARE Orion.

ngsi admin [command options] semaphore [options]

Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--logging, -L logging (default: false)
--pretty, -P pretty format (default: false)
--help show help (default: true)

Example

Request:

ngsi admin semaphore --pretty
{
  "dbConnectionPool": {
    "status": "free"
  },
  "dbConnection": {
    "status": "free"
  },
  "request": {
    "status": "free"
  },
  "subCache": {
    "status": "free"
  },
  "transaction": {
    "status": "free"
  },
  "timeStat": {
    "status": "free"
  },
  "logMsg": {
    "status": "free"
  },
  "alarmMgr": {
    "status": "free"
  },
  "metricsMgr": {
    "status": "free"
  },
  "connectionContext": {
    "status": "free"
  },
  "connectionEndpoints": {
    "status": "free"
  }
}

Metrics

This command allows you to print, reset or delete metrics for FIWARE Orion, Cygnus.

ngsi admin [command options] metrics [options]

Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--delete, -d delete (default: false)
--reset, -r reset (default: false)
--logging, -L logging (default: false)
--pretty, -P pretty format (default: false)
--help show help (default: true)

Example

Request:

ngsi admin metrics --pretty
{
  "services": {
    "default-service": {
      "subservs": {
        "root-subserv": {
          "incomingTransactionResponseSize": 1734,
          "serviceTime": 0.000461688,
          "incomingTransactions": 16
        }
      },
      "sum": {
        "incomingTransactionResponseSize": 1734,
        "serviceTime": 0.000461688,
        "incomingTransactions": 16
      }
    }
  },
  "sum": {
    "subservs": {
      "root-subserv": {
        "incomingTransactionResponseSize": 1734,
        "serviceTime": 0.000461688,
        "incomingTransactions": 16
      }
    },
    "sum": {
      "incomingTransactionResponseSize": 1734,
      "serviceTime": 0.000461688,
      "incomingTransactions": 16
    }
  }
}

Request:

ngsi admin metrics --reset --pretty
{
  "services": {
    "default-service": {
      "subservs": {
        "root-subserv": {
          "incomingTransactionResponseSize": 482,
          "serviceTime": 0.000316,
          "incomingTransactions": 1
        }
      },
      "sum": {
        "incomingTransactionResponseSize": 482,
        "serviceTime": 0.000316,
        "incomingTransactions": 1
      }
    }
  },
  "sum": {
    "subservs": {
      "root-subserv": {
        "incomingTransactionResponseSize": 482,
        "serviceTime": 0.000316,
        "incomingTransactions": 1
      }
    },
    "sum": {
      "incomingTransactionResponseSize": 482,
      "serviceTime": 0.000316,
      "incomingTransactions": 1
    }
  }
}

Request:

ngsi admin metrics --delete

Statistics

This command allows you to print or delete statistics for FIWARE Orion, Cygnus.

ngsi admin [command options] statistics [options]

Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--delete, -d delete (default: false)
--logging, -L logging (default: false)
--pretty, -P pretty format (default: false)
--help show help (default: true)

Example

Request:

 ngsi admin statistics --pretty
{
  "uptime_in_secs": 156334,
  "measuring_interval_in_secs": 156334
}

Request:

ngsi admin statistics --delete

Cache statistics

This command allows you to print or delete cache statistics for FIWARE Orion.

ngsi admin [command options] cacheStatistics [options]

Options

Options Description
--host VALUE, -h VALUE broker or server host VALUE (required)
--delete, -d delete (default: false)
--logging, -L logging (default: false)
--pretty, -P pretty format (default: false)
--help show help (default: true)

Example

Request:

ngsi admin cacheStatistics --pretty
{
  "ids": "",
  "refresh": 2011,
  "inserts": 0,
  "removes": 0,
  "updates": 0,
  "items": 0
}

Request:

ngsi admin cacheStatistics --delete