A SERVICE OF

logo

148 SOCKETS TCP/IP Stack
MX3 Reference Guide E-EQ-MX3RG-J-ARC
Parameters
ifname
ifname defines the name used in the interface command for the device to be controlled.
arg1...argn
These parameters depend on the type of interface in use.
Example
To display current serial link settings and restart the statistics on it, use:
param sl0 clear
param, Alternative Routing Control Sub-commands
The Alternative Routing Control Sub-commands set up and check the Sockets alternative route
mechanism. More than one route can be specified to a target host or network. The first route
which has an associated interface in the up state is used.
An interface is in the up state when it is defined by the interface command. It enters the query
state when it does not receive valid input within a specified up-time period after sending data
expecting a response. At this stage three (catering for links with a high data loss) ICMP echo
requests (ping) are sent to a query IP address. It enters the down state by a Sockets command or
when it does not receive valid input within the specified up-time period after entering the query
state. If an up-time has never been specified or a value of 0 is specified, the interface will stay in
the up state whether valid input is received or not.
An interface enters the up state by a Sockets command or when valid input is received on that
interface when in the down or query states. An ICMP echo request is sent on an interface in the
down state every down-time period. If a down-time has never been specified or a value of 0 is
specified, the ICMP echo request will not be sent. Up-time and down-time is specified in seconds.
Syntax
param ifname [ uptime | downtime ] time
param ifname query hostname
Example Alternative Routing
Two X.25 interfaces are used to get to the target network 192.6.1.0. The first interface, named if0
should preferably be used, but if it stops receiving for a period of 20 seconds, it should try to ping
192.6.1.2 and if no response is received within another 20 seconds, if1 should take over, but if0
should be tried every five seconds. Interface if1 should disconnect after 80 seconds of no traffic.
The SOCKET.CFG file should contain the following:
interface x25 if0 ... ... ...
param if0 uptime 20
param if0 downtime 5
param if0 query 192.6.1.2
interface x25 if1 ... ... ...
param if1 uptime 80
param if1 downtime 5
param if1 query 192.6.1.2
route add 192.6.1.0 if0
route add 192.6.1.0 if1
In the case of both if0 and if1 failing, both are tried every five seconds until one comes up. The
return paths should also be maintained in a similar way with Sockets or by using RIP.