Integration Astra with InfluxDB
InfluxDB is an open-source time series database.
Install
Section titled “Install”Download latest version from
- Go to InfluxDB site: https://portal.influxdata.com/downloads/
- Choose latest version
- Choose your platform
- Launch commands from the instruction on the InfluxDB site
Find out more information on official site: https://docs.influxdata.com/influxdb/latest/
InfluxDB is an open-source time series database.
InfluxDB Configuration
Section titled “InfluxDB Configuration”Open the InfluxDB Admin interface at http://db-server:8086.
First, create a new bucket. A bucket serves as storage for all data received from Astra. You can find buckets in the left sidebar under the “Load Data” group. To create a new bucket:
- Click Create Bucket
- Set the bucket name, for example,
astra - Set data retention: in the Delete Data section, select Older than and choose 30 days or any other value you prefer.
The next step is to grant Astra access to the bucket. In the left sidebar under the Load Data group, open API Tokens:
- Click Generate API Token and choose Custom API Token.
- Set the token description as
astra - In the Bucket group, set Read and Write permissions for the
astrabucket. - Click Generate
Now, InfluxDB is configured and ready to receive data.
Astra Configuration
Section titled “Astra Configuration”Open Settings → General in the Astra Web Interface. Set options for InfluxDB configuration:
- Instance Name: by the default is
astrawill be used as bucket in the InfluxDB - InfluxDB Address: address of the InfluxDB:
http://db-server:8086 - InfluxDB Organization: your orgranization in the InfluxDB settings
- InfluxDB Token: paste your token generated on previous step
- Click “Apply & Restart”
InfluxDB data structure
Section titled “InfluxDB data structure”Stream
Section titled “Stream”Measurement: stream
Tags:
id- unique stream identifiername- stream name
Data:
active-trueif stream is active, orfalseif stream work on demand and inactiveonair-trueif active input works without errorssessions- uint, number of sessionsbitrate- uint, stream bitrate in KBit/ssc_error- uint, percent of scrambled TS-packetscc_error- uint, CC errors counterpes_error- uint, percent of invalid PES-packetssync_error- uint, HTTP/HLS sync errors
Adapter
Section titled “Adapter”Measurement: adapter
Tags:
id- unique adapter identifiername- adapter name
Data:
lock- boolean,trueif tuner has lock and able to receive datasignal- uint, approximate signal level in percentsignal_db- float, signal level in dBmsnr- uint, approximate signal to noise ratio in percentsnr_db- float, signal to noise ratio in dBber- uint, bit errors counterunc- uint, block errors counterbitrate- total bitrate in Kbit/s
System information
Section titled “System information”Measurement: sysinfo
Data:
la1- float, load average for 1 minutela5- float, load average for 5 minutesla15- float, load average for 15 minutesthreads- uint, number of the threadssys_cpu- uint, total CPU usage. Could be up to: 100 multiplied with the core numbers on all CPUsapp_cpu- uint, CPU usage by the process and all threadssys_mem- uint, total RAM usageapp_mem- uint, RAM usage by the process and all threadsapp_mem_kb- uint, RAM usage by the process and all threads in kilobytessys_uptime- uint, total system uptime in secondsapp_uptime- uint, process uptime in seconds