Alternative Transport Protocols
- Stream Control Transmission Protocol (SCTP)
- Real Time Protocol (RTP) and RTP Control Protocol (RTCP)
- Real Time Streaming Protocol (RTSP)
Additional Internet Transport-Layer Protocols
- Stream Control Transmission Protocol (SCTP)
- Real Time Protocol (RTP) and RTP Control Protocol (RTCP)
- Real Time Streaming Protocol (RTSP)
Stream Control Transmission Protocol
- all the functions of TCP, and much more
- each connection carries any number of independent, reliable streams
of packets
- a transmission sequence number and also a stream sequence number
- each IP packet can carry multiple independent chunks
- fragmentation of application packets
- end-system may be identified by multiple IP addresses
- congestion control done on the basis of IP address pairs
- flow control similar to TCP
- some support for security
- selective acknowledgements are not really piggybacked (except that
multiple chunks may be in the same packet)
- checksum is 32-bit CRC
- RFC 4960
- in-class discussion: what problems does SCTP solve that TCP doesn't?
SCTP formats
- from RFC 4960
- overall format:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Common Header |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Chunk #1 |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| ... |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Chunk #n |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
chunks are padded to multiples of four bytes
- common header:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Source Port Number | Destination Port Number |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Verification Tag |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Checksum |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
chunk format:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Chunk Type | Chunk Flags | Chunk Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\ \
/ Chunk Value /
\ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
chunk types: data (0), init and init ACK (2), SACK (3), heartbeat
and ack (4, 5), abort (6), shutdown and ack (7, 8), error (9), cookie
and ack (10, 11), ECNE and CWR (12, 13), shutdown complete (14)
data chunk format:
0 1 2 3
0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Type = 0 | Reserved|U|B|E| Length |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| TSN |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Stream Identifier S | Stream Sequence Number n |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
| Payload Protocol Identifier |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
\ \
/ User Data (seq n of Stream S) /
\ \
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
U means unsequenced (i.e., ignore the stream sequence number), B and E
mark the beginning and end fragments of a user message
According to RFC 4960, the verification tag is defined as:
Verification Tag: A 32-bit unsigned integer that is randomly
generated. The Verification Tag provides a key that allows a
receiver to verify that the SCTP packet belongs to the current
association and is not an old or stale packet from a previous
association.
checksum is a CRC-32
Real Time Protocol
Additional Real Time Protocols
- Real Time Streaming Protocol controls one or more sources
of real time data, e.g. RTP streams
(RFC 2326)
- Session Initiation Protocol provides additional session-level
primitives,
(RFC 3261)
Real-Time Audio and Video transmission
- original digital telephone network designed to carry 8,000
voice samples per second per channel: synchronous network
- compressed audio and video still need timely delivery, but
do not have bandwidth guarantees
- audio and video may be multicast for conferencing
- data loss and data delay have the same effect
- for pre-recorded data, if maximum delay is known, can pre-stream
and buffer a corresponding number of frames (Video On Demand, VoD)
- actual bandwidth, delay, and jitter experienced on stream is the Quality
of Service, QoS
- a QoS may also be requested as part of resource reservation
- if audio stream is given higher priority,
- can tolerate higher data loss, and
- temporary loss of video stream is less disruptive than temporary
loss of audio stream
- video and audio streams must be re-synchronized at receiver
Data Link Layer
- Data Link layer
- Wireless Medium: Broadcast
- Aloha
- 802.11
- Ad-Hoc Wireless networks
- Mobile Ad-Hoc networks (MANets)
- Wireless sensor networks
Data Link layer
- the layer below IP
- the layer above the physical layer
- concerned with issues such as
- framing: combining bits into packets
- access control: for shared media, orderly sharing of the shared medium
- error checking/correcting, using CRCs
- usually originally designed for only a single hop,
though often multihop
common Data Link layers
- Ethernet
- 802.11
- modems with PPP or SLIP
- amateur packet radio
- parts of ATM (the rest may be classified as the network layer, or
as the data link layer, or as not fitting the layer model very well)
- SONET, Frame Relay
- many older technologies, including FDDI, Token Ring, ...
Wireless Radio Communications
- broadcast medium: many/all can hear each sender
- collision: two senders sending at the same time, receiver can't
tell what the message was (collision is
detected by a receiver receiving a packet with a bad checksum/CRC)
- send and receive power are very different, so sender cannot
detect collision
- no central clock, often limited power
Aloha
- transmitters on outer Hawaiian islands send on frequency
f0 (could collide with each other), receive on frequency
f1
- transmitter on Oahu (hub) sends on frequency f1, receives
on frequency f0 (no collision)
- transmitter on Oahu rebroadcasts everything it receives, so
all stations know whether a given transmission was successful
- if a transmission fails, the originator must retransmit
- now used with ground stations and satellites
- all collisions are on the uplink to the satellite
Aloha -- Efficiency
- when nobody sends, network utilization is low
- when everybody sends, lots of collision, so network utilization is low
- optimum is when the network is about 18% utilized
- improvement: have everyone start transmission at a given time (the hub
can transmit a clock signal). This decreases the chances of collision
-- slotted Aloha
- improvement: using Aloha, everyone (who needs to send)
sends their address, then the base station reports the winning address
and only that station sends its data -- why is this an improvement?
Wireless Radio Communication Networks
- can the Internet protocol be used over wireless links?
- hidden sender problem: A sends to B, C does not
know A is sending and might send to B at the same time
- because of the chance of collision and other interference,
wireless networks can have high error rates
- wirelessness is important for mobility, but how to do
addressing and routing, especially when addressing is tied to location?
- cellular: each system has a "home", identifies itself
to the local base station (strongest radio signal), which tells
the home how to reach me
- cellular: as I move, my connection must be handed off to
another base station
- WiMax is a form of cellular communication
- cellular: not peer-to-peer networking
802.11 Data Link Layer
- "hidden terminal" problem solved by
- sender sends a very short packet (Request to Send, RTS)
reserving the medium for the time needed for the actual data
- receiver responds with a very short packet (Clear to Send, CTS)
reserving the medium
- anyone within range of either the sender or the receiver must
now keep quiet
- collision avoidance: most collisions are on the RTS/CTS, not
the data packet
- a final ack confirms that the receiver has received the data
- synchronous data (e.g. voice) has higher priority
- broadcast is best-effort, unicast is reliable (passive ack -- same
as Aloha)
802.11 Network Topologies
- "Access Point" (AP) is in range of all the end stations, forwards
data onto the internet (bridging)
- ideally, APs can communicate with each other over a wired (or wireless)
network, creating a cellular wireless network: a mesh network
- the above is Managed mode, the alternative is Ad-Hoc mode, in
which all nodes are equivalent
Ad-Hoc Wireless Networks
- in an Ad-Hoc Network, everyone agrees to forward everyone else's packets
- who do we forward to? How do we locate the default router? Is
this "routing" on the data-link layer? What happens when wireless units
move?
- types:
- Mobile Ad-hoc NETwork, MANET (for vehicle communications, VANET)
- Wireless Sensor Networks
- Mesh Networks
- every node is a router, every node is a host
- IP assumes that:
- if A can talk to B on B's interface i, and
- C can talk to B on B's same interface i, then
- A should be able to directly communicate with C
- this is not the case in wireless ad-hoc networks
- two solutions: modify IP (hard), or run the entire ad-hoc network as a
single IP (sub)network (easier)
- the second solution requires an underlying, data-link-layer routing
protocol
Ad-Hoc Wireless Networks: Performance
- assume a number of nodes in an ad-hoc wireless network
- the nodes are deployed in a straight line, each node in range
of only the node before it and the node after
- the link bandwidth is B bits/second
- how many bits per second can the first node communicate to the last?
- if node i transmits to node i+1, node i+1
cannot be transmitting to node i+2
- if node i transmits to node i+1, node i-1
cannot be transmitting to node i
- if node i transmits to node i+1, node i-2
cannot be transmitting to node i-1
- so with one-directional transmission, at most 1/3 of the links
can be active at any given time.
- so the maximum data rate in such a configuration is B/3
- this is the best possible case, and it is hard to achieve
in practice
Mobile Ad-Hoc (Wireless) Networks: MANets
- nodes in a defined space move around at random speeds and directions
- new random speed and direction selected when a boundary is reached
- high mobility requires very agile routing protocols: it is normal
for routes to go down
- broadcast always works, but can we do better?
- DSR (Dynamic Source Routing): sender builds a route, includes in in
every packet. Routing tables are small, but packets are big or routes
are short
- AODV (Ad-Hoc On-Demand Distance Vector): similar to distance
vector, but routes are built on demand only, by broadcasting. Distance
vector is very efficient with information exchange, but does not do
well when links fail, though the shortage of links in AODV may help
prevent cycles
Wireless Sensor Networks
- low mobility (though sometimes units disappear),
low power, low data rates, often many nodes (mesh of nodes),
high reliability needed
- restricted application-dependent communication, e.g.
merge all the data towards a base station
- diffusion: requests (queries) and data messages (events) move at
random through the network until their paths intersect each other
- some applications may require general communication, e.g.
communication in the local area, transmit images and sound, debugging
and reconfiguration
- geographic routing: move the packet in the direction of the
destination. Often fails. Many workarounds, including Geometric Routing,
which keeps track of overall network topology.
- gradient routing: source or destination sends a broadcast, everyone
keeps track of distance. Grad, Lusus.
- sender can send a broadcast, which builds a reverse route back
to the sender. Receiver uses this route to reply, building a route
back to itself. Multipath On-Demand Routing (MOR).
- keeping multiple paths (MOR) lets you dynamically load balance
(each node may have multiple next hops) and try to avoid congestion
(if one transmission fails, try transmitting to a different next hop).
Wireless Sensor Network Physical Layers
- wanted: long range and low power
- directional focus: lasers, infrared, phased array antennas,
directional antennas. All require aiming, but some could be automatic
- omnidirectional: no focus needed, but more power needed for same range
- if antenna is high off the ground, power needed increases
with r2
- if antenna is near the ground, power needed increases
with r4
- Industrial, Scientific, Medical (ISM) bands are generally free
from licensing restrictions
- ISM bands are available in the 800-900MHz range (but different
frequencies e.g. for US and Europe) and 2.4GHz range (worldwide, same
frequency as microwave ovens, resonant frequency of water) and other
ranges
- selection of radios (systems, circuits, chips), maximum power
level usually determined by regulation, e.g. FCC in the US
- serial radios, 802.11, Bluetooth, Zigbee, and many other
up-and-coming standards