📄 rfc969.txt
字号:
RFC 969 December 1985NETBLT: A Bulk Data Transfer Protocol Timer value estimation is extremely important, especially in a high-performance protocol like NETBLT. If the estimates are too low, the protocol makes many unneeded retransmissions, degrading performance. A short control timer value causes the sending NETBLT to receive duplicate control messages (which it can reject, but which takes time). A short data timer value causes the receiving NETBLT to send unnecessary RESEND packets. This causes considerably greater performance degradation since the sending NETBLT does not merely throw away a duplicate packet, but instead has to send a number of DATA packets. Because data timers are set on each buffer transfer instead of on each DATA packet transfer, we afford to use a small variance value without worrying about performance degradation. 5.3. Closing the Connection There are three ways to close a connection: a connection close, a "quit", or an "abort". The connection close occurs after a successful data transfer. When the sending NETBLT has received an OK packet for the last buffer in the transfer, it sends a DONE packet <2>. On receipt of the DONE packet, the receiving NETBLT can close its half of the connection. The sending NETBLT dallies for a predetermined amount of time after sending the DONE packet. This allows for the possibility of the DONE packet's having been lost. If the DONE packet was lost, the receiving NETBLT will continue to send the final OK packet, which will cause the sending end to resend the DONE packet. After the dally period expires, the sending NETBLT closes its half of the connection. During the transfer, one client may send a QUIT packet to the other if it thinks that the other client is malfunctioning. Since the QUIT occurs at a client level, the QUIT transmission can only occur between buffer transmissions. The NETBLT receiving the QUIT packet can take no action other than to immediately notify its client and transmit a QUITACK packet. The QUIT sender must time out and retransmit until a QUITACK has been received or a predetermined number of resends have taken place. The sender of the QUITACK dallies in the manner described above. An ABORT takes place when a NETBLT layer thinks that it or its opposite is malfunctioning. Since the ABORT originates in the NETBLT layer, it can be sent at any time. Since the ABORT implies that the NETBLT layer is malfunctioning, no transmit reliability is expected, and the sender can immediately close it connection.Clark & Lambert & Zhang [Page 11]RFC 969 December 1985NETBLT: A Bulk Data Transfer Protocol6. MULTIPLE BUFFERING In order to increase performance, NETBLT has been designed in a manner that encourages a multiple buffering implementation. Multiple buffering is a technique in which the sender and receiver allocate and transmit buffers in a manner that allows error recovery of previous buffers to be concurrent with transmission of current buffer. During the connection setup phase, one of the negotiated parameters is the number of concurrent buffers permitted during the transfer. The simplest transfer allows for a maximum of one buffer to be transmitted at a time; this is effectively a lock-step protocol and causes time to be wasted while the sending NETBLT receives permission to send a new buffer. If there are more than one buffer available, transfer of the next buffer may start right after the current buffer finishes. For example, assume buffer A and B are allowed to transfer concurrently, with A preceding B. As soon as A finishes transferring its data and is waiting for either an OK or a RESEND message, B can start sending immediately, keeping data flowing at a stable rate. If A receives an OK, it is done; if it receives a RESEND, the missing packets specified in the RESEND message are retransmitted. All packets flow out through a priority pipe, with the priority equal to the buffer number, and with the transfer rate specified by the burst size and burst rate. Since buffer numbers increase monotonically, packets from an earlier buffer in the pipe will always precede those of the later ones. One necessary change to the timing algorithm is that when the receiving NETBLT set data timer for a new buffer, the timer value should also take into consideration of the transfer time for all missing packets from the previous buffers. Having several buffers transmitting concurrently is actually not that much more complicated than transmitting a single buffer at a time. The key is to visualize each buffer as a finite state machine; several buffers are merely a group of finite state machines, each in one of several states. The transfer process consists of moving buffers through various states until the entire transmission has completed. The state sequence of a send-receive buffer pair is as follows: the sending and receiving buffers are created independently. The receiving NETBLT sends a GO message, putting its buffer in a "receiving" state, and sets its control timer; the sending NETBLT receives the GO message, putting its buffer into a "sending" state. The sending NETBLT sends data until the buffer has been transmitted. If the receiving NETBLT's data timer goes off before it received the last (LDATA) packet, or it receives the LDATA packet in the bufferClark & Lambert & Zhang [Page 12]RFC 969 December 1985NETBLT: A Bulk Data Transfer Protocol and packets are missing, it sends a RESEND packet and moves the buffer into a "resending" state. Once all DATA packets in the buffer and the LDATA packet have been received, the receiving NETBLT enters its buffer into a "received" state and sends an OK packet. The sending NETBLT receives the OK packet and puts its buffer into a "sent" state.7. PROTOCOL LAYERING STRUCTURE NETBLT is implemented directly on top of the Internet Protocol (IP). It has been assigned a temporary protocol number of 255. This number will change as soon as the final protocol specification has been determined.8. PACKET FORMATS NETBLT packets are divided into three categories, each of which share a common packet header. First, there are those packets that travel only from sender to receiver; these contain the control message sequence numbers which the receiver uses for reliability. These packets are the NULL-ACK, DATA, and LDATA packets. Second, there is a packet that travels only from receiver to sender. This is the CONTROL packet; each CONTROL packet can contain an arbitrary number of control messages (GO, OK, or RESEND), each with its own sequence number. Finally, there are those packets which either have special ways of insuring reliability, or are not reliably transmitted. These are the QUIT, QUITACK, DONE, KEEPALIVE, and ABORT packets. Of these, all save the DONE packet can be sent by both sending and receiving NETBLTs. Packet type numbers: OPEN: 0 RESPONSE: 1 KEEPALIVE: 2 DONE: 3 QUIT: 4 QUITACK: 5 ABORT: 6 DATA: 7 LDATA: 8 NULL-ACK: 9 CONTROL: 10Clark & Lambert & Zhang [Page 13]RFC 969 December 1985NETBLT: A Bulk Data Transfer Protocol Standard header: local port: 2 bytes foreign port: 2 bytes checksum: 2 bytes version number: 1 byte packet type: 1 byte packet length: 2 bytes OPEN and RESPONSE packets: connection unique ID: 4 bytes standard buffer size: 4 bytes transfer size: 4 bytes DATA packet data segment size: 2 bytes burst size: 2 bytes burst rate: 2 bytes death timeout value in seconds: 2 bytes transfer mode (1 = SEND, 0 = RECEIVE): 1 byte maximum number of concurrent buffers: 1 byte checksum entire DATA packet / checksum DATA packet data only (1/0): 1 byte client-specific data: arbitrary DONE, QUITACK, KEEPALIVE: standard header only ABORT, QUIT: reason: arbitrary bytes CONTROL packet format: CONTROL packets consist of a standard NETBLT header of type CONTROL, followed by an arbitrary number of control messages with the following formats: Control message numbers: GO: 0 OK: 1 RESEND: 2Clark & Lambert & Zhang [Page 14]RFC 969 December 1985NETBLT: A Bulk Data Transfer Protocol OK message: message type (OK): 1 byte buffer number: 4 bytes sequence number: 2 bytes new burst size: 2 bytes new burst interval: 2 bytes GO message: message type (GO): 1 byte buffer number: 4 bytes sequence number: 2 bytes RESEND message: message type (RESEND): 1 byte buffer number: 4 bytes sequence number: 2 bytes number of missing packets: 2 bytes packet numbers...: n * 2 bytes DATA, LDATA packet formats: buffer number: 4 bytes highest consecutive sequence number received: 2 bytes packet number within buffer: 2 bytes data: arbitrary bytes NULL-ACK packet format: highest consecutive sequence number received: 2 bytes acknowledged new burst size: 2 bytes acknowledged new burst interval: 2 bytesNOTES: <1> When the buffer size is large, the variances in the round trip delays of many packets may cancel each other out; this means the variance value need not be very big. This expectation can be verified in further testing. <2> Since the receiving end may not know the transfer size in advance, it is possible that it may have allocated buffer space and sent GO messages for buffers beyond the actual last buffer sent by the sending end. Care must be taken on the sending end's part to ignore these extra GO messages.Clark & Lambert & Zhang [Page 15]
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -