IoTSSC – End- to-end networking
Image: TRENDR
networking Image: TRENDR You will need some form of global How to - - PowerPoint PPT Presentation
IoTSSC End- to-end networking Image: TRENDR You will need some form of global How to addressing (unique identifiers) enable end- A mechanism to transfer information between different end points to-end (routing protocol)
Image: TRENDR
addressing (unique identifiers)
between different end points (routing protocol)
(reduced computation capabilities, small messages, limited energy)
the Internet and does solve the device addressing issue.
problematic in the context of trillions of IoT devices expected to be rolled out in the future.
address among multiple hosts, by assigning those private addresses; however, NAT suffers though from serious problems, e.g. breaks up layered designs.
addresses – 128 bits (addressing 2128 UNIQUE interfaces).
RFC 2460 to RFC 2466
1. Support huge number of hosts 2. Reduce the size of routing tables 3. Simplify protocol → allow for faster packet processing 4. Improve security 5. Allow host roaming without address changing
compatible with Internet control and transport protocols such as ICMP, OSPF, BGP, TCP, UDP, etc.
(7 fields vs. 13) and has better support for options.
Fixed part of the header: 40 Bytes. Version: 0110 (6) – Let routers know about packet type Traffic Clas lass: Used to distinguish different classes of services – useful for real-time traffic with strict req. Flo Flow Lab Label: : Marks groups of packets that should be treated in the same way, sort of connection oriented flavour Payload Le Length: Similar to ‘Total Length’ in IPv4, but header length omitted here. Ne Next Header: Points to the first optional extension header (if any). The last header uses this field to specify the transport layer protocol, e.g. TCP, UDP) Hop
Limit: Same functionality as TTL in IPv4.
separated with colons.
8000:0000:0000:0000:0123:4567:89AB:CDEF
To reduce notation 3 optimisations are authorised: 1. Leading zeros within a group can be omitted 2. One or more groups of 16 zero bits can be replaced by a pair of colons
8000::123:4567:89AB:CDEF
3. IPv4 addresses can be written as a pair of colons followed by decimal representations
::192.31.20.46
Prefix fix Desc scrip iptio ion IPv4 equ equiv ivale lent ::/128 Unsp Unspeci cifie ied (used at boot up) 0.0.0.0 ::1/127 Loopb Loopback 127.0.0.1 ::ffff/96 Example: ::ffff:192.0.2.47 IPv Pv4 ma mapped (used to embed IPv4 addresses into IPv6) No equivalence fc00::/7 Example: fdf8:f53b:82e4::53 Uni nique Loca Local Add Address sses s (ULA (ULAs) s) Reserved for local use and are not
Private addresses: 10.0.0.0/8 172.16.0.0/12 192.168.0.0/16 fe80::/10 Example: fe80::200:5aee:feaa:20a2 Link-Local l Add Addresses Used on a single link or a non-routed common access, e.g. Eth. LAN. Not necessarily unique outside Link. 169.254.0.0/16 2000::/3 Gl Glob
nicast No equivalent single block
48 bits 16b or fewer 64 bits
id) is contained in the most significant 64 bits of the address.
smaller subnet id size.
administrator to define subnets within the given network.
from the interface's MAC address using the modified EUI-64 format, obtained from a DHCPv6 server, automatically established randomly, or assigned manually.
Routing prefix Interface identifier subnet
Modified EUI-64
00:0C:29:0C:47:D5
2001:db8:1:2::/64
2001:db8:1:2:020C:29ff:fe0c:47d5
6 extensions defined for extra functionality
security
by-hop processing
examined by the destination node
Protocols such as IEEE 802.15.4 have limited packet sizes (standard size is 127 bytes)
Only ly 33B B le left ft for data! Som
equired.
Pack cket fr fragmentation and rea eassembly is is req equired.
enable the transport of IPv6 packets over 802.15.4 links
cannot easily communicate with other protocols (but more energy efficient)
*Texas Instruments: 6LoWPAN demystified
Telemetry Transport) - like HTTP but IoT focused (resource discovery, publish/subscribe, etc.)
Key idea: omit fields if can be derived from the link layer / context Three scenarios: 1. Communication between devices on the same network – compress header to two bytes 2. Communication with a device outside local network, network prefix known – compress to 12 bytes 3. Communication with device on external network, device prefix not known – compress to 20 bytes (50%)
All packets prefixed with a 1-byte a dispatch code (encapsulation header) First fragment’s header includes the datagram size (11 bits) and a datagram tag (16 bits).
Pattern Header type 00 XXXXXX NALP - Not A LoWPAN Packet 01 000001 IPv6 - Uncompressed IPv6 addresses 01 000010 LOWPAN_HC1 – Compressed IPv6 header 01 111111 ESC - Additional Dispatch octet follows … Others reserved + broadcast, fragmentation, mesh
*Texas Instruments: 6LoWPAN demystified
for a DHCP server
short address, or both.
– this can be omitted in local communication
address in use – Duplicate Address Detection (DAD)
*Texas Instruments: 6LoWPAN demystified
scenarios (latency vs reliability vs energy)
infrastructure make sense for different applications
avoid cycles
(DODAGs), i.e. with a single root
Roots
DO DODAG DAG
DODAG root
new DODAG, or to maintain one already existing
Solicitation (DIS)
transmission count (ETX), other
St Stori ring: each nodes maintain routing table with
destinations reachable via its sub-DODAG and
hop node
A D C B E F G H Route: E -> B -> F
Non-stori ring:
routing information;
the information in the packet itself
A D C B E F G H Route: E -> B -> A -> B -> F
“A network of remote servers hosted on the Internet and used to store, manage, and process data in place
(Oxford Dictionaries) Crucial component of IoT systems
visualisation
workloads under strict resource partitioning
memory, while providing security guarantees
different OSes running on the same physical machine (Infrastructure as a Service – IaaS)
virtualised OS within partitions. Execution safe to the kernel even if apps may have security issues (Platform as a Service – PaaS)
FAST TO INSTANTIATE CAN BE DESTROYED AS NEEDED NO NEED FOR A HYPERVISOR OS LIBRARIES CAN BE SHARED EASY TO SCALE
# Use an official Python runtime as a parent image FROM python:3.6 # Set the working directory to /app WORKDIR /app # Copy the current directory contents into the container at /app ADD . /app # Install any needed packages specified in requirements.txt RUN pip install -r requirements.txt # Make port 80 available to the world outside this container EXPOSE 80 # Define environment variable ENV NAME World # Run app.py when the container launches CMD ["python", "app.py"]
app.py basically listens for connection on port 80 and returns an HTML page To run the app, simply call docker ru run -p 4000:80 docker-fi file le
localhost
We talked about
meaningful things with the data IoT devices may generate Remaining question: how to act ctually in integrate th the devices wit ith th the clo cloud?
REST (REpresentational State Transfer) API
packages them into JSON format record={ “date”: “2018-04-04”, “time”: “09:30:00”, “temperature”: 20.1 }
import requests import json … url=“http://<uri_of_server_end_point” requests.post(url, data=json.dumps(measurements))
Use OAuth (authorisation framework – RFC 6749/50)
www.websequencediagrams.com
collect information from constrained IoT devices (or devices to communicate among each other – M2M) following a publish/subscribe paradigm
high latency
industrial applications
(different IoT devices) to the clients (subscriber)
multiple topics into topic levels
publishers from the subscribers – scalability
to the guarantees of delivering a message
based on network reliability
acknowledged by the recipient, nor stored and redelivered if subscriber unreachable)
delivered at least once to the receiver (though may be delivered more than once); message stored by sender until acknowledge by the receiver (PUBACK)
slowest)
received by a subscriber.
it will received the first message on a topic, as this depends strictly on publisher.
with the ‘retain’ flag set -> broker stores the last message with retain flag, and the QoS for that topic
subscribing.
to an exact topic but to the relevant topic level, e.g.
/home/bedroom1/temperature
room as soon as it subscribes
new retained message with zero payload.
mosquitto-clients
Very similar to HTTP, uses URIs (coap://), but
retransmissions implemented at Application layer
recipients)
session)
for a central entity (unlike MQTT that needs a broker)
Mode transmissions – large files divided into smaller parts
implemented between UDP and CoAP