### Quick Start Akvorado Deployment Source: https://akvorado.net/docs/intro Use this command to quickly set up Akvorado with Docker Compose. Ensure you have Docker Engine v23 or later installed. ```bash mkdir akvorado cd akvorado curl -sL https://github.com/akvorado/akvorado/releases/latest/download/docker-compose-quickstart.tar.gz | tar zxvf - docker compose up --wait ``` -------------------------------- ### Start Akvorado Services Source: https://akvorado.net/docs/usage Demonstrates how to start different Akvorado services using their respective subcommands and configuration sources. The orchestrator requires a local YAML file, while other services fetch configuration from a URL. ```bash $ akvorado orchestrator /etc/akvorado/akvorado.yaml ``` ```bash $ akvorado inlet http://orchestrator:8080 ``` ```bash $ akvorado outlet http://orchestrator:8080 ``` ```bash $ akvorado console http://orchestrator:8080 ``` ```bash $ akvorado console http://orchestrator:8080#2 ``` -------------------------------- ### Install Go, Node.js, and PNPM on Debian Source: https://akvorado.net/docs/install Install necessary build tools for compiling Akvorado from source on Debian-based systems. PNPM is managed via Corepack. ```bash # apt install golang nodejs npm # go version go version go1.24.1 linux/amd64 # node --version v22.22.0 # corepack pnpm --version 10.16.1 ``` -------------------------------- ### API Response Example Source: https://akvorado.net/docs/configuration Example JSON output from the Akvorado API showing classified flow data, including exporter and interface details. ```json { "Bytes": 1500, "Dst1stAS": 64501, [...] "ExporterName": "dc3-edge1.example.com", "ExporterRegion": "europe", "ExporterRole": "edge", "ExporterSite": "dc3", "ExporterTenant": "acme", [...] "InIfBoundary": "external", "InIfConnectivity": "transit", "InIfDescription": "Transit: Tata", "InIfName": "Gi0/0/0/10", "InIfProvider": "tata", [...] } ``` -------------------------------- ### Build Akvorado from Source Source: https://akvorado.net/docs/install Execute the 'make' command to compile Akvorado from source after installing dependencies. This process includes formatting, linting, and building the executable. ```bash # make ▶ building golang.org/x/tools/cmd/goimports@latest… ▶ fetching node modules… ▶ formatting code… ▶ building github.com/mgechev/revive@latest… ▶ running lint… ▶ building google.golang.org/protobuf/cmd/protoc-gen-go@v1.28.0… ▶ compiling protocol buffers definition… ▶ building github.com/golang/mock/mockgen@v1.6.0… ▶ generate mocks for ClickHouse driver… ▶ generate ASN map… ▶ building github.com/mna/pigeon@v1.1.0… ▶ generate PEG parser for filters… ▶ generate list of selectable fields… ▶ building console frontend… vite v3.0.0 building for production... ✓ 2384 modules transformed. ../data/frontend/assets/akvorado.399701ee.svg 93.44 KiB ../data/frontend/index.html 0.54 KiB ../data/frontend/assets/index.26bdc6d7.css 68.11 KiB / gzip: 9.84 KiB ../data/frontend/assets/index.64c3c8d1.js 1273.41 KiB / gzip: 429.70 KiB ▶ building executable… ``` -------------------------------- ### Check Docker Version Source: https://akvorado.net/docs/intro Verify your Docker Engine version before proceeding with the Akvorado quick start. ```bash docker version -f {{ .Server.Version }} ``` -------------------------------- ### gNMI Provider Authentication Example Source: https://akvorado.net/docs/configuration Configure gNMI provider with authentication parameters, including username, password, and TLS settings. This example shows authentication for all subnets (::/0). ```yaml metadata: providers: type: gnmi authentication-parameters: ::/0: username: admin password: NokiaSrl1! skip-verify: true ``` -------------------------------- ### Configure cflowd Admin State and Cache on Nokia SR OS Source: https://akvorado.net/docs/operations Enable cflowd, set cache size, and retransmission timers. This is the initial setup for flow collection. ```bash /configure cflowd admin-state enable /configure cflowd cache-size 250000 /configure cflowd template-retransmit 60 /configure cflowd active-flow-timeout 10 /configure cflowd inactive-flow-timeout 10 /configure cflowd sample-profile 1 sample-rate 2000 ``` -------------------------------- ### Profile Akvorado CPU Usage Source: https://akvorado.net/docs/troubleshooting Use the Go profiler (`pprof`) to collect a CPU profile for an Akvorado service. Ensure you have a Go installation and the service's IP address. ```bash $ go tool pprof http://240.0.4.8:8080/debug/pprof/profile ``` -------------------------------- ### Pull and Run Akvorado Docker Image Source: https://akvorado.net/docs/install Use these commands to pull the latest Akvorado Docker image and run it to view help information. Ensure Docker is installed and running. ```bash # docker pull quay.io/akvorado/akvorado:latest # docker run --rm quay.io/akvorado/akvorado:latest help ``` -------------------------------- ### Configure Akvorado Console Widgets and Options Source: https://akvorado.net/docs/configuration Example configuration for the Akvorado console, specifying homepage widgets and default visualization options. This sets which data points are displayed on the homepage and how visualizations are rendered by default. ```yaml console: homepage-top-widgets: [src-as, src-country, etype] default-visualize-options: start: 1 day ago end: now filter: InIfBoundary = external dimensions: - ExporterName ``` -------------------------------- ### Configure Nginx for Akvorado URL Prefix Source: https://akvorado.net/docs/configuration Example Nginx configuration to handle URL prefixing for the Akvorado console. Ensure the proxy_pass directive has a trailing slash to strip the prefix correctly. ```nginx location /akvorado/ { proxy_pass http://127.0.0.1:8081/; # trailing slash strips the prefix } ``` -------------------------------- ### Configure Akvorado Authentication Headers and Defaults Source: https://akvorado.net/docs/configuration Example configuration for Akvorado's authentication, mapping incoming headers to user identity fields and defining default user information. It also shows how to set templated avatar and logout URLs. ```yaml auth: headers: login: Remote-User name: Remote-Name email: Remote-Email logout-url: X-Logout-URL default-user: login: default name: Default User avatar-url: "https://avatars.githubusercontent.com/{{ .Login }}?s=80" logout-url: "{{ if .LogoutURL }}{{ .LogoutURL }}{{ else }}/logout{{ end }}" ``` -------------------------------- ### Configure gRPC Admin State and Unsecure Connections on Nokia SR OS Source: https://akvorado.net/docs/operations Enable gRPC and allow unsecure connections for initial setup. This is a prerequisite for using gNMI or other gRPC services. ```bash /configure system grpc admin-state enable /configure system grpc allow-unsecure-connection ``` -------------------------------- ### SNMPv2 Metadata Configuration Source: https://akvorado.net/docs/configuration Configure the SNMP provider with SNMPv2 communities for metadata retrieval. This example shows how to specify multiple communities to try in order. ```yaml metadata: workers: 10 providers: - type: snmp credentials: ::/0: communities: - private - "@private" ``` -------------------------------- ### Update Flows Table Schema Example Source: https://akvorado.net/docs/operations This is an example of the updated 'ORDER BY' directive and primary key for the flows table. Ensure 'TimeReceived' is replaced with 'toStartOfFiveMinutes(TimeReceived)' for both. ```sql MergeTree PARTITION BY toYYYYMMDDhhmmss(toStartOfInterval(TimeReceived, toIntervalSecond(25920))) PRIMARY KEY (toStartOfFiveMinutes(TimeReceived)) ORDER BY (toStartOfFiveMinutes(TimeReceived), ExporterAddress, InIfName, OutIfName) TTL TimeReceived + toIntervalSecond(1296000) SETTINGS index_granularity = 8192, ttl_only_drop_parts = 1 ``` -------------------------------- ### Profile Akvorado Memory Usage Source: https://akvorado.net/docs/troubleshooting Use the Go profiler (`pprof`) to collect a memory profile (heap) for an Akvorado service. Ensure you have a Go installation and the service's IP address. ```bash $ go tool pprof http://240.0.4.8:8080/debug/pprof/heap ``` -------------------------------- ### Configure gRPC User and Authorization Profiles on Nokia SR OS Source: https://akvorado.net/docs/operations Set up a local user for gRPC access and define authorization profiles for different gRPC operations (get, set, subscribe). This controls what the user can do via gRPC. ```bash /configure system security user-params local-user user "akvorado" access grpc true /configure system security user-params local-user user "akvorado" console member ["grpc_ro"] /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnmi-get permit /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnmi-set deny /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnmi-subscribe permit /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnoi-file-get deny /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnoi-file-transfertoremote deny /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnoi-file-put deny /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnoi-file-stat deny /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization gnoi-file-remove deny /configure system security aaa local-profiles profile "grpc_ro" grpc rpc-authorization md-cli-session deny ``` -------------------------------- ### SNMPv3 Metadata Configuration Source: https://akvorado.net/docs/configuration Configure the SNMP provider with SNMPv3 credentials for metadata retrieval. This example includes user name, authentication, and privacy protocols and passphrases. ```yaml metadata: workers: 10 providers: - type: snmp credentials: ::/0: user-name: monitoring authentication-protocol: SHA authentication-passphrase: "d$rkSec" privacy-protocol: AES192 privacy-passphrase: "Cl0se" ``` -------------------------------- ### Static Provider with Remote Exporter Source Source: https://akvorado.net/docs/configuration Configure the static provider to fetch exporter data from a remote URL. This example shows fetching a JSON file and transforming its content to define exporters. It specifies the URL, refresh interval, and a jq transformation to extract exporter data. ```yaml metadata: providers: type: static exporter-sources: gostatic: url: http://gostatic:8043/my-exporters.json interval: 10m transform: .exporters[] ``` -------------------------------- ### Configure BMP Admin State and Station on Nokia SR OS Source: https://akvorado.net/docs/operations Enable BMP globally and configure a BMP station with description, stats reporting interval, local address, and remote station details. This sets up the BMP connection. ```bash /configure bmp admin-state enable /configure bmp station "akvorado" admin-state enable /configure bmp station "akvorado" description "akvorado.example.net" /configure bmp station "akvorado" stats-report-interval 300 /configure bmp station "akvorado" connection local-address 192.0.2.42 /configure bmp station "akvorado" connection station-address ip-address 192.0.2.1 /configure bmp station "akvorado" connection station-address port 10179 /configure bmp station "akvorado" family ipv4 true /configure bmp station "akvorado" family ipv6 true ``` -------------------------------- ### Default ClickHouse Resolutions Source: https://akvorado.net/docs/configuration Defines the default data retention intervals and TTLs for ClickHouse data resolutions. Use this as a starting point for custom configurations. ```yaml resolutions: - interval: 0 ttl: 360h # 15 days - interval: 1m ttl: 168h # 1 week - interval: 5m ttl: 2160h # 3 months - interval: 1h ttl: 8760h # 1 year ``` -------------------------------- ### Configure Arista SNMP Source: https://akvorado.net/docs/operations Set up SNMP on Arista devices. This example shows basic SNMP community string configuration with read-only access and VRF configuration. ```arista-eos snmp-server community ro snmp-server vrf VRF-MANAGEMENT ``` -------------------------------- ### Get Docker Service IP Address Source: https://akvorado.net/docs/troubleshooting Use `docker inspect` to retrieve the IP address of a running Akvorado service (inlet or outlet) within a Docker environment. ```bash $ docker inspect -f '{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}' akvorado-akvorado-inlet-1 240.0.4.8 $ docker inspect -f '{{range.NetworkSettings.Networks}}{{.IPAddress}}{{end}}' akvorado-akvorado-outlet-1 240.0.4.9 ``` -------------------------------- ### Configure Demo Exporter Service Source: https://akvorado.net/docs/configuration Sets up SNMP, BMP, and flow generation parameters for the demo exporter service. All fields in snmp are mandatory. In bmp, aspath is mandatory but communities are optional. All fields in flows are mandatory. ```yaml snmp: name: exporter1.example.com interfaces: 10: "Transit: Telia" 11: "IX: AMSIX" 20: "core" 21: "core" listen: :161mp: target: 127.0.0.1:10179 routes: - prefixes: 192.0.2.0/24,2a01:db8:cafe:1::/64 aspath: 64501 communities: 65401:10,65401:12 flows: samplingrate: 50000 target: 127.0.0.1:2055 flows: - per-second: 0.2 in-if-index: 10 out-if-index: 20 peak-hour: 16h multiplier: 3 src-port: 0 dst-port: 80 protocol: tcp size: 1300 dst-net: 192.0.2.0/24 dst-as: 64501 src-net: 198.38.120.0/23 src-as: 2906 ``` -------------------------------- ### Override Service Ports with !override in Docker Compose Source: https://akvorado.net/docs/operations The `!override` tag enables overriding existing configurations, such as service ports. This example shows how to override the ports for the 'traefik' service. ```yaml services: traefik: ports: !override - 127.0.0.1:8080:8080/tcp - 80:8081/tcp ``` -------------------------------- ### Configure Juniper sFlow Source: https://akvorado.net/docs/operations Enable sFlow on Juniper QFX devices to send traffic samples to Akvorado. Configure agent ID, polling interval, sample rate, and collector details. ```juniper-configuration protocols { sflow { agent-id 203.0.113.4; polling-interval 5; sample-rate ingress 8192; source-ip 203.0.113.4; collector 192.0.2.1 { udp-port 6343; } interfaces et-0/0/13.0; } } ``` -------------------------------- ### Reset Networks Configuration in Docker Compose Source: https://akvorado.net/docs/operations This snippet demonstrates how to completely reset the networks configuration using `!reset {}` in a `docker/docker-compose-local.yml` file, effectively disabling default network setups. ```yaml networks: !reset {} ``` -------------------------------- ### Enable SNMP Source: https://akvorado.net/docs/operations Configure SNMP community strings and allow SNMP access from the Akvorado IP address. ```cisco snmp-server community RO IPv4 snmp-server ifindex persist control-plane management-plane inband interface all allow SNMP peer address ipv4 ``` -------------------------------- ### Custom IP Dictionary CSV Format Source: https://akvorado.net/docs/configuration Example CSV format for the custom IP dictionary. The 'addr' column contains IP addresses and the 'role' column contains the associated role. ```csv addr,role 2001:db8::1,ExampleRole ``` -------------------------------- ### Configure Interface Sampling for cflowd on Nokia SR OS Source: https://akvorado.net/docs/operations Configure sampling on individual interfaces for unicast traffic. Specify the direction and sample profile to be used. ```bash /configure service ies "internet" interface "if1/1/c1/1:0" cflowd-parameters sampling unicast type interface /configure service ies "internet" interface "if1/1/c1/1:0" cflowd-parameters sampling unicast direction ingress-only /configure service ies "internet" interface "if1/1/c1/1:0" cflowd-parameters sampling unicast sample-profile 1 ``` -------------------------------- ### Configure Juniper Inline Monitoring (IPFIX) Source: https://akvorado.net/docs/operations Set up inline monitoring on Juniper devices to send IPFIX data to Akvorado. This method decodes sampled packets directly on the device. ```juniper-configuration services { inline-monitoring { template im-template { template-refresh-rate 30; option-template-refresh-rate 30; primary-data-record-fields { cpid-forwarding-exception-code; egress-interface-snmp-id; ingress-interface-snmp-id; direction; datalink-frame-size; } } instance im-instance { template-name im-template { maximum-clip-length 126; } collector akvorado { source-address 203.0.113.2; destination-address 192.0.2.1; destination-port 2055; sampling-rate 1024; } } } } firewall { family inet { filter monitoring { term 1 { then { inline-monitoring-instance im-instance; accept; } } } } family inet6 { filter monitoring { term 1 { then { inline-monitoring-instance im-instance; accept; } } } } } groups { sampling { interfaces { <*> { unit <*> { family inet { filter { input monitoring; } } family inet6 { filter { input monitoring; } } } } } } } ``` ```juniper-configuration interfaces { xe-0/0/0.0 { description "Transit: Cogent AS179 [3-10109101]"; apply-groups [ sampling ]; } } ``` -------------------------------- ### Retrieve Flows Table Engine Full Definition Source: https://akvorado.net/docs/operations Execute this SQL command to get the current 'engine_full' definition of the flows table. This information is needed to recreate the table with the updated schema. ```sql SELECT engine_full FROM system.tables WHERE (database = currentDatabase()) AND (`table` = 'flows') FORMAT TSVRaw ``` -------------------------------- ### Configure cflowd Collector on Nokia SR OS Source: https://akvorado.net/docs/operations Configure a cflowd collector with IP address, port, description, router instance, and version. Ensure the collector is enabled. ```bash /configure cflowd collector 192.0.2.1 port 2055 admin-state enable /configure cflowd collector 192.0.2.1 port 2055 description "akvorado.example.net" /configure cflowd collector 192.0.2.1 port 2055 router-instance "Base" /configure cflowd collector 192.0.2.1 port 2055 version 10 ``` -------------------------------- ### Cisco IOS-XE Interface NetFlow Configuration Source: https://akvorado.net/docs/operations Applies the configured NetFlow monitors and samplers to specific interfaces for both IPv4 and IPv6 traffic. Ensure the interface names and monitor names match your setup. ```cisco-ios-xe interface GigabitEthernet0/0/3 ip flow monitor AkvoradoMonitor sampler random1in100 input ip flow monitor AkvoradoMonitor sampler random1in100 output ipv6 flow monitor AkvoradoMonitor-IPV6 sampler random1in100 input ipv6 flow monitor AkvoradoMonitor-IPV6 sampler random1in100 output ! ``` -------------------------------- ### Check Akvorado Outlet Metrics Source: https://akvorado.net/docs/troubleshooting Use this command to retrieve key metrics from the Akvorado outlet, such as received and forwarded flows. This helps in identifying if data is being processed correctly. ```bash $ curl -s http://127.0.0.1:8080/api/v0/outlet/metrics | grep -P 'akvorado_outlet_core_(received|forwarded)' # HELP akvorado_outlet_core_forwarded_flows_total Number of flows forwarded to Kafka. # TYPE akvorado_outlet_core_forwarded_flows_total counter akvorado_outlet_core_forwarded_flows_total{exporter="241.107.1.12"} 182512 akvorado_outlet_core_forwarded_flows_total{exporter="241.107.1.13"} 182366 akvorado_outlet_core_forwarded_flows_total{exporter="241.107.1.14"} 182278 akvorado_outlet_core_forwarded_flows_total{exporter="241.107.1.15"} 182900 # HELP akvorado_outlet_core_received_flows_total Number of incoming flows. # TYPE akvorado_outlet_core_received_flows_total counter akvorado_outlet_core_received_flows_total{exporter="241.107.1.12"} 182512 akvorado_outlet_core_received_flows_total{exporter="241.107.1.13"} 182366 akvorado_outlet_core_received_flows_total{exporter="241.107.1.14"} 182278 akvorado_outlet_core_received_flows_total{exporter="241.107.1.15"} 182900 # HELP akvorado_outlet_core_received_raw_flows_total Number of incoming raw flows (proto). # TYPE akvorado_outlet_core_received_raw_flows_total counter akvorado_outlet_core_received_raw_flows_total 45812 ``` -------------------------------- ### Configure Juniper BMP Source: https://akvorado.net/docs/operations Enable BMP on Juniper routers to send AdjRIB-in information to Akvorado. Configure connection details and monitoring options. ```juniper-configuration routing-options { bmp { connection-mode active; station-address 203.0.113.1; station-port 10179; station collector; hold-down 30 flaps 10 period 30; route-monitoring post-policy; monitor enable; } } ``` -------------------------------- ### Override and Add Data-Skipping Indexes Source: https://akvorado.net/docs/configuration Configure data-skipping indexes for the main flows table. This example overrides the false-positive probability for SrcAddr and adds a new index for SrcNetName, while also removing the default index for DstAddr. ```yaml schema: # Override the FPP for SrcAddr and add an index for a custom column. indexes: SrcAddr: bloom(0.01) SrcNetName: bloom(0.001) # Remove the default index for DstAddr. no-indexes: - DstAddr ``` -------------------------------- ### Recreate Kafka Container Source: https://akvorado.net/docs/changelog Instructions to recreate the Kafka container when upgrading to Apache Kafka 4.1 with KRaft mode. ```bash # docker compose down --remove-orphans # docker compose rm --volumes kafka # docker volume rm akvorado_akvorado-kafka # docker compose pull # docker compose up -d ``` -------------------------------- ### Add Static Route for Akvorado Reachability Source: https://akvorado.net/docs/operations Configure a static route to ensure reachability to the Akvorado collector if the default route is insufficient. ```juniper routing-options { static { route 192.0.2.1/32 next-table internet.inet.0; } } ``` -------------------------------- ### Configure SQLite Database Source: https://akvorado.net/docs/configuration Sets the database driver to SQLite and specifies the path for the database file. ```yaml database: driver: sqlite dsn: /var/lib/akvorado/console.sqlite ``` -------------------------------- ### Validate Akvorado Configuration Source: https://akvorado.net/docs/intro Check your Akvorado configuration file for syntax errors and validate its structure. This command also dumps the full configuration with default values. ```bash docker compose run --rm --no-deps akvorado-orchestrator orchestrator --check --dump /etc/akvorado/akvorado.yaml ``` -------------------------------- ### Enable NetFlow on Interface Source: https://akvorado.net/docs/operations Apply the configured NetFlow monitor and sampler to an interface for ingress traffic. ```cisco interface Bundle-Ether4000 flow ipv4 monitor monitor1 sampler sampler1 ingress flow ipv6 monitor monitor2 sampler sampler1 ingress ! ``` -------------------------------- ### Create New Flows Table Source: https://akvorado.net/docs/operations This SQL command creates the new 'flows' table, using 'flows_old' as a template and specifying the engine definition. Paste the prepared engine definition after 'ENGINE = '. ```sql CREATE TABLE flows AS flows_old ENGINE = ``` -------------------------------- ### Configure Apply-Groups for cflowd Sampling on Nokia SR OS Source: https://akvorado.net/docs/operations Apply cflowd sampling configurations to a group of interfaces using apply-groups. This allows for centralized management of sampling settings. ```bash /configure groups group "peering" service ies "internet" interface "" cflowd-parameters sampling unicast type interface /configure groups group "peering" service ies "internet" interface "" cflowd-parameters sampling unicast direction ingress-only /configure groups group "peering" service ies "internet" interface "" cflowd-parameters sampling unicast sample-profile 1 /configure service ies "internet" interface "if1/1/c1/1:0" apply-groups ["peering"] ``` -------------------------------- ### Configure Kafka Topic Settings Source: https://akvorado.net/docs/configuration Use this to define Kafka topic settings, including partition count, replication factor, and retention policies. Ensure `config-entries-strict-sync` is set to `true` to maintain configuration consistency. ```yaml kafka: topic: test-topic topic-configuration: num-partitions: 1 replication-factor: 1 config-entries: segment.bytes: 1073741824 retention.ms: 86400000 cleanup.policy: delete config-entries-strict-sync: true ``` -------------------------------- ### View Docker Compose Service Logs Source: https://akvorado.net/docs/troubleshooting Inspect the logs of a specific Akvorado component to diagnose runtime errors or unexpected behavior. Replace 'akvorado-inlet' with the desired service name. ```bash $ docker compose logs akvorado-inlet ``` -------------------------------- ### List All Tables and Their Space Usage in ClickHouse Source: https://akvorado.net/docs/operations This query provides a comprehensive list of all tables across all databases, along with their total disk space usage and the oldest partition ID. Useful for overall storage management. ```sql SELECT database, table, formatReadableSize(sum(bytes_on_disk)) AS size, MIN(partition_id) AS oldest FROM system.parts GROUP by database, table ORDER by sum(bytes_on_disk) DESC ``` -------------------------------- ### Configure BMP Server Source: https://akvorado.net/docs/operations Set up a BMP server to receive routing information, including route monitoring policies. ```cisco bmp server 1 host port 10179 flapping-delay 60 bmp server all route-monitoring policy post inbound router bgp 65400 vrf public neighbor 192.0.2.100 bmp-activate server 1 ``` -------------------------------- ### Access Akvorado Inlet Metrics Source: https://akvorado.net/docs/metrics Use this command to fetch metrics from the Akvorado inlet API. The output includes metric type, help text, and values. ```bash $ curl -s http://127.0.0.1:8080/api/v0/inlet/metrics ​# HELP akvorado_cmd_info Akvorado build information ​# TYPE akvorado_cmd_info gauge akvorado_cmd_info{compiler="go1.24.4",version="v1.11.5-134-gaf3869cd701c"} 1 [...] ``` -------------------------------- ### Connect to ClickHouse Client Source: https://akvorado.net/docs/troubleshooting Access the ClickHouse client within a Docker environment to perform database checks and queries. ```bash $ docker compose exec clickhouse clickhouse-client ``` -------------------------------- ### Check Inlet Metrics Source: https://akvorado.net/docs/troubleshooting Verify if the inlet service is receiving packets from exporters. Look for 'akvorado_inlet_flow_input_udp_packets_total' to confirm packet reception. ```bash $ curl -s http://127.0.0.1:8080/api/v0/inlet/metrics | grep 'akvorado_inlet_flow_input_udp_packets' # HELP akvorado_inlet_flow_input_udp_packets_total Packets received by the application. # TYPE akvorado_inlet_flow_input_udp_packets_total counter akvorado_inlet_flow_input_udp_packets_total{exporter="241.107.1.12",listener=":2055",worker="2"} 6769 akvorado_inlet_flow_input_udp_packets_total{exporter="241.107.1.13",listener=":2055",worker="1"} 6794 akvorado_inlet_flow_input_udp_packets_total{exporter="241.107.1.14",listener=":2055",worker="2"} 6765 akvorado_inlet_flow_input_udp_packets_total{exporter="241.107.1.15",listener=":2055",worker="0"} 6782 ``` -------------------------------- ### Configure BGP Monitoring for BMP Station on Nokia SR OS Source: https://akvorado.net/docs/operations Enable BGP route monitoring and associate it with the configured BMP station. This ensures BGP route information is sent via BMP. ```bash /configure router "Base" bgp monitor admin-state enable /configure router "Base" bgp monitor route-monitoring post-policy true /configure router "Base" bgp monitor station "akvorado" { } ``` -------------------------------- ### Akvorado Static Metadata Provider Configuration Source: https://akvorado.net/docs/operations Configure Akvorado's static metadata provider to map exporter IPs to interface names and descriptions. This is used in conjunction with pmacct or ipfixprobe. ```yaml outlet: metadata: providers: - type: static exporters: 2001:db8:1::1: name: exporter1 ifindexes: 3: name: eth0 description: PNI Google speed: 10000 4: name: eth1 description: PNI Netflix speed: 10000 ``` -------------------------------- ### Configure File Inputs for NetFlow and sFlow (Testing) Source: https://akvorado.net/docs/configuration Configure file inputs for testing purposes, specifying the paths to raw flow data files. These files are continuously read and added to the processing pipeline. ```yaml flow: inputs: - type: file decoder: netflow paths: - /tmp/flow1.raw - /tmp/flow2.raw - type: file decoder: sflow paths: - /tmp/flow1.raw - /tmp/flow2.raw ``` -------------------------------- ### Verify Total Flows Count During Migration Source: https://akvorado.net/docs/operations After each 'attach partition' step during the migration, use this SQL query to verify that the total count of flows in the new 'flows' table and the remaining 'flows_old' table equals the expected total. This helps ensure no data loss. ```sql SELECT ( SELECT count(*) FROM flows ) + ( SELECT count(*) FROM flows_old ) ``` -------------------------------- ### List ClickHouse Tables Source: https://akvorado.net/docs/troubleshooting Display all available tables within the ClickHouse database to ensure expected tables exist. ```sql SHOW TABLES ``` -------------------------------- ### Configure Custom Interface Dictionaries Source: https://akvorado.net/docs/configuration Set up a custom dictionary for network interfaces to enrich flow data with interface-specific information. This configuration allows matching CSV columns to specific dimensions. ```yaml schema: custom-dictionaries: interfaces: layout: complex_key_hashed dimensions: - OutIf - InIf keys: - name: agent type: String # CSV column “agent” matches the ExporterAddress dimension match-dimension: ExporterAddress - name: interface type: String # CSV column “interface” matches matches either OUtIfName or InIfName match-dimension-suffix: Name attributes: - name: information # OutIfInformation/InIfInformation type: String # No default. If no match of both agent and interface, the dimension is empty source: /etc/akvorado/interfaces.csv ``` -------------------------------- ### Upgrade Akvorado using Docker Compose Source: https://akvorado.net/docs/install Commands to upgrade Akvorado when using Docker Compose. This involves fetching an upgrade tarball, pulling new images, and restarting the orchestrator. ```bash # cd akvorado # curl -sL https://github.com/akvorado/akvorado/releases/latest/download/docker-compose-upgrade.tar.gz | tar zxvf - # docker compose pull # docker compose stop akvorado-orchestrator # docker compose up --wait ``` -------------------------------- ### Analyze Column Space Usage and Compression in ClickHouse 'flows' Table Source: https://akvorado.net/docs/operations This query details space usage and compression ratios for each column in the 'flows' table. It helps identify columns that consume excessive space or are poorly compressed. ```sql SELECT database, table, column, type, sum(rows) AS rows, sum(column_data_compressed_bytes) AS compressed_bytes, formatReadableSize(compressed_bytes) AS compressed, formatReadableSize(sum(column_data_uncompressed_bytes)) AS uncompressed, sum(column_data_uncompressed_bytes) / compressed_bytes AS ratio, any(compression_codec) AS codec FROM system.parts_columns AS pc LEFT JOIN system.columns AS c ON (pc.database = c.database) AND (c.table = pc.table) AND (c.name = pc.column) WHERE table = 'flows' AND active GROUP BY database, table, column, type ORDER BY database ASC, table ASC, sum(column_data_compressed_bytes) DESC ``` -------------------------------- ### Restart Akvorado Containers Source: https://akvorado.net/docs/intro Commands to stop and restart Akvorado containers after configuration changes. ```bash docker compose down docker compose up --wait ``` -------------------------------- ### Retrieve Akvorado Inlet UDP Buffer Metrics Source: https://akvorado.net/docs/troubleshooting Fetch Akvorado inlet metrics via its API to check the size of the in-kernel UDP buffer for specific workers. This is useful for understanding buffer utilization. ```bash $ curl -s http://127.0.0.1:8080/api/v0/inlet/metrics | grep -P 'akvorado_inlet_flow_input_udp_buffer' ​# HELP akvorado_inlet_flow_input_udp_buffer_size_bytes Size of the in-kernel buffer for this worker. ​# TYPE akvorado_inlet_flow_input_udp_buffer_size_bytes gauge akvorado_inlet_flow_input_udp_buffer_size_bytes{listener=":2055",worker="2"} 212992 ``` -------------------------------- ### Generate Data Migration Statements Source: https://akvorado.net/docs/operations This SQL query generates the necessary 'INSERT', 'DROP PARTITION', and 'ATTACH PARTITION' statements to migrate data from 'flows_old' to 'flows_temp' and then attach partitions to the new 'flows' table. It processes data partition by partition. ```sql SELECT concat('insert into flows_temp select * from flows_old where _partition_id = \'', partition_id, '\';\n', 'alter table flows_old drop partition \'', partition_id, '\';\n', 'alter table flows attach partition id \'', partition, '\' from flows_temp;') AS cmd FROM system.parts WHERE (database = currentDatabase()) AND (`table` = 'flows_old') GROUP BY database, `table`, partition_id, partition ORDER BY partition_id ASC FORMAT TSVRaw ```