RFC5885翻译

静态路由与BFD联动配置 为了能够快速的检测这两台设备之间的故障,可以在支持BFD功能的设备上创建单臂回声功能的BFD会话。BFD检测是通过维护在两个系统之间建立的BFD会话来实现的,系统通过发送BFD报文建立会话。两个系统之间建立BFD会话通道,并周期性发送BFD检测报文,如果某个系统在规定的时间内没有收到对端的检测报文,则认为该通道的某个部分发生了故障。两个系统建立BFD会话,并沿它们之间的路径周期性发送BFD控制报文,如果一方在既定的时间内没有收到BFD控制报文,则认为路径上发生了故障。图13-4:BFD的报文。 阅读详情

Internet Engineering Task Force (IETF)                    T. Nadeau, Ed. Request for Comments: 5885                                            BT Category: Standards Track                              C. Pignataro, Ed. ISSN: 2070-1721                                      Cisco Systems, Inc.

June 2010

 

 

Bidirectional Forwarding Detection (BFD) for

the Pseudowire Virtual Circuit Connectivity Verification (VCCV)

 

Abstract

 

摘要

 

This document describes Connectivity Verification (CV) Types using Bidirectional Forwarding Detection (BFD) with Virtual Circuit Connectivity Verification (VCCV).                                   VCCV provides a control channel that is associated with a pseudowire (PW), as well as the corresponding operations and management functions such as connectivity verification to be used over that control channel.

 

这个文件描述在VCCV(虚电路连接验证)上使用BFD的CV(连通性验证)类型。VCCV提供关联PW的控制通道,并且提供一致性操作和管理功能,比如用在控制平面上的CV。

 

Status of This Memo

 

本备忘录的状态

 

This is an Internet Standards Track document.

        

 这是一个internet标准跟踪文件。

 

This document is a product of the Internet Engineering Task Force (IETF).    It represents the consensus of the IETF community.              It has received public review and has been approved for publication by the Internet Engineering Steering Group (IESG).  Further information on Internet Standards is available in Section 2 of RFC 5741.

 

更多有效信息在RFC 5741的第二部分。

 

Information about the current status of this document, any errata, and how to provide feedback on it may be obtained at

http://www.rfc-editor.org/info/rfc5885.

当前备忘录状态信息,勘误表和如何反馈,通过上述网址获得。                                                   

Copyright Notice

版权

Copyright (c) 2010 IETF Trust and the persons identified as the document authors.                   All rights reserved.

        

This document is subject to BCP 78 and the IETF Trust’s Legal Provisions Relating to IETF Documents (http://trustee.ietf.org/license-info) in effect on the date of publication of this document.  Please review these documents

carefully, as they describe your rights and restrictions with respect to this document.                   Code Components extracted from this document must include Simplified BSD License text as described in Section 4.e of

the Trust Legal Provisions and are provided without warranty as described in the Simplified BSD License.

 

This document may contain material from IETF Documents or IETF Contributions published or made publicly available before November

10, 2008.  The person(s) controlling the copyright in some of this material may not have granted the IETF Trust the right to allow modifications of such material outside the IETF Standards Process. Without obtaining an adequate license from the person(s) controlling the copyright in such materials, this document may not be modified outside the IETF Standards Process, and derivative works of it may not be created outside the IETF Standards Process, except to format it for publication as an RFC or to translate it into languages other than English.

 

Table of Contents

 

目录

 

1.

Introduction . . . . . . . . .

. .

. . .

. . . .

.

.

.

.

.

.

.

3

2.

Specification of Requirements

. .

. . .

. . . .

.

.

.

.

.

.

.

3

3.  Bidirectional Forwarding Detection Connectivity

Verification . . . . . . . . . . . . . . . . . . . . . . . . .  3

3.1.  BFD CV Type Operation  . . . . . . . . . . . . . . . . . .  4

3.2.  BFD Encapsulation  . . . . . . . . . . . . . . . . . . . .  5

3.3.  CV Types for BFD . . . . . . . . . . . . . . . . . . . . .  7

4.  Capability Selection . . . . . . . . . . . . . . . . . . . . .  9

5.  IANA Considerations  . . . . . . . . . . . . . . . . . . . . . 10

5.1.  MPLS CV Types for the VCCV Interface Parameters Sub-TLV  . 10

5.2.  PW Associated Channel Type . . . . . . . . . . . . . . . . 10

5.3.  L2TPv3 CV Types for the VCCV Capability AVP  . . . . . . . 11

6.  Congestion Considerations  . . . . . . . . . . . . . . . . . . 11

7.  Security Considerations  . . . . . . . . . . . . . . . . . . . 12

8.  Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 12

9.  References . . . . . . . . . . . . . . . . . . . . . . . . . . 12

9.1.  Normative References . . . . . . . . . . . . . . . . . . . 12

9.2.  Informative References . . . . . . . . . . . . . . . . . . 13

 

 

 

  1. Introduction

 

介绍

        

This document describes Connectivity Verification (CV) Types using Bidirectional Forwarding Detection (BFD) with Virtual Circuit Connectivity Verification (VCCV).   VCCV [RFC5085] provides a control channel that is associated with a pseudowire (PW), as well as the corresponding operations and management functions such as connectivity/fault verification to be used over that control channel.

 

这个文件描述在VCCV(虚电路连接验证)上的使用BFD的CV(连通性验证)类型。VCCV[RFC5085]提供关联PW的控制平面,并且提供一致性操作和管理功能,比如用在控制通道上的连通性/故障验证。

 

 

primarily as a

pseudowire fault detection mechanism

BFD [RFC5880] is used over the VCCV control channel

 

 

additionally carry fault status

, for detecting data-plane

 

 

 

between the endpoints of the pseudowire

failures.  Some BFD CV Types can

 

 

 

.  Furthermore, this

 

information can then be translated into the native Operations, Administration, and Maintenance (OAM) status codes used by the native access technologies, such as ATM, Frame Relay, or Ethernet.                                  The specific details of such status interworking are out of the scope of this document, and are only noted here to illustrate the utility of BFD over VCCV for such purposes.           Those details can be found in

[OAM-MSG-MAP].

 

BFD被用在VCCV控制通道上,它主要作为PW故障检测机制,用来检测数据平面失效。此外,很多BFD CV类型可以在PW端点间传递故障状态。这些状态随后可以翻译到本地OAM状态码中应用于本地接入技术,比如:ATM,Frame Relay 或者Ethernet.这些状态的协作细节不在本文件讨论范围内,提到这些细节只是为了在这里举例说明一些VCCV BFD的实用目的。这些细节可以在[OAM-MSG-MAP]中查找。

 

The new BFD CV Types are PW demultiplexer-agnostic, and hence applicable for both MPLS and Layer Two Tunneling Protocol version 3 (L2TPv3) pseudowire demultiplexers.   This document concerns itself with the BFD VCCV operation over single-segment pseudowires (SS-PWs). This specification describes procedures only for BFD asynchronous mode.

 

新BFD CV 是PW多路分配器不可知的,因此它适用于 MPLS和L2TPv3 PW分配器。本文件关注BFD VCCV在单段PW(SS-PWs)上的运作。规则描述的程序只用于BFD异步模式。

 

  1. Specification of Requirements

 

需求项说明

 

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC2119].

 

The reader is expected to be familiar with the terminology and abbreviations defined in [RFC5085].

 

  1. Bidirectional Forwarding Detection Connectivity Verification

 

双向转发检测连通性验证

 

VCCV can support several Connectivity Verification (CV) Types.  This section defines new CV Types for use when BFD is used as the VCCV payload.

 

VCCV支持多种连通性验证类型,这部分定义BFD作为VCCV负载的新CV类型。

 

Four CV Types are defined for BFD.  Table 1 summarizes the BFD CV Types, grouping them by encapsulation (i.e., with versus without IP/ UDP headers) and by functionality (i.e., fault detection only versus fault detection and status signaling).

 

为BFD定义的四种CV类型。表1总结BFD CV的分类,通过封装(即,对照于带不带IP/UDP头)和功能(即,仅故障检测对照与故障检测和状态信号)分类。

 

 

 

+----------------------------+--------------+-----------------------+

|

 

|

Fault

|

Fault Detection and

|

|

 

|

Detection

|

Status Signaling

|

|

 

|

Only

|

 

|

+----------------------------+--------------+-----------------------+

|

BFD, IP/UDP Encapsulation

|

0x04

|

0x08

|

|

(with IP/UDP Headers)

|

 

|

 

|

|

 

|

 

|

 

|

|

BFD, PW-ACH Encapsulation

|

0x10

|

0x20

|

|

(without IP/UDP Headers)

|

 

|

 

|

+----------------------------+--------------+-----------------------+

 

Table 1: Bitmask Values for BFD CV Types

 

    1. BFD CV Type Operation

 

BFD CV的运作

 

When heart-beat indication is necessary for one or more PWs, the

Bidirectional Forwarding Detection (BFD) [RFC5880] provides a means

of continuous monitoring of the PW data path and, in some operational

modes, propagation of PW receive and transmit defect state

indications.

 

当一个或多个PW需要节拍性标志时,BFD提供PW数据路径的连续监测和一些操作模式下,PW收发缺陷状态的传播。

 

In order to use BFD, both ends of the PW connection need to agree on the BFD CV Type to use:

 

为了使用BFD,PW的两端连接都需要同意使用BFD CV。

 

For statically provisioned pseudowires, both ends need to be statically configured to use the same BFD CV Type (in addition to being statically configured for VCCV with the same CC Type).

 

对于静态供应的PW,两端都需要静态配置来使用相同BFD CV类型(已静态配置相同CC类型的VCCV)。

 

For dynamically established pseudowires, both ends of the PW must have signaled the existence of a control channel and the ability to run BFD on it (see Sections 3.3 and 4).

 

对于动态建立的PW,PW两端必须已经表明其存在控制通道,并有运行BFD的能力。(见3.3 和4)

 

Once a node has selected a valid BFD CV Type to use (either statically provisioned or selected dynamically after the node has both signaled and received signaling from its peer of these capabilities), it begins sending BFD Control packets:

 

一但一个节点选择了有效的BFD CV类型来使用(静态提供或者在节点已经发送和接受了来自其对等点的信令后的动态选择),它开始发送BFD控制包。

 

o  The BFD Control packets are sent on the VCCV control channel.  The use of the VCCV control channel provides the context required to bind and bootstrap the BFD session, since discriminator values are not exchanged; the pseudowire demultiplexer field (e.g., MPLS PW Label or L2TPv3 Session ID) provides the context to demultiplex

the first BFD Control packet, and thus single-hop BFD initialization procedures are followed (see Section 3 of [RFC5881] and Section 6 of [RFC5882]).

 

BFD控制包被发送在VCCV控制通道上。由于会话标识值不可更改,使用VCCV控制通道提供的上下文环境需要绑定并引导BFD会话;伪线分配域(比如,MPLS PW标签或者L2TPv3 Session ID)提供上下文环境来区分第一个BFD控制报文,并因此伴随着单跳BFD初始化过程(见[RFC5881]第三部分和[RFC5882]第六部分)。

 

 

 

o  A single BFD session exists per pseudowire.  Both PW endpoints take the Active role sending initial BFD Control packets with a Your Discriminator field of zero, and BFD Control packets received with a Your Discriminator field of zero are associated to the BFD session bound to the PW.

  

   每条PW上存在单独的BFD会话。PW的两端都采用主动方式发送Your Discriminator为0的初始BFD控制包,被接收的Your Discriminator为0的 BFD控制包被关联到绑定PW的BFD会话上。

 

o  BFD MUST be run in asynchronous mode (see [RFC5880]).

  

   BFD 必须工作在异步模式(见[RFC5880])。

 

The operation of BFD VCCV for PWs is therefore symmetrical.  Both endpoints of the bidirectional pseudowire MUST send BFD messages on the VCCV control channel.

 

PW的BFD VCCV运作是对称的。双向PW的两端必须在VCCV控制通道上发送BFD信息。

 

The details of the BFD state machine are as per Section 6.2 of [RFC5880].    The following scenario exemplifies the operation: when the downstream PE (D-PE) does not receive BFD Control messages from its upstream peer PE (U-PE) during a certain number of transmission intervals (a number provisioned by the operator as "Detect Mult" or detection time multiplier [RFC5880]), D-PE declares that the PW in its receive direction is down.      In other words, D-PE enters the "PW receive defect" state for this PW.  After this calculated Detection Time (see Section 6.8.4 of [RFC5880]), D-PE declares the session Down, and signals this to the remote end via the State (Sta) with Diagnostic code 1 (Control Detection Time Expired).   In turn, U-PE declares the PW is down in its transmit direction, setting the State to Down with Diagnostic code 3 (Neighbor signaled session down) in its control messages to D-PE.    U-PE enters the "PW transmit defect" state for this PW.   How it further processes this error condition, and potentially conveys this status to the attachment circuits, is out of the scope of this specification, and is defined in

[OAM-MSG-MAP].

 

BFD状态机的细节在[BFD5880]6.2部分。以下方案为其运行给出例子:当特定数字的时间间隔内(一个操作者提供的数字,称作”Detect Mult” 或者检测时间乘子[RFC5880]),下游PE(D-PE)没有从上游对等PE(U-PE)收到BFD控制信息,D-PE宣布PW在其接收方向down。换句话说,D-PE为这个PW进入”PW receive defect”状态。在计算的检测时间过后(见[RFC5880]6.8.4部分)D_PE宣布会话Down,并通过诊断码Control Detection Time Expired)告知远端其状态。相应的U-PE宣布PW在它的发送方向down。发送诊断码3(Neighbor signaled session dow)给D-PE。U-PE为P进入”PW transmit defect”状态。它再如何处理这个错误情况和潜在地传送状态给相连电路不在此说明书范围内。它被定义在[OAM-MSG-MAP]。

 

    1. BFD Encapsulation

BFD 封装

 

The VCCV message comprises a BFD Control packet [RFC5880]

encapsulated as specified by the CV Type.  There are two ways in

which a BFD connectivity verification packet may be encapsulated over

the VCCV control channel.  This document defines four BFD CV Types

(see Section 3), which can be grouped into two pairs of BFD CV Types

from an encapsulation point of view.  See Table 1 in Section 3, which

summarizes the BFD CV Types.

 

VCCV信息包含一个按CV类型规定封装的BFD控制包。一个BFD连接验证包有两种通过VCCV

控制通道封装的形式。本文件规定了四种BFD CV类型(见第3部分),从封装角度来看,它们可以分为两对BFD CV类型。见第三部分表1中的BFD CV类型总结。

 

o  IP/UDP BFD Encapsulation (BFD with IP/UDP Headers)

  

   IP/UDP BFD 封装 (带IP/UDP头的BFD)

 

In the first method, the VCCV encapsulation of BFD includes the IP/UDP headers as defined in Section 4 of [RFC5881].                            BFD Control packets are therefore transmitted in UDP with destination port

3784 and source port within the range 49152 through 65535.  The IP

 

 

 

Protocol Number and UDP Port numbers discriminate among the possible VCCV payloads (i.e., differentiate among ICMP Ping and LSP Ping defined in [RFC5085] and BFD).

 

在这第一种方法中,BFD的VCCV封装包含定义在[RFC5881]的第4部分的IP/UDP头部.BFD控制包因此传递在UDP目的端口3784源端口49152和65535之间。用IP协议数和UDP端口数区分可能在VCCV上的负载(即,区分 ICMP Ping与定义在RFC[5085]中的LSP Ping 和BFD)。

                  

The IP version (IPv4 or IPv6) MUST match the IP version used for signaling for dynamically established pseudowires or MUST be configured for statically provisioned pseudowires.                                      The source IP address is an address of the sender.                                      The destination IP address is a (randomly chosen) IPv4 address from the range 127/8 or IPv6 address from the range 0:0:0:0:0:FFFF:127.0.0.0/104.         The rationale is explained in Section 2.1 of [RFC4379].                            The Time to Live/Hop Limit and Generalized TTL Security Mechanism (GTSM) procedures from Section 5 of [RFC5881] apply to this encapsulation, and hence the TTL/Hop Limit is set to 255.

 

IP(IPv4 or IPv6)版本必须配备用于发信令以动态建立PW的IP版本或者必须被静态提供的PW所配置。源IP地址是发送者的一个地址。目的IP地址(随机选择)是一个从127/8中随机选择的IPv4,或者从0:0:0:0:0:FFFF:7F00/104中随机选择得IPv6。基本原理在[RFC4379]的2.1部分被解释。时间活性/跳数限制和在RFC5881的第5部分中的普通TTL安全机制(GTSM)程序被应用于此封装,因此TTL/Hop Limit被设为255。

 

If the PW is established by signaling, then the BFD CV Type used for this encapsulation is either 0x04 or 0x08.

 

如果PW通过信令建立,BFD CV封装类型为0x04或者0x08

 

o  PW-ACH BFD Encapsulation (BFD without IP/UDP Headers)

  

   PW—ACH BFD封装 (BFD 不带IP/UDP头部)

 

In the second method, a BFD Control packet (format defined in Section 4 of [RFC5880]) is encapsulated directly in the VCCV control channel (see Sections 6 and 8 of [RFC5882]) and the IP/UDP headers are omitted from the BFD encapsulation. Therefore, to utilize this encapsulation, a pseudowire MUST use the PW

Associated Channel Header (PW-ACH) Control Word format (see [RFC5586]) for its Control Word (CW) or L2-Specific Sublayer (L2SS, used in L2TPv3).

 

在这种封装中,一个BFD控制报文包(格式定义在RFC[5880]第4部分)被直接封装在VCCV控制通道(见[RFC5882]第6部分和第8部分)

 

In this encapsulation, a "raw" BFD Control packet (i.e., a BFD Control packet as defined in Section 4.1 of [RFC5880] without IP/ UDP headers) follows directly the PW-ACH.                                           The PW-ACH Channel Type indicates that the Associated Channel carries "raw" BFD.      The PW Associated Channel (PWAC) is defined in Section 5 of [RFC4385],

and its Channel Type field is used to discriminate the VCCV

payload types.

 

在这种封装中, 一个“raw(未加工)” BFD控制报文(即,一个[RFC5880]第4.1部分中定义的,不含IP/UDP头的控制包)直接跟随 PW-ACH。PW-ACH 通道类型表明关联的通道运输“raw”BFD。 PW关联通道(PWAC)定义在[RFC4385]第5部分。它的chanel type字段被用于区别VCCV负载类型。

 

The usage of the PW-ACH on different VCCV CC Types is specified for CC Type 1, Type 2, and Type 3 respectively in Sections 5.1.1,

5.1.2, and 5.1.3 of [RFC5085], and in all cases requires the use of a CW (see Section 7 of [RFC4385]).                       When VCCV carries PW-ACH- encapsulated BFD (i.e., "raw" BFD), the PW-ACH (pseudowire CW’s or L2SS’) Channel Type MUST be set to 0x0007 to indicate "BFD

Control, PW-ACH-encapsulated" (i.e., BFD without IP/UDP headers; see Section 5.2).                   This is to allow the identification of the encased BFD payload when demultiplexing the VCCV control channel.

 

不同VCCV CC 类型的PW-ACH使用方法规定,对于 CC 类型1 CC类型2 CC类型3分别在RFC[5085]的5.1.1  5.1.2  5.1.3 部分,并且在所用需要用CW的情况中(见[RFC4385]第7部分)。当VCCV 运输PW-ACH 封装的BFD(即, “raw”BFD),PW-ACH(伪线 CW的或者L2SS的)的Channel而来Type必须被设置为 0x0007来表明“BFD 控制,PW-ACH-封装”(即,BFD 不带IP/UDP 头,见5.2部分)。这是为了在解复用VCCV控制通道时允许对被封装的BFD负载的识别。

 

 

 

If the PW is established by signaling, then the BFD CV Type used for this encapsulation is either 0x10 or 0x20.

 

如果PW用信令建立,BFD CV类型的封装类型为0x10或0x20。

 

In summary, for the IP/UDP encapsulation of BFD (BFD with IP/UDP headers), if a PW Associated Channel Header is used, the Channel Type MUST either IPv4 (0x0021) or IPv6 (0x0057).                                                      For the PW-ACH encapsulation of BFD (BFD without IP/UDP headers), the PW Associated Channel Header MUST be used and the Channel Type MUST indicate BFD Control packet (0x0007).

 

总之,对于BFD的IP/UDP封装,如果一个 PW关联的通道头被使用,通道类型必须被表明为IPv4(0x0021)或者IPv6(0x0057)。对于BFD的PW-ACH封装(BFD不带IP/UDP头),PW关联的通道头必须被使用而且通道类型必须被表明为BFD控制包(0x0007)。

 

    1. CV Types for BFD

 

对于BFD的CV类型

 

The CV Type is defined as a bitmask field used to indicate the specific CV Type or Types (i.e., none, one, or more) of VCCV packets that may be sent on the VCCV control channel.                                               The CV Types shown in the table below augment those already defined in [RFC5085].    Their values shown in parentheses represent the numerical value corresponding to the actual bit being set in the CV Type bitfield.

 

CV类型被定义在一个位标域用以表明特定CV或可能被VCCV控制通道发送的VCCV包的类型(即, 没有,一个,或多个)。CV类型见下表,这些类型已定义在[RFC5085]中。括号中的值代表的数值和CV Type 位字段的真实置位情况是一致的。

 

BFD CV Types:

BFD CV 类型:

 

The defined values for the different BFD CV Types for MPLS and

L2TPv3 PWs are:

          

为对于MPLS和L2TPv3 PWs的不同BFD CV类型的定义值如下:

 

Bit (Value)   Description

============  ====================================================

Bit 2 (0x04)  BFD IP/UDP-encapsulated, for PW Fault Detection only

Bit 3 (0x08)  BFD IP/UDP-encapsulated, for PW Fault Detection and

AC/PW Fault Status Signaling

Bit 4 (0x10)  BFD PW-ACH-encapsulated, for PW Fault Detection only

Bit 5 (0x20)  BFD PW-ACH-encapsulated, for PW Fault Detection and

AC/PW Fault Status Signaling

 

It should be noted that four BFD CV Types have been defined by combining two types of encapsulation with two types of functionality; see Table 1 in Section 3.

 

应注意四种BFD CV类型通过两种封装类型和两种功能结合,第三部分表一

 

Given the bidirectional nature of BFD, before selecting a given BFD

CV Type capability to be used in dynamically established pseudowires,

there MUST be common CV Types in the VCCV capability advertised and

received.  That is, only BFD CV Types that were both advertised and

received are available to be selected.  Additionally, only one BFD CV

Type can be used (selecting a BFD CV Type excludes all the remaining

BFD CV Types).

 

 

由于BFD的双向性质,在选择用于动态建立PW的BFD CV类型之前,VCCV中必须有普通类型的CV在发布和接收。也就是说只有BFD CV类型是发送和接受可选的。另外,只有一种BFD CV类型可以被使用。(选择一个BFD CV类型排除了所有剩余的BFD CV类型).

 

 

 

The following list enumerates rules, restrictions, and clarifications on the usage of BFD CV Types:

 

下面列出使用BFD CV类型的规则,限制和说明:

 

 

SHOULD NOT be used when a control

protocol such as LDP [RFC4447] or L2TPV3 [RFC3931] is available

1.  BFD CV Types used for fault detection and status signaling (i.e., CV Types 0x08 and 0x20)

 

 

that can signal the AC/PW status to the remote endpoint of the

PW.  More details can be found in [OAM-MSG-MAP].

 

当控制协议比如LDP[RFC4447]或者L@TPV3[RFC3931]能传送AC/PW状态到PW远端节点时,用于故障检测和状态传输的BFD CV类型(即, 0x08 0x20)不应该被使用.

更多细节可以在[OAM-MSG-MAP]中获得。

 

2.  BFD CV Types used for fault detection only (i.e., CV Types 0x04 and 0x10) can be used whether or not a protocol that can signal AC/PW status is available. This includes both statically provisioned and dynamically signaled pseudowires.

   

    仅用于故障检测 的BFD CV 类型(即,CV类型0x04,0x10)无论是协议发送AC/PW状态是否可行都可以使用。这包括静态提供的和动态建立的PW。

 

 

2.1.  In this case, BFD is used exclusively to detect faults on the PW; if it is desired to convey AC/PW fault status, some means other than BFD are to be used.                                      Examples include

using LDP status messages when using MPLS as a transport (see Section 5.4 of [RFC4447]), and the Circuit Status Attribute Value Pair (AVP) in an L2TPv3 SLI message for L2TPv3 (see Section 5.4.5 of [RFC3931]).

 

这种情况,仅使用 BFD检查PW故障;如果它被要求运输AC/PW 故障状态,将有其他的非BFD方法被使用。比如当使用MPLS作为运输机时使用LDP状态信息(见[RFC3931]5.4.5)。

 

3.  Pseudowires that do not use a CW or L2SS using the PW Associated Channel Header MUST NOT use the BFD CV Types 0x10 or 0x20 (i.e., PW-ACH encapsulation of BFD, without IP/UDP headers).

   

    使用CW的PW或者使用ACH的L2SS不可使用BFD CV类型 0x10 或0x20(即,不带IP/UDP头的BFD的PW-ACH 封装)。

 

3.1.  PWs that use a PW-ACH include CC Type 1 (for both MPLS and L2TPv3 as defined in Sections 5.1.1 and 6.1 of [RFC5085]), and MPLS CC Types 2 and 3 when using a Control Word (as specified in Sections 5.1.2 and 5.1.3 of [RFC5085]).  This restriction stems from the fact that the encapsulation uses the Channel Type in the PW-ACH.

 

      当使用PW-ACH时(在[RFC5085]的5.1.2和5.1.3中规定)PW包括CC type1、(对于MPLS和L2SS的定义在[RFC5085]的5.1.1和6.1中)和MPLS cc type2 ,CC type3(使用控制字的方式)。这种限制源自在PW-ACH中封装使用通道类型。

      注:cc2和cc3可不使用控制字。

     

 

3.2.  PWs that do not use a PW-ACH can use the VCCV BFD encapsulation with IP/UDP headers, as the only VCCV BFD encapsulation supported. Using the IP/UDP encapsulated BFD CV Types allows for the concurrent use of other VCCV CV Types that use an encapsulation with IP headers (e.g., ICMP Ping or LSP Ping defined in [RFC5085]).

     

      不使用PW-ACH的PW可以使用带IP/UDP的VCCVBFD封装,作为唯一的VCCV BFD 支持的封装。使用IP/UDP封装的BFD CV类型允许同时使用使用IP 头封装的其他VCCV CV类型。(例如,ICMP Ping或者定义在[RFC5085]中的LSP Ping)。

 

4. Only a single BFD CV Type can be selected and used.  All BFD CV Types are mutually exclusive.  After selecting a BFD CV Type, a node MUST NOT use any of the other three BFD CV Types.

   

    只用一个BFD CV类型可以被选择和使用。所有的BFD CV类型时互相排斥的,在选择一个BFD CV类型后,一个节点不可使用其他三种BFD CV类型中的任何一种。

 

5.  Once a PE has chosen a single BFD CV Type to use, it MUST continue using it until when the PW is re-signaled.                               In order to change the negotiated and selected BFD CV Type, the PW must be torn down and re-established.

 

一但一个PE已经选择一个BFD CV类型来使用,它必须继续使用它直到当PW被重置时。为了改变以协商和选择的BFD CV类型,PW必须断开并重建。

 

 

 

  1. Capability Selection

 

性能选择

 

The precedence rules for selection of various CC and CV Types is clearly outlined in Section 7 of [RFC5085].                              This section augments these rules when the BFD CV Types defined herein are supported.   The selection of a specific BFD CV Type to use out of the four available CV Types defined is tied to multiple factors, as described in

Section 3.3.  Given that BFD is bidirectional in nature, only CV Types that are both received and sent in VCCV capability signaling advertisement can be selected

 

选择CC和CV类型的优先规则在[RFC5085]第7部分被清楚地列出。这部分讨论了三个规则用于当本文中的BFD CV类型被支持时。使用四种定义的CV类型之外的特定BFD CV类型被绑定在多种因素下,如3.3中所描述的那样。

 

When multiple BFD CV Types are advertised, and after applying the rules in Section 3.3, the set that both ends of the pseudowire have in common is determined.   If the two ends have more than one BFD CV Type in common, the following list of BFD CV Types is considered in the order of the lowest list number CV Type to the highest list number CV Type, and the CV Type with the lowest list number is used:

        

当多个BFD CV类型被通告,然后应用3.3中的规则,PW两端的设置被确定。如果两端有多于一个BFD CV类型,从以下列表中选择最小数字的类型使用

 

  1. 0x20 - BFD PW-ACH-encapsulated (without IP/UDP headers), for PW Fault Detection and AC/PW Fault Status Signaling

 

2.  0x10 - BFD PW-ACH-encapsulated (without IP/UDP headers), for PW Fault Detection only

 

3.  0x08 - BFD IP/UDP-encapsulated, for PW Fault Detection and AC/PW Fault Status Signaling

 

4.  0x04 - BFD IP/UDP-encapsulated, for PW Fault Detection only

 

 

 

5.  IANA Considerations

 

5.1.  MPLS CV Types for the VCCV Interface Parameters Sub-TLV

     

      MPLS CV 类型对于VCCV的接口参数 Sub-TLV

 

The VCCV Interface Parameters Sub-TLV codepoint is defined in [RFC4446], and the VCCV CV Types registry is defined in [RFC5085]. This section lists the new BFD CV Types.

 

VCCV接口参数Sub-TLV定义在[RFC4446],VCCV CV类型注册在[RFC5085].以下列出新增的BFD CV类型。

 

IANA has augmented the "VCCV Connectivity Verification (CV) Types" registry in the Pseudowire Name Spaces reachable from [IANA].                            These are bitfield values.                      CV Type values 0x04, 0x08, 0x10, and 0x20 are specified in Section 3 of this document.

 

MPLS Connectivity Verification (CV) Types: Bit (Value)              Description

============  ====================================================

Bit 2 (0x04)  BFD IP/UDP-encapsulated, for PW Fault Detection only

Bit 3 (0x08)  BFD IP/UDP-encapsulated, for PW Fault Detection and

AC/PW Fault Status Signaling

Bit 4 (0x10)  BFD PW-ACH-encapsulated, for PW Fault Detection only

Bit 5 (0x20)  BFD PW-ACH-encapsulated, for PW Fault Detection and

AC/PW Fault Status Signaling

 

5.2.  PW Associated Channel Type

          

PW 关联通道类型

The PW Associated Channel Types used by VCCV rely on previously allocated numbers from the Pseudowire Associated Channel Types Registry [RFC4385] in the Pseudowire Name Spaces reachable from [IANA].

 

VCCV使用的PW关联通道类型依赖于早先[RFC4385]中提供的PW关联通道类型数字,它在PW 名称空间中可以从[IANA]获得。

         

IANA has reserved a new Pseudowire Associated Channel Type value as follows:

          

          IANA  已经保留了新的PW关联通道类型值

 

Registry:

注册:

 

 

TLV

 

Value   Description                         Follows  Reference

------  ----------------------------------  -------  ---------------

0x0007  BFD Control, PW-ACH encapsulation   No       [This document]

(without IP/UDP Headers)

 

 

 

5.3.  L2TPv3 CV Types for the VCCV Capability AVP

     

      VCCV性能AVP的L2TPv3 CV类型

 

This section lists the new BFD CV Types to be added to the existing "VCCV Capability AVP" registry in the L2TP name spaces.                        The Layer Two Tunneling Protocol "L2TP" Name Spaces are reachable from [IANA].

 

新的BFD CV类型被加到现存的被注册在L2TP名称空间的"VCCV Capability AVP"中。二层通道协议“L2TP”名称空间可以从IANA中获得。

 

IANA has reserved the following L2TPv3 Connectivity Verification (CV) Types in the VCCV Capability AVP Values registry.

 

VCCV Capability AVP (Attribute Type 96) Values

VCCV Capability AVP值

 

----------------------------------------------

L2TPv3 Connectivity Verification (CV) Types: Bit (Value)              Description

============  ====================================================

Bit 2 (0x04)  BFD IP/UDP-encapsulated, for PW Fault Detection only

Bit 3 (0x08)  BFD IP/UDP-encapsulated, for PW Fault Detection and

AC/PW Fault Status Signaling

Bit 4 (0x10)  BFD PW-ACH-encapsulated, for PW Fault Detection only

Bit 5 (0x20)  BFD PW-ACH-encapsulated, for PW Fault Detection and

AC/PW Fault Status Signaling

 

  1. Congestion Considerations

 

阻塞情况

 

The congestion considerations that apply to [RFC5085] apply to this mode of operation as well.                       This section describes explicitly how they apply.

 

 

BFD as a VCCV application is required to provide details on

congestion and bandwidth considerations.  BFD provides with a desired

minimum transmit interval and a required minimum receive interval,

negotiates the transmission interval using these configurable fields,

and has a packet of fixed size (setting the transmission rate).

Therefore, it results in a configuration limited bandwidth

utilization.  As stated in [RFC5085], this is sufficient protection

against congestion as long as BFD’s configured maximum bit-rate is

minimal compared to the bit-rate of the pseudowire the VCCV channel

is associated with.  If the pseudowire bit-rate can’t be guaranteed

to be minimal, like potentially for highly variable bit-rate and/or

congestion responsive pseudowires, BFD will be required to operate

using an adaptive congestion control mechanism (for example,

including a throttled transmission rate on "congestion detected"

situations, and a slow-start after shutdown due to congestion and

until basic connectivity is verified).

 

BFD作为VCCV应用被要求给出阻塞和带宽的详细说明。BFD进行时间间隔协商需要使用报文的三个字段而且它有一个固定大小的包(用以设定传送率)。这导致一个配置限制的带宽使用。如同在[RFC5085]中说明的,有充分的保护防止阻塞,只要BFD配置的最大比特率与PW关联的通道比特率相比是极小的。如果在高变化比特率或者拥塞响应PW时,PW比特率不能保证最小。BFD需要运行适当阻塞控制机制(比如阻塞检测上的节流传送,shutdown后的对于阻塞的慢启动直到基本连接被验证)。

 

 

 

Since the bandwidth utilized by BFD is configuration-limited, the

VCCV channel MUST NOT be rate-limited below this maximum configurable

bandwidth or BFD will not operate correctly.  The VCCV channel could

provide rate-limiting above the maximum BFD rate, to protect from a

misbehaving BFD application, so that it does not conflict and can

coexist.  Additionally, the VCCV channel SHOULD NOT use any

additional congestion control loop that would interfere or negatively

interact with that of BFD.  There are no additional congestion

considerations.

 

由于BFD的使用带宽是配置限制的,VCCV 通道必须是比特率低于最大配置带宽,或者BFD不正确的运行。VCCV通道可以提供 最大BFD率比特率限制 以在BFD应用行为错误时,保护通道。避免冲突。另外VCCV通道不应该使用任何额外的会干涉或者和BFD互相影响的阻塞控制环。这里没有附加阻塞情况。

 

  1. Security Considerations

 

安全情况考虑

 

Routers that implement the additional CV Types defined herein are subject to the same security considerations as defined in [RFC5085], [RFC5880], and [RFC5881]. This specification does not raise any additional security issues beyond these.    The IP/UDP-encapsulated BFD makes use of the TTL/Hop Limit procedures described in Section 5 of [RFC5881], including the use of the Generalized TTL Security

Mechanism (GTSM) as a security mechanism.

 

运行本文定义的CV类型的路由器遵守相同的定义在[RFC5085]、[RFC5880]和[RFC5881]中安全环境。这个规定不会附加任何超出以前提出的安全问题。IP/UDP封装的BFD使用TTL/HOP限制程序,定义在[RFC5881]中,包括GTSM的使用作为安全机制。

 

8.  Acknowledgements

 

This work forks from a previous revision of the PWE3 WG document that resulted in [RFC5085], to which a number of people contributed, including Rahul Aggarwal, Peter B. Busschbach, Yuichi Ikejiri, Kenji Kumaki, Luca Martini, Monique Morrow, George Swallow, and others.

 

Mustapha Aissaoui, Sam Aldrin, Stewart Bryant, Peter B. Busschbach, Annamaria Fulignoli, Vishwas Manral, Luca Martini, Dave McDysan, Ben Niven-Jenkins, Pankil Shah, Yaakov Stein, and George Swallow provided useful feedback and valuable comments and suggestions improving newer versions of this document.

 

9.  References

 

9.1.  Normative References

 

[RFC2119]      Bradner, S., "Key words for use in RFCs to Indicate

Requirement Levels", BCP 14, RFC 2119, March 1997.

 

[RFC4385]      Bryant, S., Swallow, G., Martini, L., and D.

McPherson, "Pseudowire Emulation Edge-to-Edge (PWE3)

Control Word for Use over an MPLS PSN", RFC 4385,

February 2006.

 

[RFC5085]      Nadeau, T. and C. Pignataro, "Pseudowire Virtual Circuit Connectivity Verification (VCCV): A Control Channel for Pseudowires", RFC 5085, December 2007.

 

 

 

[RFC5880]      Katz, D. and D. Ward, "Bidirectional Forwarding

Detection", RFC 5880, June 2010.

 

[RFC5881]      Katz, D. and D. Ward, "Bidirectional Forwarding Detection (BFD) for IPv4 and IPv6 (Single Hop)", RFC 5881, June 2010.

 

[RFC5882]      Katz, D. and D. Ward, "Generic Application of Bidirectional Forwarding Detection (BFD)", RFC 5882, June 2010.

 

9.2.  Informative References

 

[IANA]         Internet Assigned Numbers Authority, "Protocol

Registries", <http://www.iana.org>.

 

[OAM-MSG-MAP]  Aissaoui, M., Busschbach, P., Morrow, M., Martini, L., Stein, Y., Allan, D., and T. Nadeau, "Pseudowire (PW) OAM Message Mapping", Work in Progress, March 2010.

 

[RFC3931]      Lau, J., Townsley, M., and I. Goyret, "Layer Two Tunneling Protocol - Version 3 (L2TPv3)", RFC 3931, March 2005.

 

[RFC4379]      Kompella, K. and G. Swallow, "Detecting Multi-Protocol Label Switched (MPLS) Data Plane Failures", RFC 4379, February 2006.

 

[RFC4446]      Martini, L., "IANA Allocations for Pseudowire Edge to

Edge Emulation (PWE3)", BCP 116, RFC 4446, April 2006.

 

[RFC4447]      Martini, L., Rosen, E., El-Aawar, N., Smith, T., and G. Heron, "Pseudowire Setup and Maintenance Using the Label Distribution Protocol (LDP)", RFC 4447,

April 2006.

 

[RFC5586]      Bocci, M., Vigoureux, M., and S. Bryant, "MPLS Generic

Associated Channel", RFC 5586, June 2009.

 

 

 

Authors’ Addresses

 

Thomas D. Nadeau (editor) BT

BT Centre

81 Newgate Street

London  EC1A 7AJ

United Kingdom

 

EMail: tom.nadeau@bt.com

 

 

Carlos Pignataro (editor) Cisco Systems, Inc.

7200 Kit Creek Road

PO Box 14987

Research Triangle Park, NC  27709

USA

 

EMail: cpignata@cisco.com

一篇掌握BFD技术(一):静态路由与BFD联动配置 配置一个名字为102的BFD会话,使用12.1.1.2对绑定本端接口g0/0/0接口的单跳链路进行检测。2)在AR1与AR2之间建立BFD会话,并与静态路由绑定,实现故障快速检测和路径快速收敛。一旦AR1与AR2之间的链路产生了问题,3S就可以切换到另一条链路上去。Name : 102 // bfd会话状态为up。关闭AR2的g0/0/1口,然后tracert 4.4.4.4。在R2的g0/0/1口抓包查看BFD包文。在AR1上查看BFD信息。发送间隔1000毫秒。接收间隔1000毫秒。 阅读详情

相关推荐

BFD5880-5885.7z

包含RFC5880-5885的内容,全是BFD相关的,网上下载不是那么方便,所以下载下来给大家提供方便,顺便赚点积分

华为路由器学习指南-BFD检测_实验

 BFD(Bidirectional ForwardingDetctcion)用于快速检测系统之间的发送和接收两个方向的通信故障,并在出现故障时通知上层应用。静态BFD单跳检测的主要配置任务如下。使能设备上的全局BFD功能。(可选)配置BFD缺省组播IP地址创建BFD会话的绑定信息,建立BFD组播会话。配置BFD会话的本端和远端标识符单跳检测二层链路配置示例RouterA配置bfdbfd test...

荆盼的博客 1万+

Qt实现仿微信在线聊天工具(服务器、客户端)V1_ 01

在主控类中绑定登录类的信号 void signalLoginOK() ,跳过验证步骤,先实现页面的跳转MyChatToolClient.h文件//登录成功槽函数 private :MyChatToolClient.cpp文件} //登录成功槽函数 void MyChatToolClient :: slotLoginOk() {//关闭登录窗口并释放空间 m_loginWin -> close();//新建并打开聊天窗口 m_chatWin = new ChatWindow;

Leo的博客 1872

BFD的原理及配置

BFD 简述 BFD(Bidirectional Forwarding Detection,双向转发检测)是一个通用的、标准化的、介质无关和协议无关的快速故障检测机制,用于检测IP网络中链路的连通状况,保证设备之间能够快速检测到通信故障,以便能够及时采取措施,保证业务持续运行。 在现有网络中,通常采用以下几种方法检测链路故障: 硬件检测:通过硬件检测信号,如SDH告警,检测链路硬件故障。 Hello报文机制:如果无法通过硬件信号检测故障,通常采用路由协议的Hello报文机制。这种机制检测到故障所需时间比较

奋斗Zalvin_JE(奋斗Zhy)的个人博客 2万+

iOS马甲包过审实战:如何用5天时间搞定4.3审核(附完整代码混淆方案)

本文提供了一套为期五天的高效实战方案,专门解决iOS应用因重复或抄袭问题而被App Store的4.3条款拒绝的难题。方案涵盖深度分析、代码混淆、资源翻新及环境隔离等系统性步骤,并附有完整的代码混淆示例,旨在帮助开发者在合规框架内重塑应用,显著提升过审成功率。

weixin_29234239的博客 147

TPAMI 2025新作LRFormer复现笔记:我的Windows 11 + RTX 4090配置全流程

本文详细记录了在Windows 11系统下使用RTX 4090显卡复现TPAMI 2025顶会论文LRTransformer的完整流程,包括硬件配置、系统优化、Python环境搭建及模型训练中的常见问题解决方案。特别针对Windows平台特有的路径管理、CUDA版本冲突和显存优化等关键技术细节提供了实用指南,帮助开发者高效完成环境搭建和模型训练。

weixin_29094301的博客 412

RFC6020 - YANG语言标准中文

RFC6020 - YANG语言标准中文 2016年08月05日 14:49:04 阅读数:12297 YANG - A Data Modeling Language for the Network Configuration Protocol (NETCONF) 该标准脱胎于草案draft-ietf-netmod-yang,该草案从2008年5月开始,先后经历了13个草案版本,最终于2010年8月成为建议标准(Proposed Standard)。本文档的翻译时间开始于2016年5月12日。

dolphin98629的专栏 1万+

DrissionPage实战:5分钟搞定京东滑块验证码自动登录(附完整轨迹生成代码)

本文详细介绍了如何使用DrissionPage工具实现京东滑块验证码的自动化登录,包括环境配置、滑块缺口识别、拟人化轨迹生成算法及完整登录流程。通过物理运动学模型和智能识别技术,有效提升验证码破解成功率,适用于电商自动化场景。

weixin_29229055的博客 244

RFC5881 翻译

15年看协议时写的 黑色为原文,紫色为翻译,绿色为尚不完全确定意义的内容,蓝色为我校注的内容 Internet Engineering Task Force (IETF) D. Katz Request for Comments: 5881 D. Ward Category: Standards Track ...

ZZ1263的专栏 735

爬虫逆向:Hook 技术原理与实战

Hook 技术​(钩子技术)是一种通过拦截和修改程序执行流程的技术手段。它允许开发者在目标程序的特定位置插入自定义代码,以改变程序的默认行为或获取运行时信息。Hook 技术广泛应用于调试、逆向工程、性能分析、安全防护等领域。Hook 技术在爬虫逆向中非常有用,能够有效获取和修改目标程序的数据。通过合理使用 Hook 工具和技术,可以显著提升爬虫的效率和成功率。但使用时需注意法律和道德问题,确保行为合规。

数据知道的博客 1万+

基于 ESP32 与 TDS 传感器的水培营养液离子浓度自动配比系统设计与实现

本系统以 ESP32 为主控芯片,结合 TDS(总溶解固体)传感器实时监测水培营养液中的离子浓度,通过蠕动泵自动补充浓缩营养液或清水,实现营养液 EC 值的闭环自动配比。系统适用于家庭及小型农场的水培种植场景,可稳定维持营养液浓度在作物生长所需的最佳区间。

weixin_42300449的博客 81

RFC5586:MPLS Generic Associated Channel读书笔记

RFC5586下载地址:http://tools.ietf.org/html//rfc5586

points的专栏 1489

【图像超分】论文复现:新手入门必备!Pytorch实现SRGAN!手把手详细教程!代码注释详尽!可用于训练自己的数据集!实时验证模型性能!绘制PSNR曲线图!附训练好的各放大倍数的模型权重文件!

【图像超分】论文精读:SRResNet/SRGAN【图像超分】论文复现:万字长文!Pytorch实现SRResNet代码修改无报错!踩坑全记录!适合各种深度学习新手!帮助你少走弯路!附修改后的代码和PSNR最优的模型权重文件!请配合上述论文精读文章使用,效果更佳!与原论文描述不一样的实现部分,也即可以修改的部分数据集使用:论文中是ImageNet随机选35000张图像,本文是VOC2012数据集16700张图像。数据集预处理:裁剪大小不同,论文是96×96,本文是88×88。

主要更新底层视觉(去噪、超分等)相关的科研内容,形式为【论文精读】+【论文复现】 6853

网络高可用性技术白皮书(一)

转自 http://blog.163.com/yzc_5001/blog/static/20619634201218105450112/ 网络高可用性技术,基本都可以归入容错技术,即在网络出现故障(错误)时,确保网络能快速恢复。对目前常用的高可用性技术,可以作一个简单的归类: ? 单个设备上的硬件冗余,如双主控、单板热插拔、电源冗余、风扇冗余等; ? 链路捆绑,如以太网...

weixin_34004750的博客 2296

车载以太网:PHY(物理层)介绍

本文以TJA1101芯片为实例介绍了车载以太网PHY(物理层)组成。

kevin1499的博客 6231

Data-Structures-and-Algorithm-Analysis-in-Java.pdf

作者: Weiss, Mark A. 出版社: Addison Wesley Data Structures and Algorithm Analysis in Java is an “advanced algorithms” book that fits between traditional CS2 and Algorithms Analysis courses. In the old ACM Curriculum Guidelines, this course was known as CS7. This text is for readers who want to learn good programming and algorithm analysis skills simultaneously so that they can develop such programs with the maximum amo...

双向转发检测-BFD

BFD简介 双向转发检测BFD(Bidirectional Forwarding Detection)用于快速检测系统之间的通信故障,并在出现故障时通知上层应用。 为了减小设备故障对业务的影响、提高网络的可靠性,设备需要能够尽快检测到与相邻设备间的通信故障,以便能够及时采取措施,从而保证业务继续进行。 现有的故障检测方法主要包括以下几种: 硬件检测:硬件检测的优点是可以很快发现故障,但并...

曹世宏的博客 1万+

LinePhone3.2.7(android端最新版本) sip客户端

SIP客户端For android:LinePhone3.2.7(最新版本),官网地址:http://www.linphone.org/

玩转华为ENSP模拟器系列 | 配置静态BFD检测VPWS PW示例

素材来源:华为路由器配置指南 一边学习一边整理试验笔记,并与大家分享,侵权即删,谢谢支持! 附上汇总贴:玩转华为ENSP模拟器系列 | 合集_COCOgsta的博客-优快云博客_华为模拟器实验 目标 静态BFD检测PW,配置比较简单,报文交互比较少。 组网需求 在MPLS L2VPN组网方案中: PE1和PE2之间建立PW1(主)。 PE1和PE3之间建立PW2(备)。 如图1,要求使用BFD检测主备PW的连通性,当主PW出现故障以后,能够在50ms内将业务切换到备用PW上。

团爸讲算法 1492

计算机控制技术及应用

《计算机控制技术及应用》通过总结作者的科研成果和吸收国内外的先进理论、方法和技术,以计算机控制系统的网络化、开放化、智能化和集成化发展趋势为主线索,主要介绍计算机控制系统的基本概念和计算机控制系统的典型形式,计算机控制系统的数学描述与基本分析方法,以及数字PID控制器、最少拍控制系统、达林算法、状态变量设计法等设计方法及其各种改进算法。重点突出计算机控制系统输入输出通道接口的设计方法和典型控制系统的设计案例与实现方法等。

深度学习工具包 DeepLearningToolbox

深度学习工具包Deprecation notice.-----This toolbox is outdated and no longer maintained.There are much better tools available for deep learning than this toolbox, e.g. [Theano](http://deeplearning.net/software/theano/), [torch](http://torch.ch/) or [tensorflow](http://www.tensorflow.org/)I would suggest you use one of the tools mentioned above rather than use this toolbox.Best, Rasmus.DeepLearnToolbox================A Matlab toolbox for Deep Learning.Deep Learning is a new subfield of machine learning that focuses on learning deep hierarchical models of data.It is inspired by the human brain's apparent deep (layered, hierarchical) architecture.A good overview of the theory of Deep Learning theory is[Learning Deep Architectures for AI](http://www.iro.umontreal.ca/~bengioy/papers/ftml_book.pdf)For a more informal introduction, see the following videos by Geoffrey Hinton and Andrew Ng.* [The Next Generation of Neural Networks](http://www.youtube.com/watch?v=AyzOUbkUf3M) (Hinton, 2007)* [Recent Developments in Deep Learning](http://www.youtube.com/watch?v=VdIURAu1-aU) (Hinton, 2010)* [Unsupervised Feature Learning and Deep Learning](http://www.youtube.com/watch?v=ZmNOAtZIgIk) (Ng, 2011)If you use this toolbox in your research please cite [Prediction as a candidate for learning deep hierarchical models of data](http://www2.imm.dtu.dk/pubdb/views/publication_details.php?id=6284)```@MASTERSTHESIS\{IMM2012-06284, author = "R. B. Palm", title = "Prediction as a candidate for learning deep hierarchical models of data", year = "2012",}```Contact: rasmusbergpalm at gmail dot comDirectories included in the toolbox-----------------------------------`NN/` - A library for Feedforward Backpropagation Neural Networks`CNN/` - A library for Convolutional Neural Networks`DBN/` - A library for Deep Belief Networks`SAE/` - A library for Stacked Auto-Encoders`CAE/` - A library for Convolutional Auto-Encoders`util/` - Utility functions used by the libraries`data/` - Data used by the examples`tests/` - unit tests to verify toolbox is workingFor references on each library check REFS.mdSetup-----1. Download.2. addpath(genpath('DeepLearnToolbox'));Example: Deep Belief Network---------------------```matlabfunction test_example_DBNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit RBM and visualize its weightsrand('state',0)dbn.sizes = [100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);figure; visualize(dbn.rbm{1}.W'); % Visualize the RBM weights%% ex2 train a 100-100 hidden unit DBN and use its weights to initialize a NNrand('state',0)%train dbndbn.sizes = [100 100];opts.numepochs = 1;opts.batchsize = 100;opts.momentum = 0;opts.alpha = 1;dbn = dbnsetup(dbn, train_x, opts);dbn = dbntrain(dbn, train_x, opts);%unfold dbn to nnnn = dbnunfoldtonn(dbn, 10);nn.activation_function = 'sigm';%train nnopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.10, 'Too big error');```Example: Stacked Auto-Encoders---------------------```matlabfunction test_example_SAEload mnist_uint8;train_x = double(train_x)/255;test_x = double(test_x)/255;train_y = double(train_y);test_y = double(test_y);%% ex1 train a 100 hidden unit SDAE and use it to initialize a FFNN% Setup and train a stacked denoising autoencoder (SDAE)rand('state',0)sae = saesetup([784 100]);sae.ae{1}.activation_function = 'sigm';sae.ae{1}.learningRate = 1;sae.ae{1}.inputZeroMaskedFraction = 0.5;opts.numepochs = 1;opts.batchsize = 100;sae = saetrain(sae, train_x, opts);visualize(sae.ae{1}.W{1}(:,2:end)')% Use the SDAE to initialize a FFNNnn = nnsetup([784 100 10]);nn.activation_function = 'sigm';nn.learningRate = 1;nn.W{1} = sae.ae{1}.W{1};% Train the FFNNopts.numepochs = 1;opts.batchsize = 100;nn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.16, 'Too big error');```Example: Convolutional Neural Nets---------------------```matlabfunction test_example_CNNload mnist_uint8;train_x = double(reshape(train_x',28,28,60000))/255;test_x = double(reshape(test_x',28,28,10000))/255;train_y = double(train_y');test_y = double(test_y');%% ex1 Train a 6c-2s-12c-2s Convolutional neural network %will run 1 epoch in about 200 second and get around 11% error. %With 100 epochs you'll get around 1.2% errorrand('state',0)cnn.layers = { struct('type', 'i') %input layer struct('type', 'c', 'outputmaps', 6, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %sub sampling layer struct('type', 'c', 'outputmaps', 12, 'kernelsize', 5) %convolution layer struct('type', 's', 'scale', 2) %subsampling layer};cnn = cnnsetup(cnn, train_x, train_y);opts.alpha = 1;opts.batchsize = 50;opts.numepochs = 1;cnn = cnntrain(cnn, train_x, train_y, opts);[er, bad] = cnntest(cnn, test_x, test_y);%plot mean squared errorfigure; plot(cnn.rL);assert(er<0.12, 'Too big error');```Example: Neural Networks---------------------```matlabfunction test_example_NNload mnist_uint8;train_x = double(train_x) / 255;test_x = double(test_x) / 255;train_y = double(train_y);test_y = double(test_y);% normalize[train_x, mu, sigma] = zscore(train_x);test_x = normalize(test_x, mu, sigma);%% ex1 vanilla neural netrand('state',0)nn = nnsetup([784 100 10]);opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samples[nn, L] = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.08, 'Too big error');%% ex2 neural net with L2 weight decayrand('state',0)nn = nnsetup([784 100 10]);nn.weightPenaltyL2 = 1e-4; % L2 weight decayopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex3 neural net with dropoutrand('state',0)nn = nnsetup([784 100 10]);nn.dropoutFraction = 0.5; % Dropout fraction opts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex4 neural net with sigmoid activation functionrand('state',0)nn = nnsetup([784 100 10]);nn.activation_function = 'sigm'; % Sigmoid activation functionnn.learningRate = 1; % Sigm require a lower learning rateopts.numepochs = 1; % Number of full sweeps through dataopts.batchsize = 100; % Take a mean gradient step over this many samplesnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex5 plotting functionalityrand('state',0)nn = nnsetup([784 20 10]);opts.numepochs = 5; % Number of full sweeps through datann.output = 'softmax'; % use softmax outputopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, train_x, train_y, opts);[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');%% ex6 neural net with sigmoid activation and plotting of validation and training error% split training data into training and validation datavx = train_x(1:10000,:);tx = train_x(10001:end,:);vy = train_y(1:10000,:);ty = train_y(10001:end,:);rand('state',0)nn = nnsetup([784 20 10]); nn.output = 'softmax'; % use softmax outputopts.numepochs = 5; % Number of full sweeps through dataopts.batchsize = 1000; % Take a mean gradient step over this many samplesopts.plot = 1; % enable plottingnn = nntrain(nn, tx, ty, opts, vx, vy); % nntrain takes validation set as last two arguments (optionally)[er, bad] = nntest(nn, test_x, test_y);assert(er < 0.1, 'Too big error');```[![Bitdeli Badge](https://d2weczhvl823v0.cloudfront.net/rasmusbergpalm/deeplearntoolbox/trend.png)](https://bitdeli.com/free "Bitdeli Badge")

玩转华为ENSP模拟器系列 | 配置多段拼接场景下的伪线BFD示例

素材来源:华为路由器配置指南 一边学习一边整理试验笔记,并与大家分享,侵权即删,谢谢支持! 附上汇总贴:玩转华为ENSP模拟器系列 | 合集_COCOgsta的博客-优快云博客_ensp实验大全 目标 验证在多段伪线拼接场景下,BFD for 主备伪线中BFD报文的收发情况 组网需求 配置思路 配置OSPF和LDP邻居。 R1与R2/R3之间启用主备伪线,并启用BFD for 主备伪线。同理R8与R5/R6也启用主备伪线,并启用BFD for 主备伪线。 R2/R3/R4/R5/R6

团爸讲算法 1099

1.1.0 IGP高级特性之BFD

BFD(Bidirectional Forwarding Detection,双向转发检测),报文字段、工作原理,BFD Echo、BFD多跳检测与单跳检测,BFD与OSPF、BGP进行联动实现网络故障的快速感知。

Hades_Ling的优快云博客 2375

RFC5880(BFD)中文翻译

双向转发检测(RFC5880) 文天 2017年11月10日     写在前面:文档由译者根据我司BFD关心的功能将RFC5880中相应章节翻译成中文,由于水平有限,必然有理解不准确的地方,仅供参考,严格的协议标准以RFC5880文档为准。     目录 1. 简介 3 1.1 文档中的约定 3 2. 设计 3 3. 协议综述 3 3.1 定址和会话建立 3 4. BF

淮南子 5663

BFD学习笔记

BFD(Bridirectional Forwarding Detection,双向转发检测机制)是一种基于RFC 5880标准的高速故障检测机制,用于快速检测、监控网络中链路或者IP路由的转发连通状况。

qq_34659299的博客 322

华为 BFD协议的介绍以及配置示例故障分析和常见问题

华为设备支持的BFD协议是一种快速、轻量级的网络故障检测机制,能够在各种网络层次上提供低延迟的故障检测能力。BFD的设计独立于任何特定的网络层协议,这意味着它可以应用于从数据链路层到网络层乃至更高层的各种环境,为上层协议和服务提供快速的故障通知,进而加速网络收敛和恢复过程。

满地找牙的博客 2597

RFC5880 6.8节翻译

1 介绍 (p1) 2设计 (p4) 3 协议概述(p5) 4控制报文封装格式(p5) 5 Echo报文格式 6 原理 6.1概述 6.2 BFD状态机 6.3 解复用和Discriminator字段 6.4 Echo与不对称 6.5 The Poll Sequence调查序列 6.6 Demend Mode查询模式 6.7 认证 6.7.1 启用与禁用认证 6.7.2 simple 6.7.3 MD5 6.7.4 SHA1 6.8 功...

ZZ1263的专栏 898

RFC4385:PWE3 Control Word for Use over an MPLS PSN读书笔记

http://tools.ietf.org/html//rfc4385RFC4385定义了PWE3控制字,避免PW包被当做IP包解析。

points的专栏 1840

MPLS PW Control Word与Associated Channel

RFC4385定义了在MPLS PW中使用的Control Word和Associated Channel,即在LSP label和PW Label后面,可以跟Control Word或者Associated Channel两个结构化字段。这两个东西有什么用呢? 在MPLS P

hongsiye的专栏 4079

BFD协议解析及C/C++代码实现

为了最大限度地减少设备/链路故障对业务的影响,提高网络可用性,网络设备必须能够快速检测到与相邻设备的通信故障。然后可以采取措施及时纠正故障,以确保服务的连续性。 而 BFD (双向转发检测)是一种故障检测协议,可以快速确定两个转发引擎之间的通信故障。 BFD Control 数据包格式 BFD 控制数据包有一个强制部分和一个可选认证部分。 认证部分的格式,如果目前,取决于使用的身份验证类型。 BFD Control 数据包强制部分 BFD 控制数据包的强制部分具有以下内容格式: Version (Ver

chen1415886044的博客 2599
上一篇: RFC5884 翻译
下一篇: C语言中的隐式函数声明
著我扁舟一叶
博客等级 码龄15年 61粉丝 15原创
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符
 
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

个

红包个数最小为10个

元

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00元
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付元
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值