A method and apparatus of a device that exports Border Gateway Protocol (BGP) data in sFlow samples. The device generates separate tables for BGP attribute information, community list information, and autonomous systems path (AS_PATH) attribute information, where each entry in the BGP attribute information table is associated with an entry in the community list information table and an entry in the AS_PATH attribute information table. The device further populates a BGP route information table that defines a mapping from a network address prefix to an entry in the BGP attribute information table. The device generates a sFlow sample related to the network address prefix using the BGP attribute information table, the community list information table, the AS_PATH attribute information table, and the BGP route information table.
展开▼