既存の NETWAYS/sflow パーサーに大きめと思われるバグがあり、ユーザーの手元ではデータが壊れていると思われます。
バグは取りつつ互換にするのが理想ではありますが、テストを書きつつトランスレーターを実装するのがまあまあ手間で迷っています。
- 1 sflow export 中には複数flow sample 格納される
- 1 flow sample 中には複数flow record 格納される
| version 17.4R1.16; | |
| system { | |
| host-name vqfx1-re; | |
| root-authentication { | |
| encrypted-password "xxx"; ## SECRET-DATA | |
| ssh-rsa "ssh-rsa xxx"; ## SECRET-DATA | |
| } | |
| login { | |
| user koji { | |
| uid 2001; |
| ! Command: show running-config | |
| ! device: veos2 (vEOS, EOS-4.22.0F) | |
| ! | |
| ! boot system flash:/vEOS-lab.swi | |
| ! | |
| transceiver qsfp default-mode 4x10G | |
| ! | |
| service routing protocols model multi-agent | |
| ! | |
| hostname veos2 |
| { | |
| "nodes": [ | |
| { "name": "POP01-bb01", "group": "bb", "icon": "./images/router.png" }, | |
| { "name": "POP01-bb02", "group": "bb", "icon": "./images/router.png" }, | |
| { "name": "POP01-ag01", "group": "ag", "icon": "./images/switch.png" }, | |
| { "name": "POP01-ag02", "group": "ag", "icon": "./images/switch.png" }, | |
| { "name": "POP02-bb01", "group": "bb", "meta": { "loopback": "10.0.0.1" } }, | |
| { "name": "POP02-bb02", "group": "bb" }, | |
| { "name": "POP02-ag01", "group": "ag" }, | |
| { "name": "POP02-ag02", "group": "ag" }, |
| <!DOCTYPE html> | |
| <html> | |
| <head> | |
| <meta charset="utf-8"/> | |
| <script src="https://cdnjs.cloudflare.com/ajax/libs/d3/3.5.17/d3.js"></script> | |
| <script src="https://inet-henge.herokuapp.com/js/cola.min.js"></script> | |
| <script src="https://inet-henge.herokuapp.com/js/inet-henge.js"></script> | |
| <style> | |
| .path-label { | |
| font-size: 7px; |
| { | |
| "_index": "packets-2018-09-16", | |
| "_type": "pcap_file", | |
| "_score": null, | |
| "_source": { | |
| "layers": { | |
| "frame_raw": ["080027f854e2080027a13a3b0800450000f800000000fe116792a9fe0002a9fe0064c88f18c700e4b6e50000000500000001a9fe000200000000000002fe0044de260000000100000001000000b8000004cb0000020000000001000004cc000000000000020000000000000000020000000100000078000000010000006a0000000400000066020586717403020586716403884700010140450000544a9500004001aec0c0a80002c0a800010800b31d400e004d5b1d85c70008389708090a0b0c0d0e0f101112131415161718191a1b1c1d1e1f202122232425262728292a2b2c2d2e2f30313233343536370000000003e90000001000000000000000000000000000000000", 0, 262, 0, 1], | |
| "frame": { | |
| "frame.encap_type": "1", | |
| "frame.number": "1", |
| require 'junoser' | |
| require 'parslet' | |
| module Junoser | |
| module Display | |
| class DeleteTransformer < Parslet::Transform | |
| rule(config: simple(:config)) do | |
| "(#{config.to_s}" | |
| end |
| from __future__ import unicode_literals, print_function, absolute_import | |
| from _pybgpstream import BGPStream, BGPRecord, BGPElem | |
| import re | |
| class BgpUpdate(object): | |
| def __init__(self, collector=None, nexthop=None, aspath=None, start=None, stop=None): | |
| self.collector = collector | |
| self.nexthop = nexthop | |
| self.aspath = aspath |
| require 'open-uri' | |
| require 'pg' | |
| require 'uri' | |
| module RouteViews | |
| DIR = 'mrt' | |
| BASE_URL = 'http://archive.routeviews.org' | |
| SERVERS = { | |
| 'oregon2' => '', | |
| 'oregon3' => 'route-views3', |
| { | |
| "202.249.2.169": [ | |
| { | |
| "aspath": "2497 701 15169 4713", | |
| "prefixes": 31325 | |
| }, | |
| { | |
| "aspath": "2497 701 15169 9121", | |
| "prefixes": 10387 | |
| }, |