relay

Section: WIN SYSTEM (1W)
Updated: 2005.5.18
Index Return to Main Contents
 

NAME

relay, relayd - relay of win format data on IP  

SYNOPSIS

relay [-NnrD] [-b bufsiz] [-d delay] [-f ctlfile] [-g group] [-i interface] [-p src_port] [-s sinterface] [-t ttl] inport dest outport [ logfile ]

relayd [-Nnr] [-b bufsiz] [-d delay] [-f ctlfile] [-g group] [-i interface] [-p src_port] [-s sinterface] [-t ttl] inport dest outport [ logfile ]  

DESCRIPTION

Relay receives win format data sent to the UDP port number  inport of its own host and transmits to the UDP port number  outport of host  dest. Although relay inspects packet number of received packet, it does not inspect time stamp.

However, when 0 is specified to  inport it reads data in line unit from the standard input instead of the UDP port. Data of one line including line feed code are transmitted to  outport as one UDP packet. At that time, a packet number of 2 bytes (1 byte each of "current" packet number and "original" packet number) is added to the head. When the line head characters are ^D(0x04) or end-of-file is detected, relay ends. This operation is utilized for delivery of text data.

Relayd is initiated in daemon mode. It is the same operation as when option -D is specified by relay.

When log file name  logfile is specified, operation log is set here. When it is not specified, log information is sent to the standard output (however, it is sent to syslogd(8) when operation is made in the daemon mode). The log file is opened/closed in each write.

When relay receives the HUP signal, it rereads control file (if specified, as described later)  ctlfile and send it to log file  logfile to write flow rate information on each source host. It includes

  number of packets, number of bytes, number of packets per second, number of bytes per second
since startup or the previous time it received the HUP signal.

When relay is initiated without argument, brief usage is displayed.  

Format on networks and resend protocol

Refer to recvt(1W). Relay can monitor continuity of packet number to recognize up to 100 sources (a set of host and port) as targets to which resend to be requested. If the number of sources exceeds 100, recvt once cancels all the data of source table and restarts registration.  

OPTIONS

-b bufsiz
Makes receiving socket buffer size bufsiz KB. However, the value must be within a range allowed by the system. Default is 256KB.
-D
Is initiated in the daemon mode.
-d delay
When a packet arrived 0.5 second or more after relaying the previous packet, it inserts a delay of delay milliseconds.
-f ctlfile
Enables receiving control by source host specified by control file  ctlfile. In  ctlfile a host control line starting with "+" or "-"can be written. In each line, only the left-most item delimited by blank or tab is read, and the remaining parts of the line are jumped. The line starting with '#' is presumed to be a comment.
Host control line is a rule written in the format.

       -host   packet sent from host to be rejected
       +host   packet sent from host to be accepted
       +       accept packet
       -       reject packet

As for host control, the rule is applied to each packet from the top. When the applicable rule is found, it is applied. When no applicable rule is found until the last, the packet is accepted (that is to say, the last line is always with "+").
-g group
Receives a packet transmitted to the IP multicast address group.
-i interface
Specifies the network interface that receives the packet sent to the IP multicast address by the IP address of the interface interface.
-N
Does not inspect packet number of received packet. Packet number field (the top 2 bytes) is not rewritten, that is to say, the received packet is relayed as it is.
-n
Does not report information on packet from source address to be rejected or resent packet received redundantly to the log.
-p src_port
Makes the UDP port number of the source src_port. Usually the specification is not required.
-r
Does not transmit resend request packet. In case of one-way transmission line like receiving through the DVB satellite delivery board, this can restrict unnecessary packet transmission.
-s sinterface
When address dest is the IP multicast address, it specifies network interface to which packet is transmitted by the IP address of the interface sinterface.
-t ttl
When the recepient is the IP multicast address, it makes the value of TTL of transmission packet ttl instead of default 1.
 

SOURCE

relay.c
 

SEE ALSO

winformat(1W), recvt(1W), send_raw(1W), order(1W)


 

Index

NAME
SYNOPSIS
DESCRIPTION
Format on networks and resend protocol
OPTIONS
SOURCE
SEE ALSO

This document was created by man2html, using the manual pages.
Time: 00:24:28 GMT, September 20, 2017