COMP 3000 2011 Week 11 Notes

From Soma-notes

Networking

It should be noted that, if networking were taken away, there would be no need for modern operating systems. Modern operating system architecture is very good for networking--the kernel handles receiving messages, processing the message and sending it to the appropriate procedure. The kernel will receive an interrupt from the network card, notifying it that it has a message to process and send.

Networking: communication between point A and point B

Packet: fixed size chunk of data (normally 1500 bytes). If one wants to send a package larger than the fixed size, the larger packet is fragmented into smaller ones. Packets can be repeatedly "wrapped" (e.g. data is wrapped in an IP packet, which is wrapped in an ethernet packet, which is wrapped in a DSL packet etc. and, once the destination is reached, all of this is stripped).

TCP/IP: one way to format a packet (the "to" and "from" fields associated with the packet are numbers--IP addresses--while the contents of the "message" is the data to be sent)

Routers: copies packets and relays them from router to router until the destination is reached. However, along the way, a packet may be damaged/dropped. This system of sending packets is a "best effort" practice.

TCP: notion of retransmission when something is lost, reordering of packets; will interpret packet loss as congestion and will slow down

Sockets: file like abstraction of the operating system

Ports: ID for operating system to distinguish which process gets the data

Streaming Protocols: just wants datagrams, continuous stream, usually for things like media. If packets are lost, just move on. This means that data can be lost, but everything is still alright, there is only a degradation in quality (i.e. the entire thing doesn't stop working).

Firewall: filters network traffic, often by blocking ports. A standard firewall works on TCP or IP levels.

DPI: deep packet inspection means that the data of the packet is what is being looked at, not the "wrappers" around the data

Time line of how data is sent to processes:

Data -> Ethernet Card (via ethernet card MAC address) -> Driver (interrupt associated with ethernet card) -> data is processed and given to the right process -> network stack (makes available to right process; puts the data in the right buffer) -> data now available to process

Note that the driver, processing the data, and network stack steps of this process are all fulfilled by the kernel.