rfc823.txt
来自「RFC 的详细文档!」· 文本 代码 · 共 2,611 行 · 第 1/5 页
TXT
2,611 行
DARPA Internet Gateway September 1982
RFC 823
gateway is directly connected to the network. A neighbor gateway
is one which shares a common network with this gateway. The
distance metric that is used to determine which neighbor is
closest is defined as the "number of hops," where a gateway is
considered to be zero hops from its directly connected networks,
one hop from a network that is reachable via one other gateway,
etc. The Gateway-to-Gateway Protocol (GGP) is used to update the
Routing Table (see Section 4.4 describing the Gateway-to-Gateway
Protocol).
The gateway tries to match the destination network address
in the IP header of the datagram to be forwarded, with a network
in its Routing Table. If no match is found, the gateway drops
the datagram and sends an ICMP Destination Unreachable message to
the IP source. If the gateway does find an entry for the network
in its table, it will use the network address of the neighbor
gateway entry as the local network destination address of the
datagram. However, if the final destination network is one that
the gateway is directly connected to, the destination address in
the local network header is created from the destination address
in the IP header of the datagram.
-8-
DARPA Internet Gateway September 1982
RFC 823
3.4 Redirects
If the routing procedure decides that an IP datagram is to
be sent back out the same network interface that it was read in,
then this gateway is not on the shortest path to the IP final
destination. Nevertheless, the datagram will still be forwarded
to the next address chosen by the routing procedure. If the
datagram is not using the IP Source Route Option, and the IP
source network of the datagram is the same as the network of the
next gateway chosen by the routing procedure, an ICMP Redirect
message will be sent to the IP source host indicating that
another gateway should be used to send traffic to the final IP
destination.
3.5 Fragmentation
The datagram is passed to the fragmentation routine after
the routing decision has been made. If the next network through
which the datagram must pass has a maximum message size that is
smaller than the size of the datagram, the datagram must be
fragmented. Fragmentation is performed according to the
algorithm described in the Internet Protocol Specification [1].
Certain IP options must be copied into the IP header of all
-9-
DARPA Internet Gateway September 1982
RFC 823
fragments, and others appear only in the first fragment according
to the IP specification. If a datagram must be fragmented, but
the Don't fragment bit is set, the datagram is discarded and an
ICMP error message is sent to the IP source of the datagram.
3.6 Header Rebuild
The datagram (or the fragments of the original datagram if
fragmentation was needed) is next passed to a routine that
rebuilds the Internet header. The Time to Live field is
decremented by one and the IP checksum is recomputed.
The local network header is now built. Using the
information obtained from its routing procedure, the gateway
chooses the network interface it considers proper to send the
datagram and to build the destination address in the local
network header.
3.7 Output
The datagram is now enqueued on an output queue for delivery
towards its destination. A limit is enforced on the size of the
output queue for each network interface so that a slow network
-10-
DARPA Internet Gateway September 1982
RFC 823
does not unfairly use up all of the gateway's buffers. If a
datagram cannot be enqueued due to the limit on the output queue
length, it is dropped and an HMP trap is sent to the INOC. These
traps, and others of a similar nature, are used by operational
personnel to monitor the operations of the gateways.
-11-
DARPA Internet Gateway September 1982
RFC 823
4 PROTOCOLS SUPPORTED BY THE GATEWAY
A number of protocols are supported by the gateway to
provide dynamic routing, monitoring, debugging, and error
reporting. These protocols are described below.
4.1 Cross-Net Debugging Protocol
The Cross-Net Debugging Protocol (XNET) [8] is used to load
the gateway and to examine and deposit data. The gateway
supports the following XNET op-codes:
o NOP
o Debug
o End Debug
o Deposit
o Examine
o Create Process
4.2 Host Monitoring Protocol
The Host Monitoring Protocol (HMP) [6] is used to collect
measurements and status information from the gateways.
Exceptional conditions in the gateways are reported in HMP traps.
The status of a gateway's interfaces, neighbors, and the networks
which it can reach are reported in the HMP status message.
-12-
DARPA Internet Gateway September 1982
RFC 823
Two types of gateway statistics, the Host Traffic Matrix and
the gateway throughput, are currently defined by the HMP. The
Host Traffic Matrix records the number of datagrams that pass
through the gateway with a given IP source, destination, and
protocol number. The gateway throughput message collects a
number of important counters that are kept by the gateway. The
current gateway reports the following values:
o Datagrams dropped because destination net unreachable
o Datagrams dropped because destination host unreachable
o Per Interface:
Datagrams received with IP errors
Datagrams received for this gateway
Datagrams received to be forwarded
Datagrams looped
Bytes received
Datagrams sent, originating at this gateway
Datagrams sent to destination hosts
Datagrams dropped due to flow control limitations
Datagrams dropped due to full queue
Bytes sent
o Per Neighbor:
Routing updates sent to
Routing updates received from
Datagrams sent, originating here
Datagrams forwarded to
Datagrams dropped due to flow control limitations
Datagrams dropped due to full queue
Bytes sent
-13-
DARPA Internet Gateway September 1982
RFC 823
4.3 ICMP
The gateway will generate the following ICMP messages under
appropriate circumstances as defined by the ICMP specification
[4]:
o Echo Reply
o Destination Unreachable
o Source Quench
o Redirect
o Time Exceeded
o Parameter Problem
o Information Reply
4.4 Gateway-to-Gateway Protocol
The gateway uses the Gateway-to-Gateway Protocol (GGP) to
determine connectivity to networks and neighbor gateways; it is
also used in the implementation of a dynamic, shortest-path
routing algorithm. The current GGP message formats (for release
1003 of the gateway software) are presented in Appendix A.
4.4.1 Determining Connectivity to Networks
When a gateway starts running it assumes that all its
neighbor gateways are "down," that it is disconnected from
-14-
DARPA Internet Gateway September 1982
RFC 823
networks to which it is attached, and that the distance reported
in routing updates from each neighbor to each network is
"infinity."
The gateway first determines the state of its connectivity
to networks to which it is physically attached. The gateway's
connection to a network is declared up if it can send and receive
internet datagrams on its interface to that network. Note that
the method that the gateway uses to determine its connectivity to
a network is network-dependent. In some networks, the host-to-
network protocol determines whether or not datagrams can be sent
and received on the host interface. In these networks, the
gateway simply checks-status information provided by the protocol
in order to determine if it can communicate with the network. In
other networks, where the host-to-network protocols are less
sophisticated, it may be necessary for the gateway to send
datagrams to itself to determine if it can communicate with the
network. In these networks, the gateways periodically poll the
network using GGP network interface status messages [Appendix A]
to determine if the network interface is operational.
The gateway has two rules relevant to computing distances to
networks: 1) if the gateway can send and receive traffic on its
-15-
DARPA Internet Gateway September 1982
RFC 823
network interface, its distance to the network is zero; 2) if it
cannot send and receive traffic on the interface, its distance to
the network is "infinity." Note that if a gateway's network
interface is not working, it may still be able to send traffic to
the network on an alternate route via one of its neighbor
gateways.
4.4.2 Determining Connectivity to Neighbors
The gateway determines connectivity to neighbors using a "K
out of N" algorithm. Every 15 seconds, the gateway sends GGP
Echo messages [Appendix A] to each of its neighbors. The
neighbors respond by sending GGP echo replies. If there is no
reply to K out of N (current values are K=3 and N=4) echo
messages sent to a neighbor, the neighbor is declared down. If a
neighbor is down and J out of M (current values are J=2 and M=4)
echo replies are received, the neighbor is declared to be up.
The values of J,K,M,N and the time interval are operational
parameters which can be adjusted as required.
-16-
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?