Appearance
Collector setup
Prerequisites
Install Go and ClickHouse, then apply the nat.translations schema. The collector replaces Vector and needs port 514.
sh
sudo systemctl disable --now vector
cd syslog/backend
cp .env.example .env
# Set CLICKHOUSE_PASSWORD in .env
go mod tidy
go build -o bin/server ./cmd/server
go build -o bin/devicectl ./cmd/devicectlApply the schema
sh
clickhouse-client --password < ../clickhouse/schema.sqlRegister a device
The collector accepts traffic only from registered source IPs. Specify the vendor so the correct parser is selected.
sh
./bin/devicectl add "Dream-100G" 10.208.1.1 netelastic
./bin/devicectl listRun and verify
Port 514 is privileged, so use the deployed systemd service or run the development server with sudo:
sh
sudo -E ./bin/server
clickhouse-client --password -q "SELECT count() FROM nat.translations"The server should report that it is listening on UDP and TCP port 514. Run the count query twice; it should increase while logs arrive.