作者投稿和查稿 主编审稿 专家审稿 编委审稿 远程编辑

›› 2005, Vol. 31 ›› Issue (20): 221-222.

• 论文 • 上一篇    下一篇

一种高效网络数据捕包平台的设计与实现

张志斌,郭莉,陈明宇,方滨兴   

  1. 中国科学院计算技术研究所,中国科学院计算技术研究所,中国科学院计算技术研究所,中国科学院计算技术研究所 北京 100080,中国科学院研究生院,北京 100089
  • 发布日期:2005-10-25

A High Performance User Level Packet Capture System

ZHANG Zhibin1,2,GUO Li1,CHEN Mingyu1,FANG Binxing1   

  1. (1.Institute of Computing Technology,Chinese Academy of Sciences,Beijing 100080;2.Graduate School,CAS,Beijing 100089)
  • Published:2005-10-25

摘要: 提出了一种基于用户空间的捕包平台设计――ULPF(User Level Packet Filter)。系统完全在用户空间实现;通过修改网卡驱动将数据绕过操作系统内核直接提交给用户空间避免了耗时的数据拷贝操作;利用网络数据包长度的局部性实现了一个高效的内存分配算法避免了多线程带来的内存分配开销。实验证明,该平台基本可以实现将网络数据流线速还原到TCP层。

关键词: 捕包, 网络协议栈, 内核, 内存分配

Abstract: This paper designs a packet capture system ULPF(User Level Packet Filter),which is completely implemented in user level.With optimizing network driver,people bypass kernel and put packets to user level directly so that they can avoid data copying which is time consuming.Advantage of the locality of packets length is taken to design an efficient memory allocator instead of malloc which will show its inefficiency inmultithread environment.The test result indicates that this system can process TCP packets almost at line speed.

中图分类号: