Please Whitelist This Site?

I know everyone hates ads. But please understand that I am providing premium content for free that takes hundreds of hours of time to research and write. I don't want to go to a pay-only model like some sites, but when more and more people block ads, I end up working for free. And I have a family to support, just like you. :)

If you like The TCP/IP Guide, please consider the download version. It's priced very economically and you can read all of it in a convenient format without ads.

If you want to use this site for free, I'd be grateful if you could add the site to the whitelist for Adblock. To do so, just open the Adblock menu and select "Disable on". Or go to the Tools menu and select "Adblock Plus Preferences...". Then click "Add Filter..." at the bottom, and add this string: "@@||^$document". Then just click OK.

Thanks for your understanding!

Sincerely, Charles Kozierok
Author and Publisher, The TCP/IP Guide

NOTE: Using software to mass-download the site degrades the server and is prohibited.
If you want to read The TCP/IP Guide offline, please consider licensing it. Thank you.

The Book is Here... and Now On Sale!

Get The TCP/IP Guide for your own computer.
The TCP/IP Guide

Custom Search

Table Of Contents  The TCP/IP Guide
 9  TCP/IP Lower-Layer (Interface, Internet and Transport) Protocols (OSI Layers 2, 3 and 4)
      9  TCP/IP Internet Layer (OSI Network Layer) Protocols
           9  TCP/IP Routing Protocols (Gateway Protocols)
                9  TCP/IP Exterior Gateway/Routing Protocols (BGP and EGP)
                     9  TCP/IP Border Gateway Protocol (BGP/BGP-4)
                          9  BGP Detailed Messaging, Operation and Message Formats

Previous Topic/Section
BGP Connectivity Maintenance: Keepalive Messages
Previous Page
Pages in Current Topic/Section
Next Page
TCP/IP Exterior Gateway Protocol (EGP)
Next Topic/Section

BGP Error Reporting: Notification Messages
(Page 3 of 3)

BGP Notification Message Error Codes and Error Subcodes

Table 142 and Table 143 show the values permitted for the Error Code and Error Subcode fields, respectively, and thus provide a good summary of the types of errors that Notification messages can report (as well as demonstrating the other non-error uses of the message type).

Table 142: BGP Notification Message Error Codes

Error Code Value

Code Name



Message Header Error

A problem was detected either with the contents or length of the BGP header. The Error Subcode provides more details on the nature of the problem.


Open Message Error

A problem was found in the body of an Open message. The Error Subtype field describes the problem in more detail. Note that authentication failures or inability to agree on a parameter such as hold time are included here.


Update Message Error

A problem was found in the body of an Update message. Again, the Error Subtype provides more information. Many of the problems that fall under this code are related to issues detected in the routing data or path attributes sent in the Update message, so these messages provide feedback about such problems to the device sending the erroneous data.


Hold Timer Expired

A message was not received before the hold time expired. See the description of the Keepalive message for details on this timer.


Finite State Machine Error

The BGP finite state machine refers to the mechanism by which the BGP software on a peer moves from one operating state to another based on events (see the TCP finite state machine description for some background on this concept). If an event occurs that is unexpected for the state the peer is currently in, it will generate this error.



Used when a BGP device wants to break the connection to a peer for a reason not related to any of the error conditions described by the other codes.

Table 143: BGP Notification Message Error Subcodes

Error Type

Error Subcode Value

Subcode Name


Message Header Error (Error Code 1)


Connection Not Synchronized

The expected value in the Marker field was not found, indicating that the connection has become unsynchronized. See the description of the Marker field.


Bad Message Length

The message was less than 19 bytes, greater than 4096 bytes, or not consistent with what was expected for the message type.


Bad Message Type

The Type field of the message contains an invalid value.

Open Message Error (Error Code 2)


Unsupported Version Number

The device does not “speak” the version number its peer is trying to use.


Bad Peer AS

The router doesn't recognize the peer's autonomous system number or is not willing to communicate with it.


Bad BGP Identifier

The BGP Identifier field is invalid.


Unsupported Optional Parameter

The Open message contains an optional parameter that the recipient of the message doesn't understand.


Authentication Failure

The data in the Authentication Information optional parameter could not be authenticated.


Unacceptable Hold Time

The router refuses to open a session because the proposed hold time its peer specified in its Open message is unacceptable.

Update Message Error (Error Code 3)


Malformed Attribute List

The overall structure of the message's path attributes is incorrect, or an attribute has appeared twice.


Unrecognized Well-Known Attribute

One of the mandatory well-known attributes was not recognized.


Missing Well-Known Attribute

One of the mandatory well-known attributes was not specified.


Attribute Flags Error

An attribute has a flag set to a value that conflicts with the attribute's type code.


Attribute Length Error

The length of an attribute is incorrect.


Invalid Origin Attribute

The Origin attribute has an undefined value.


AS Routing Loop

A routing loop was detected.


Invalid Next_Hop Attribute

The Next_Hop attribute is invalid.


Optional Attribute Error

An error was detected in an optional attribute.


Invalid Network Field

The Network Layer Reachability Information field is incorrect.


Malformed AS_Path

The AS_Path attribute is incorrect.

Note that, perhaps ironically, no mechanism exists to report an error in a Notification message itself. This is likely because the connection is normally terminated after such a message is sent.

Key Concept: BGP Notification messages are used for error reporting between BGP peers. Each message contains an Error Code field that indicates what type of problem occurred. For certain Error Codes, an Error Subcode field provides additional details about the specific nature of the problem. Despite these field names, Notification messages are also used for other types of special non-error communication, such as terminating a BGP connection.


Previous Topic/Section
BGP Connectivity Maintenance: Keepalive Messages
Previous Page
Pages in Current Topic/Section
Next Page
TCP/IP Exterior Gateway Protocol (EGP)
Next Topic/Section

If you find The TCP/IP Guide useful, please consider making a small Paypal donation to help the site, using one of the buttons below. You can also donate a custom amount using the far right button (not less than $1 please, or PayPal gets most/all of your money!) In lieu of a larger donation, you may wish to consider purchasing a download license of The TCP/IP Guide. Thanks for your support!
Donate $2
Donate $5
Donate $10
Donate $20
Donate $30
Donate: $

Home - Table Of Contents - Contact Us

The TCP/IP Guide (
Version 3.0 - Version Date: September 20, 2005

Copyright 2001-2005 Charles M. Kozierok. All Rights Reserved.
Not responsible for any loss resulting from the use of this site.