netfpga 기반 - fiffif.kr/fiwc2009/doc/jylee.pdfverilog, etc). flexible definitions of a flow...

37
1 忠南大學校 情報通信工學部 Data Communications Lab. NetFPGA NetFPGA 기반 기반 OpenFlow OpenFlow switch switch 설치 설치 향후 향후 계획 계획 충남대학교 정보통신공학부 이재용

Upload: others

Post on 03-Apr-2020

3 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

1忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA 기반기반OpenFlowOpenFlow switch switch 설치설치및및 향후향후 계획계획

충남대학교정보통신공학부

이재용

Page 2: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

2忠南大學校 情報通信工學部 Data Communications Lab.

목목 차차

NetFPGA설치및테스트OpenFlow switch 설치및테스트향후연구

Page 3: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

3忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA IntroductionIntroductionThe NetFPGA is a low-cost platform

Tool for teaching networking hardware and router design Tool for networking researchers

Page 4: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

4忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA Usage modelsUsage models1) Reference Router : can be downloaded from http://NetFPGA.org

Hardware-accelerated NIC, or IPv4 router Openflow switch extension

2) Customized Router3) Complete new design

Page 5: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

5忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA Major componentsMajor componentsInterfaces: PCI, 4GEMemoriesFPGA resourcesSchematic and board layout

PDF (http://netfpga.org/NetFPGA_PCB_r3.pdf)Orcad Capture file (http://netfpga.org/NetFPGA_PCB-May-14-2008.zip)

Page 6: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

6忠南大學校 情報通信工學部 Data Communications Lab.

Obtaining Obtaining NetFPGANetFPGA systemsystemObtaining NetFPGA Hardware

Digilent Inc. , [email protected]

Obtaining a Host PC for the NetFPGA

Assemble your on PC using from componentsPurchase a Dell 2950Purchase a complete pre-built system

User Space

Linux Kernel

NIC

GE

PCI-ePCI

Browser& VideoClient

MonitorSoftware

GE

GE

GE

GE

GE

CADTools

NetFPGA RouterHardware

VI VI VI VI

Packet Forwarding Table

(eth1 .. 2)(nf2c0 .. 3)

Web &VideoServer

Page 7: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

7忠南大學校 情報通信工學部 Data Communications Lab.

Obtaining Obtaining GatewareGateware/Software Package /Software Package Download the Beta NetFPGA Package (NFP)

Sign up for a new beta account http://netfpga.org/netfpgawiki/index.php?title=Special:Userlogin&type=signup

Download the tarballs from http://NetFPGA.org/beta/distributionsnetfpga_base_beta_1_2_5_2_CentOS5.tar.gz

Download the extended NetFPGA Package (BetaPlus, optional) 1) Complete the survey on-line as: http://netfpga.org/survey.html2) Send an email to [email protected]

written guarantee that you will not re-distribute the source code 3) 7 days for review email confirmation 4) download the NFP from http://NetFPGA.org/betaplus

netfpga_full_beta_1_2_5_1.tar.gz

Page 8: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

8忠南大學校 情報通信工學部 Data Communications Lab.

Install Software Install Software

CentOS설치 (4.4, 4.5, 5.1, 5.2)

GUI 환경을위한 JDK 설치1.6 이후버전설치

RPMforge repositoryyum이용패키지인스톨시인스톨정보를얻을수없을경우 rpmforge를repository로써추가시키면최신정보에의해인스톨가능

NetFPGA Base Package

Verilog개발툴설치Xilinx ISE , ModelSim, ChipScope

시뮬레이션을위한 Memory Modules 추가Micron DDR2 SDRAM Cypress SRAM

Page 9: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

9忠南大學校 情報通信工學部 Data Communications Lab.

Verify the software and hardware Verify the software and hardware Compile and Load Driver

cd ~/NF2/ make make install reboot

Page 10: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

10忠南大學校 情報通信工學部 Data Communications Lab.

Verify the software and hardwareVerify the software and hardware

Run SelftestReprogram the CPCI

/usr/local/sbin/cpci_reprogram.pl --all

PC를 restart 할때마다시행

Loopback cable 설치

Load self-test bitfilenf2_download ~/NF2/bitfiles/selftest.bit

Page 11: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

11忠南大學校 情報通信工學部 Data Communications Lab.

Verify the software and hardwareVerify the software and hardwareRun Regression Tests

Connect Ethernet test cablesLoad reference_router bitfile

nf2_download ~/NF2/bitfiles/reference_router.bitRun regression test suite

~/NF2/bin/nf21_regress_test.pl

Page 12: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

12忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA full system componentsfull system components

Software

PCI Bus

NetFPGA

CPURxQCPURxQ

CPUTxQCPUTxQ

nf2_reg_grpnf2_reg_grp

user data pathuser data path

nf2c0nf2c0 nf2c1nf2c1 nf2c2nf2c2 nf2c3nf2c3 ioctlioctl

MACTxQMACTxQ

MACRxQMACRxQ

Ethernet

CPURxQCPURxQ

CPUTxQCPUTxQCPU

RxQCPURxQ

CPUTxQCPUTxQCPU

RxQCPURxQ

CPUTxQCPUTxQ

MACTxQMACTxQ

MACRxQMACRxQMAC

TxQMACTxQ

MACRxQMACRxQMAC

TxQMACTxQ

MACRxQMACRxQ

Page 13: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

13忠南大學校 情報通信工學部 Data Communications Lab.

The SCONEThe SCONESoftware Component Of NetFPGA

IPv4 forwarding, handles ARPs and various ICMP messages, has telnet (port 23) and web (port 8080) interfaces implements a subset of OSPF named PW-OSPF.

SCONE mirrors a copy of its MAC addresses, IP addresses, routing table, and ARP table to the NetFPGA card which hardware accelerates the forwarding path

Page 14: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

14忠南大學校 情報通信工學部 Data Communications Lab.

The reference pipeline of The reference pipeline of NetFPGANetFPGARx queues moduleInput arbiter module다음서비스를위한 RxQ결정

Output port lookup module 출력포트결정

“Openflow switch”확장 module Output queues module 출력포트 packet 일시저장“Traffic scheduler “구현위치

Tx queues module

Page 15: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

15忠南大學校 情報通信工學部 Data Communications Lab.

InterInter--Module CommunicationModule CommunicationOnly “Push” operation

“RDY” signal : 1 bit “WR” signal : 1 bit “CTRL” signal: 8 bit

Module header 구분End of Packet 구분

“DATA” signal : 64 bit

data

ctrlwr

rdy

Page 16: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

16忠南大學校 情報通信工學部 Data Communications Lab.

InterInter--Module CommunicationModule Communication“Module header”로정보전달

First module header: Rx queue 에서생성

IP HdrEth Hdr

…00

0Last word of packet0x10

Last Module Hdry……

Module Hdrx Contain information such as packet length, input port, output port, …

Data Word(64 bits)

Ctrl Word(8 bits)

Page 17: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

17忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA 라우팅라우팅 테스트테스트

실험환경

실험결과

ping 을이용확인

Page 18: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

18忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA 대역폭대역폭 측정측정 실험실험

실험환경

iperf 프로그램

Reno TCP

t = 1800s

단말환경

OS : Cent OS 5.2

(Kernel 2.6.18-web100)

CPU : 2.8GHz

RAM : 512MB

LAN : dual port 1G

Page 19: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

19忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA 대역폭대역폭 측정측정 실험실험

Reno TCP HSTCP

Page 20: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

20忠南大學校 情報通信工學部 Data Communications Lab.

OpenFlowOpenFlow switchingswitchingIsolation: Regular production traffic untouchedVirtualized and programmable: Different flows processed in different ways Open development environment for all researchers (e.g. Linux, Verilog, etc). Flexible definitions of a flow

Individual application trafficAggregated flowsAlternatives to IP running side-by-side…

StandardNetwork

Processing

StandardNetwork

Processinghwsw Experimenter writes

experimental codeon switch/router

User-defined

Processing

User-defined

Processing

Page 21: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

21忠南大學校 情報通信工學部 Data Communications Lab.

OpenFlowOpenFlow componentscomponentsOpenFlow Controller OpenFlow protocolSecure channelFlow Table

Ingress portEthernet src/dst addressesEthernet typeVLAN tagIP src/dst addressesIP protocolTCP/UDP src/dst ports

Page 22: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

22忠南大學校 情報通信工學部 Data Communications Lab.

Flow Table EntryFlow Table Entry““Type 0Type 0”” OpenFlowOpenFlow SwitchSwitch

+ mask

SwitchPort

MACsrc

MACdst

Ethtype

VLANID

IPSrc

IPDst

IPProt

TCPsport

TCPdport

Rule Action Stats

1. Forward packet to port(s)2. Encapsulate and forward to controller3. Drop packet4. Send to normal processing pipeline

Packet + byte counters

Page 23: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

23忠南大學校 情報通信工學部 Data Communications Lab.

OpenFlowOpenFlow protocolprotocol“http://www.openflowswitch.org/documents/openflow-spec-v0.8.9.pdf”Controller-to-Switch Messages

Handshake messagesOFPT_FEATURES_REQUEST/OFPT_FEATURES_REPLY

Switch configuration messagesOFPT_SET_CONFIG/OFPT_GET_CONFIG_REQUEST/OFPT_GET_CONFIG_REPLY

Modify Flow messagesOFPT_FLOW_MOD/OFPT_PORT_MOD

Read state messagesOFPT_STATS_REQUEST/OFPT_STATS_REPLY

Send packet messageOFPT_PACKET_OUT

Asynchronous MessagesOFPT_PACKET_IN/OFPT_FLOW_EXPIRED/OFPT_PORT_STATUS/OFPT_ERROR_MSG

Symmetric messagesHELLO/ECHO_REQUEST/ECHO_REPLY

Page 24: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

24忠南大學校 情報通信工學部 Data Communications Lab.

Using Using OpenFlowOpenFlow on on NetFPGANetFPGAImplementation

Output port lookup module 확장

Page 25: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

25忠南大學校 情報通信工學部 Data Communications Lab.

Performance ResultsPerformance ResultsThe maximum number of flows active <= 10000 flows

fit very easily into the NetFPGA OpenFlow switch’s 32,000-entry exact match table.

The maximum new flow request rate seen in the Stanford EE/CS network <= 7000 flows/second,

within the capabilities of unoptimized NetFPGA OpenFlow switch implementation.

Page 26: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

26忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA OpenFloOpenFloww switch switch 설치설치Obtain tarball

http://netfpga.org/beta/distributions/netfpga_openflow_switch.0_8_9-1.tar.gzRegression Tests

Reprogram the CPCI

Load openflow_switch bitfile

nf21_regression_test.pl --project openflow_switch실행

Page 27: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

27忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA OpenFloOpenFloww switch switch 테스트테스트

Page 28: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

28忠南大學校 情報通信工學部 Data Communications Lab.

NetFPGANetFPGA OpenFloOpenFloww switch switch 테스트테스트Controller 실행

./controller -v ptcp:6633

Openflow switch 실행순서Download OpenFlow bitfile.

nf2_download openflow_switch.bit

Insert OpenFlow kernel module and NetFPGA kernel module

/sbin/insmod openflow_mod.ko

/sbin/insmod hwtable_nf2_mod.ko

Setup datapath and interface

dpctl adddp nl:1

dpctl addif nl:1 nf2cX

dpctl show nl:1

ifconfig of0 192.168.1.X netmask 255.255.255.0

secchan nl:1 tcp:controller ip:port

Page 29: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

29忠南大學校 情報通信工學部 Data Communications Lab.

OpenFloOpenFloww switch switch DatapathDatapath 설정설정

Page 30: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

30忠南大學校 情報通信工學部 Data Communications Lab.

OpenFloOpenFloww switch switch ‘‘pingping’’ 테스트테스트

Page 31: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

31忠南大學校 情報通信工學部 Data Communications Lab.

OpenFloOpenFloww switch switch ‘‘pingping’’ 테스트테스트

Page 32: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

32忠南大學校 情報通信工學部 Data Communications Lab.

OpenFloOpenFloww switch switch ‘‘pingping’’ 테스트테스트

Page 33: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

33忠南大學校 情報通信工學部 Data Communications Lab.

Page 34: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

34忠南大學校 情報通信工學部 Data Communications Lab.

향후향후 연구연구

“미래인터넷 인프라를 위한 PC기반 네트워크 가상화 노드 및 테스트베드구축”연구

Programmable Computing/Networking Node

Node Controller

Wireless Networking

Wired Networking NetFPGA Hardware Substrate

Programmable Networking VirtualizationOpenFlow

VINI

Network Services, Computation Services

Experiment & Control

Operation & Management

Measurement

Nod

e M

anag

emen

t

AgentAgentAgentAgent

Page 35: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

35忠南大學校 情報通信工學部 Data Communications Lab.

향후향후 연구연구

Programmable 네트워크장치의다중네트워크지원자원관리및가상화기술개발

자원관리 scheduler (DRR, WFQ 등)Packet editor 확장 (NAT, Other protocols)Openflow protocol 확장

Page 36: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

36忠南大學校 情報通信工學部 Data Communications Lab.

향후향후 연구연구

Scheduler 구현Output queue 확장DRR, WFQ, SCFQ 등

OpenFlow protocol 확장Flow entry 및 message format 수정

Rule Action Stats QoS Spec.

Output Queue

Page 37: NetFPGA 기반 - FIFfif.kr/fiwc2009/doc/jylee.pdfVerilog, etc). Flexible definitions of a flow ¾Individual application traffic ¾Aggregated flows ¾Alternatives to IP running side-by-side

37忠南大學校 情報通信工學部 Data Communications Lab.

References References NetFPGA Guide document,

http://netfpga.org/netfpgawiki/index.php/GuideNick McKeown, et al., “OpenFlow: Enabling Innovation in Campus Networks”, Whitepaper,

http://www.openflowswitch.org//documents/openflow-wp-latest.pdfBrandon Heller, “OpenFlow Switch Specification”,

http://www.openflowswitch.org/documents/openflow-spec-v0.8.9.pdfJad Naous, et al., “Implementing an OpenFlow Switch on the NetFPGAplatform”, ACM ANCS’08, Nov. 2008