atmtcp - set up ATM over TCP connections
] command ...
The main purpose of atmtcp
is to establish TCP connections and to
configure them as virtual ATM devices. Such pairs of "ATM over TCP"
devices are connected as if they were real ATM adapters linked by a cable or
fiber, i.e. SDUs sent on a given VPI/VCI are received at the other end on the
Virtual interfaces and ATM over TCP connections are called links
link types supported by atmtcp
are real interfaces, files for recording
and playback of ATM traffic, and printing a hex dump of the PDU content on
standard output. Any pair of such links can be connected with atmtcp
If additional links are attached to such a connection, they send to all other
links, except to the first link and the respective sender, and they receive
from all other links.
can operate with two types of virtual interfaces: ephemeral or
persistent. By default, atmtcp
interfaces are ephemeral. When the
process that created an interface terminates, the virtual ATM
device is removed as soon all VCs are closed. However, if the interface was
previously created as a persistent interface, only the communication stops,
but the interface and all VCs on it remain intact. Attempts to send data on an
interface in this state fail silently, i.e. the interface
behaves just like a real ATM interface without a wire. A new atmtcp
process can then attach to the interface and resume operation. Persistent
interfaces need to be removed explicitly.
has any readable links after processing the command line, it
enters a loop to perform the data forwarding. If no readable links have been
terminates after processing the command line. If any
setup operation fails, atmtcp
terminates at this point and does not
attempt to cancel previous operations (e.g. creation of permanent interfaces).
- print detailed progress information on standard error.
- print some progress information on standard error.
- print version number of atmtcp on standard output
- create [itf]
- create a persistent interface. If no interface number is
specified, atmtcp uses the default value 0.
- remove [itf]
- remove a persistent interface. If the interface is still in
use, it is marked as ephemeral and will be removed as soon as all VCs are
closed. If no interface number is specified, atmtcp uses the
default value 0.
- virtual [itf]
- link to the corresponding virtual (ATM over TCP) interface.
If no interface number is specified, the kernel assigns the first
- real [itf]
- link to the corresponding ATM interface. If no interface
number is specified, atmtcp uses the default value 0. If a link
requests that a VC be opened, atmtcp will attempt to open a VC with
the specified QoS parameters on that interface. If the operation succeeds,
data can be sent or received on that VC. If the operation fails, an error
code is returned to the requester. Note that only data arriving on open
VCs can be received and that a real ATM interface never initiates a
connection. atmtcp can share ATM interfaces with other
- connect host [port]
- connect to an instance of atmtcp running on the
specified host. If the port argument is omitted, atmtcp uses the
default port 2812.
- switch host line [port]
- like connect, but connects to an ATM over TCP
"switch" and selects the specified virtual line.
- listen [port]
- listen for an incoming ATM over TCP connection. If the port
argument is omitted, atmtcp uses the default port 2812.
atmtcp waits until the connection is established. Only one
connection is accepted per listen command.
- listen-bg [port]
- like listen, but run in background after beginning
- read file [stream]
- play back all streams from the specified file. If a stream
number is specified, only that stream is played back.
- write file
- record the traffic of all links in the specified file. The
PDUs from each link are stored in a stream with the same number as the
- print a hex dump of the content of all received PDUs on
- continue to run in background (i.e. in a forked child
- wait [seconds]
- wait for the specified number of seconds. If no time is
specified, atmtcp waits for a newline on standard input.
Due to recent protocol changes, atmtcp
is currently not compatible with
the ATM over TCP "switch".
Only AAL SDUs are exchanged, no segmentation or reassembly is performed. That
implies that using different AALs (e.g. AAL5 and AAL0) on either side will
reveal limitations of this emulation.
process needs to run during the the whole lifetime of the
Create a pair of virtual ATM over TCP interfaces on the local host and connect
# session A
atmtcp virtual listen
# session B
atmtcp virtual connect localhost
Create virtual interface 1, connect it to real ATM interface 0, then start
on the virtual interface, and log all the traffic in a file:
atmtcp virtual 1 real 0 write /tmp/log
Take the previously created file and examine the traffic sent from
# session A
atmtcp virtual 1 read /tmp/log 0 wait
# session B
# press [Enter] in session A
Werner Almesberger, EPFL ICA <Werner.Almesberger@epfl.ch>