@wuzhimang
2016-05-30T10:13:34.000000Z
字数 3811
阅读 3972
SDN
wireshark
openflow
谈到OpenFlow协议数据包的解析,之前自己直接是从Mininet官网下载了虚拟机镜像(ubuntu)的,里面已经包含了wireshark套件,拿来即可用!
最近需要在CentOS物理机上进行抓包分析,在安装Wireshark和openflow dissecctor时碰到了一些小问题,在此总结整理并分享下...
yum install -y wireshark*
,安装成功后如下
[root@share ofdissector]# rpm -aq | grep wireshark
wireshark-gnome-1.8.10-17.el6.x86_64
wireshark-devel-1.8.10-17.el6.x86_64
wireshark-1.8.10-17.el6.x86_64
wireshark &
),查看其版本信息(可直接通过命令wireshark -v
),是否支持lua,如下图 yum install scons -y
)!
[root@gf01 Desktop]# cd /usr/lib64/wireshark/plugins/1.10.14/
[root@gf01 1.10.14]# wget https://raw.githubusercontent.com/floodlight/loxigen-artifacts/master/wireshark/openflow.lua
[root@gf01 1.10.14]# chmod a+x openflow.lua
在CentOS下安装新版本支持openflow协议的wireshark很繁琐,不建议本步骤,如需这样建议直接升级系统到CentOS7!!!
1. 下载编译安装,如下系统报了Qt5Core版本的错误,且yum支持qt3的安装,故需要转入Qt5的安装
[root@share ~]# wget https://www.wireshark.org/download/src/wireshark-2.0.3.tar.bz2
[root@share ~]# tar -xjf wireshark-2.0.3.tar.bz2
[root@share ~]# cd wireshark-2.0.3 && ./configure
......
checking for sed... (cached) /bin/sed
checking for GNU sed as first sed in PATH... yes
checking if profile builds must be generated... no
checking for Qt5Core - version >= 5.0.0... no
checking for QtCore - version >= 4.7.0... no
configure: error: Qt is not available
[root@share ~]# cat /etc/redhat-release
CentOS release 6.7 (Final)
[root@share ~]# yum search qt
...
qt3.x86_64 : The shared library for the Qt 3 GUI toolkit
...
qt3-devel.i686 : Development files for the Qt 3 GUI toolkit
...
[root@share ~]# wget http://mirrors.ustc.edu.cn/gnu/gcc/gcc-6.1.0/gcc-6.1.0.tar.gz
本方法很繁琐,有兴趣和时间的可以尝试,毕竟原生版本在支持力和性能方面会好不少
[root@gf01 1.10.14]# cat /etc/redhat-release
CentOS Linux release 7.2.1511 (Core)
[root@gf01 1.10.14]# rpm -aq | grep wireshark
wireshark-devel-1.10.14-7.el7.x86_64
wireshark-gnome-1.10.14-7.el7.x86_64
wireshark-1.10.14-7.el7.x86_64
[root@gf01 1.10.14]# wireshark -v
wireshark 1.10.14 (Git Rev Unknown from unknown)
Copyright 1998-2015 Gerald Combs <gerald@wireshark.org> and contributors.
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
Compiled (64-bit) with GTK+ 2.24.28, with Cairo 1.14.2, with Pango 1.36.8, with
GLib 2.42.2, with libpcap, with libz 1.2.7, with POSIX capabilities (Linux),
without libnl, with SMI 0.4.8, with c-ares 1.10.0, with Lua 5.1, without Python,
with GnuTLS 3.3.8, with Gcrypt 1.5.3, with MIT Kerberos, without GeoIP, without
PortAudio, with AirPcap.
Running on Linux 3.10.0-327.el7.x86_64, with locale en_US.UTF-8, with libpcap
version 1.5.3, with libz 1.2.7, GnuTLS 3.3.8, Gcrypt 1.5.3, without AirPcap.
Intel(R) Xeon(R) CPU E5-2620 v3 @ 2.40GHz
Built using gcc 4.8.5 20150623 (Red Hat 4.8.5-4).
[root@gf01 1.10.14]#
yum search qt5