wiki:Proto/cModules/c0HostProtocolStack/c0Configuration
close Warning: Can't synchronize with repository "(default)" ("(default)" is not readable or not a Git repository.). Look in the Trac log for more information.

Version 1 (modified by seskar, 9 years ago) ( diff )

--

Configuration

Stack configuration includes default identity, set of network interfaces, policy for choosing between two or more interfaces for forwarding outbound packets, and several resource parameters that affect performance. Configuration is specified simply using <name>=<value> pairs as shown in the below template file.

Template hoststack.conf

# Specify 'default' GUID for the network stack and therefore for the 
# node that it runs on. The stack would use this as a source GUID for 
# any messages sent by applications that do not specify their own, and 
# also when the communication originates from within the stack (e.g., 
# from transport modules or for error messages). For now, it is a
# 32-bit positive integer.
# Example:
# DEFAULT_GUID=234323
#
# Required.
DEFAULT_GUID=

# Define one or more interfaces to be used for network communication.
# These are either a 3-tuple 'auto' or a 5-tuple 'manual' 
# configuration:
# INTERFACE=<type>,<name>,auto 
# INTERFACE=<type>,<name>,manual,<ip_addr>,<mac_addr>
# where 
#  type is one of 'wifi', 'wimax', or 'ether'
#  name is the system name of interface, e.g., wlan0 or eth0
#  'auto' and 'manual' keywords distinguish whether network attachment
#    (i.e., first hop router, or another host in p2p mode) is dynamically 
#    chosen by stack based on advertisements or is statically fixed for 
#    the interface.
#  ip_addr is the IP4 address of first hop in fixed attachment
#  mac_addr is the MAC address of first hop in fixed attachment
# Examples: 
# INTERFACE=wifi,wlan0,auto
# INTERFACE=wimax,wmx0,manual,192.168.1.1,11:22:33:44:55:66
# 
# Must specify at least one
INTERFACE=

# Pick policy for deciding what interface an outbound packet should be
# sent on. Policies currently implemented are:
#  'bestperformance' - stack monitors link (e.g., data rate) to 
#    determine best. Interfaces not enabled or down with errors are 
#    not considered.
#  'wifionly' - equivalent to having just the WiFi interface(s)
#  'wimaxonly' - similarly, just having the WiMAX interface(s)
#  'etheronly' - just having the Ethernet interfaces(s)
# Example:
# POLICY=bestperformance
#
# Required.
POLICY=

# Performance configuration - mostly for tuning 

# Buffer size (in MB) for communication sockets used internal by
# stack to interact with API library. It is also used to size per
# interface buffer on the send side.
# Positive integer based on system resources.
# Example:
# BUFFER_SIZE=10
BUFFER_SIZE=10

# Ack timeout (in usec) for the Hop data-link transport layer.
# Example: 800ms timeout 
# CSYN_TO=800000
CSYN_TO=800000
Note: See TracWiki for help on using the wiki.