欢迎来到淘文阁 - 分享文档赚钱的网站! | 帮助中心 好文档才是您的得力助手!
淘文阁 - 分享文档赚钱的网站
全部分类
  • 研究报告>
  • 管理文献>
  • 标准材料>
  • 技术资料>
  • 教育专区>
  • 应用文书>
  • 生活休闲>
  • 考试试题>
  • pptx模板>
  • 工商注册>
  • 期刊短文>
  • 图片设计>
  • ImageVerifierCode 换一换

    SDN-P4原版完整课件.pptx

    • 资源ID:89741865       资源大小:1.83MB        全文页数:38页
    • 资源格式: PPTX        下载积分:20金币
    快捷下载 游客一键下载
    会员登录下载
    微信登录下载
    三方登录下载: 微信开放平台登录   QQ登录  
    二维码
    微信扫一扫登录
    下载资源需要20金币
    邮箱/手机:
    温馨提示:
    快捷下载时,用户名和密码都是您填写的邮箱或者手机号,方便查询和重复下载(系统自动生成)。
    如填写123,账号就是123,密码也是123。
    支付方式: 支付宝    微信支付   
    验证码:   换一换

     
    账号:
    密码:
    验证码:   换一换
      忘记密码?
        
    友情提示
    2、PDF文件下载后,可能会被浏览器默认打开,此种情况可以点击浏览器菜单,保存网页到桌面,就可以正常下载了。
    3、本站不支持迅雷下载,请使用电脑自带的IE浏览器,或者360浏览器、谷歌浏览器下载即可。
    4、本站资源下载后的文档和图纸-无水印,预览文档经过压缩,下载后原文更清晰。
    5、试题试卷类文档,如果标题没有明确说明有答案则都视为没有答案,请知晓。

    SDN-P4原版完整课件.pptx

    P4:Programming Protocol-Independent Packet ProcessorsP.Bosshart,D.Daly,G.Gibb,M.Izzard,N.McKeown,J.Rexford,C.Schlesinger,D.Talayco,A.Vahdat,G.Varghese,D.WalkerSIGCOMM CCR,2014Presented by Ye Tian for Course CS05112OverviewMotivationAbstract Forwarding ModelA Programming LanguageAn ExampleReviewMotivationOver the past five years,OpenFlow has grown increasingly more complicatedThe proliferation of new header fields shows no signs of stopping.MotivationRather than repeatedly extending the OpenFlow specification,we argue that future switches should support flexible mechanisms for parsing packets and matching header fields,allowing controller applications to leverage these capabilities through a common,open interface(i.e.,a new“OpenFlow 2.0”API).Such a general,extensible approach would be simpler,more elegant,and more future-proof than todays OpenFlow 1.x standard.MotivationP4:a higher-level language for Programming Protocol-independent Packet ProcessorsConfigure a switch,telling it how packets are to be processedPopulate the forwarding tables in fixed function switchesThree goalsReconfigurableRedefine the packet parsing and processing in the field.Protocol independentthe controller should be able to specify a packet parser for extracting header fields with particular names and types anda collection of typed match+action tables that process these headerTarget independentCompiler should take the switchs capabilities into account when turning a target-independent description(written in P4)into a target-dependent programOverviewMotivationAbstract Forwarding ModelA Programming LanguageAn ExampleReviewAbstract Forwarding ModelA programming parserAllow new headers to be definedMultiple stages of match+actionIn series,parallel,or combination of bothCompare with OpenFlowFixed parserFixed series of actionsAbstract Forwarding ModelTwo types of operations:Configure operations program the parser,set the order of match+action stages,and specify the header fields processed by each stage.Static,offline wayPopulate operations add(and remove)entries to the match+action tables that were specified during configuration.Runtime Abstract Forwarding ModelArriving packets are first handled by the parser.Recognize and extract fields from the headerThe extracted header fields are then passed to the match+action tables.Ingress match+action table:determines the egress port(s)and determines the queue into which the packet is placed.The packet may be forwarded,replicated,dropped,or trigger flow control.Egress match+action table:performs per-instance modifications to the packet headerAbstract Forwarding ModelPackets can carry additional information between stages,called metadata,which is treated identically to packet header fields.Example:inport,timestamp,etcQueueing:an action maps a packet to a queueOverviewMotivationAbstract Forwarding ModelA Programming LanguageAn ExampleReviewA Programming LanguageDependencies between the fieldsDetermine which table can be executed in parallelTable Dependency Graphs(TDG)TDG nodes map directly to match+action tables,and a dependency analysis identifies where each table may reside in the pipeline.an example table dependency graph for an L2/L3 switch.A Programming LanguageTwo-step compilationAt the highest level,programmers express packet processing programs using an imperative language representing the control flow(P4);Below this,a compiler translates the P4 representation to TDGs to facilitate dependency analysis and then maps the TDG to a specific switch target.OverviewMotivationAbstract Forwarding ModelA Programming LanguageAn ExampleReviewAn ExampleConsider an example L2 network deployment with top-of-rack(ToR)switches at the edge connected by a two-tier core.mTag:a combination of PortLand and MPLS.The routes through the core are encoded by a 32-bit tag composed of four single-byte fields.Each core switch need only examine one byte of the tag and switch on that information.The tag is added by the first edge switch.P4 ConceptsA P4 program contains the following key componentsHeaders:describes the sequence and structure of a series of fields.Parsers:specify how to identify headers and valid header sequences within packets.Tables:Match+action tables are the mechanism for performing packet processing.Actions:Construction of complex actions from simpler protocol-independent primitives.Control Programs:determine the order of match+action tables that are applied to a packet.Header FormatsAn ordered list of names together with their widthEthernet and VLANHeader FormatsThe mTag header can be added without altering existing declarations.Each core switch is programmedwith rules to examine one of these bytes determined by its location in the hierarchy and the direction of travel.Output port on first and second levels up switch Output port on first and second levels down switchThe Packet ParserP4 assumes the underlying switch can implement a state machine that traverses packet headers from start to finish,extracting field values as it goes.P4 describes this state machine directly as the set of transitions from one header to the next.The Packet ParserStarts in the start state and proceeds until an explicit stop state is reached or an unhandled case is encounteredTable SpecificationThe edge switch matches on the L2 destination and VLAN ID,and selects an mTag to add to the header.The reads attribute declares which fields to match,qualified by the match type(exact,ternary,etc).The actions attribute lists the possible actions which may be applied to a packet by the table.The max size attribute specifies how many entries the table should support.The table specification allows a compiler to decide how much memory it needs,and the memory type(e.g.,TCAM or SRAM)to implement the table.Note that this is NOT the run-time packet processing logic.Table SpecificationBrief denfitions of other tablesBrief defitions of other tablesAction SpecificationP4 defines a collection of primitive actions from which more complicated actions are built.Action SpecificationIf an action needs parameters(e.g.,the up1 value for the mTag),it is supplied from the match table at runtime.P4s primitive actions include:set field:Set a specific field in a header to a value.copy field:Copy one field to another.add header:Set a specific header instance(and all its fields)as valid.remove header:Delete(“pop”)a header(and all its fields)from a packet.increment:Increment or decrement the value in a field.checksum:Calculate a checksum over some set of header fields(e.g.,an IPv4 checksum).The Control ProgramSpecify the flow of control from one table to the next.The Control ProgramThe source check table verifies consistency between the received packet and the ingress port.It also strips mTags from the packet,recording whether the packet had an mTag in metadata.The local switching table is then executed.If this table“misses“,it indicates that the packet is not destined for a locally connected host.The mTag table is applied to the packet.Both local and core forwarding control can be processed by the egress check table which handles the case of an unknown destination by sending a notification up the SDN control stack.The Control ProgramCompiling packet parserThe compiler translates the parser description into a parsing state machineCompiling control programControl program:not explicitly call out dependencies between tables or opportunities for concurrency.Employ a compiler to analyze the control program to identify dependencies and look for opportunities to process header fields in parallel.Finally,the compiler generates the target configuration for the switch.Compiling control programHow mTag can compiled on different targetsSoftware switch:The compiler directly maps the mTag table graph to switch tables.Hardware switches with RAM and TCAM:perform efficient exact-matching using RAM,matches on a subset of bits with TCAM.Switches supporting parallel tables:the tables mTag table and local switching can execute in parallel up to the execution of the action of setting an mTag.Compiling control programSwitches that apply actions at the end of the pipeline:In the mTag example,whether the mTag is added or removed could be represented in metadata.Switches with a few tables:Map a large number of P4 tables to a smaller number of physical tables.In the mTag example,the local switching could be combined with the mTag table.P4 forumThe newest specificationCompiler&switch sourcecodehttp:/p4.org/ReviewWhat motivates P4.What is the key differences with OpenFlow 1.x.The components of the abstract forwarding model of a switch in P4.The P4 language:The major components.

    注意事项

    本文(SDN-P4原版完整课件.pptx)为本站会员(暗伤)主动上传,淘文阁 - 分享文档赚钱的网站仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。 若此文所含内容侵犯了您的版权或隐私,请立即通知淘文阁 - 分享文档赚钱的网站(点击联系客服),我们立即给予删除!

    温馨提示:如果因为网速或其他原因下载失败请重新下载,重复下载不扣分。




    关于淘文阁 - 版权申诉 - 用户使用规则 - 积分规则 - 联系我们

    本站为文档C TO C交易模式,本站只提供存储空间、用户上传的文档直接被用户下载,本站只是中间服务平台,本站所有文档下载所得的收益归上传人(含作者)所有。本站仅对用户上传内容的表现方式做保护处理,对上载内容本身不做任何修改或编辑。若文档所含内容侵犯了您的版权或隐私,请立即通知淘文阁网,我们立即给予删除!客服QQ:136780468 微信:18945177775 电话:18904686070

    工信部备案号:黑ICP备15003705号 © 2020-2023 www.taowenge.com 淘文阁 

    收起
    展开