Data Link Layer (OSI Protocols)

Source: Wikipedia: Data Link Layer


Data Link Layer

From Wikipedia, the free encyclopedia
Jump to: navigation, search
Question book-new.svg
This article needs additional citations for verification.
Please help improve this article by adding reliable references. Unsourced material may be challenged and removed. (October 2009)
OSI Model
7 Application Layer
6 Presentation Layer
5 Session Layer
4 Transport Layer
3 Network Layer
2 Data Link Layer

* LLC sublayer
* MAC sublayer

1 Physical Layer

The Data Link Layer is Layer 2 of the seven-layer OSI model of computer networking. It corresponds to, or is part of the link layer of the TCP/IP reference model.

The Data Link Layer is the protocol layer which transfers data between adjacent network nodes in a wide area network or between nodes on the same local area network segment[1]. The Data Link Layer provides the functional and procedural means to transfer data between network entities and might provide the means to detect and possibly correct errors that may occur in the Physical Layer. Examples of data link protocols are Ethernet for local area networks (multi-node), the Point-to-Point Protocol (PPP), HDLC and ADCCP for point-to-point (dual-node) connections.

The Data Link Layer is concerned with local delivery of frames between devices on the same LAN. Data Link frames, as these protocol data units are called, do not cross the boundaries of a local network. Inter-network routing and global addressing are higher layer functions, allowing Data Link protocols to focus on local delivery, addressing, and media arbitration. In this way, the Data Link layer is analogous to a neighborhood traffic cop; it endeavors to arbitrate between parties contending for access to a medium.

When devices attempt to use a medium simultaneously, frame collisions occur. Data Link protocols specify how devices detect and recover from such collisions, but it does not prevent them from happening.

Delivery of frames by layer 2 devices is affected through the use of unambiguous hardware addresses. A frame's header contains source and destination addresses that indicate which device originated the frame and which device is expected to receive and process it. In contrast to the hierarchical and routable addresses of the network layer, layer 2 addresses are flat, meaning that no part of the address can be used to identify the logical or physical group to which the address belongs.

The data link thus provides data transfer across the physical link. That transfer can be reliable or unreliable; many data link protocols do not have acknowledgments of successful frame reception and acceptance, and some data link protocols might not even have any form of checksum to check for transmission errors. In those cases, higher-level protocols must provide flow control, error checking, and acknowledgments and retransmission.

In some networks, such as IEEE 802 local area networks, the Data Link Layer is described in more detail with Media Access Control (MAC) and Logical Link Control (LLC) sublayers; this means that the IEEE 802.2 LLC protocol can be used with all of the IEEE 802 MAC layers, such as Ethernet, token ring, IEEE 802.11, etc., as well as with some non-802 MAC layers such as FDDI. Other Data Link Layer protocols, such as HDLC, are specified to include both sublayers, although some other protocols, such as Cisco HDLC, use HDLC's low-level framing as a MAC layer in combination with a different LLC layer. In the ITU-T G.hn standard, which provides a way to create a high-speed (up to 1 Gigabit/s) Local area network using existing home wiring (power lines, phone lines and coaxial cables), the Data Link Layer is divided into three sub-layers (Application Protocol Convergence, Logical Link Control and Medium Access Control).

Within the semantics of the OSI network architecture, the Data Link Layer protocols respond to service requests from the Network Layer and they perform their function by issuing service requests to the Physical Layer.
Contents
[hide]

* 1 Models of communication
o 1.1 Connection-oriented communication
o 1.2 Connectionless communication
* 2 Sublayers of the Data Link Layer
o 2.1 Logical Link Control sublayer
o 2.2 Media Access Control sublayer
* 3 List of Data Link Layer services
* 4 Protocol examples
* 5 Interfaces
* 6 Relation to TCP/IP model
* 7 See also
* 8 References

[edit] Models of communication
[edit] Connection-oriented communication
Main article: Connection-oriented
[edit] Connectionless communication
Main article: Connectionless mode transmission
[edit] Sublayers of the Data Link Layer
[edit] Logical Link Control sublayer

The uppermost sublayer is Logical Link Control (LLC). This sublayer multiplexes protocols running atop the Data Link Layer, and optionally provides flow control, acknowledgment, and error notification. The LLC provides addressing and control of the data link. It specifies which mechanisms are to be used for addressing stations over the transmission medium and for controlling the data exchanged between the originator and recipient machines.
[edit] Media Access Control sublayer

The sublayer below it is Media Access Control (MAC). Sometimes this refers to the sublayer that determines who is allowed to access the media at any one time (usually CSMA/CD). Other times it refers to a frame structure with MAC addresses inside.

There are generally two forms of media access control: distributed and centralized. Both of these may be compared to communication between people. In a network made up of people speaking, i.e. a conversation, we look for clues from our fellow talkers to see if any of them appear to be about to speak. If two people speak at the same time, they will back off and begin a long and elaborate game of saying "no, you first".

The Media Access Control sublayer also determines where one frame of data ends and the next one starts — frame synchronization. There are four means of frame synchronization: time based, character counting, byte stuffing and bit stuffing.

* The time based approach simply puts a specified amount of time between frames. The major drawback of this is that new gaps can be introduced or old gaps can be lost due to external influences.
* Character counting simply notes the count of remaining characters in the frame's header. This method, however, is easily disturbed if this field gets faulty in some way, thus making it hard to keep up synchronization.
* Byte stuffing precedes the frame with a special byte sequence such as DLE STX and succeeds it with DLE ETX. Appearances of DLE (byte value 0x10) has to be escaped with another DLE. The start and stop marks are detected at the receiver and removed as well as the inserted DLE characters.
* Similarly, bit stuffing replaces these start and end marks with flag consisting of a special bit pattern (e.g. a 0, six 1 bits and a 0). Occurrences of this bit pattern in the data to be transmitted is avoided by inserting a bit. To use the example where the flag is 01111110, a 0 is inserted after 5 consecutive 1's in the data stream. The flags and the inserted 0's are removed at the receiving end. This makes for arbitrary long frames and easy synchronization for the recipient. Note that this stuffed bit is added even if the following data bit is 0, which could not be mistaken for a sync sequence, so that the receiver can unambiguously distinguish stuffed bits from normal bits.

[edit] List of Data Link Layer services

* Encapsulation of network layer data packets into frames
* Frame synchronization
* Logical link control (LLC) sublayer:
o Error control (automatic repeat request,ARQ), in addition to ARQ provided by some Transport layer protocols, to forward error correction (FEC) techniques provided on the Physical Layer, and to error-detection and packet canceling provided at all layers, including the network layer. Data link layer error control (i.e. retransmission of erroneous packets) is provided in wireless networks and V.42 telephone network modems, but not in LAN protocols such as Ethernet, since bit errors are so uncommon in short wires. In that case, only error detection and canceling of erroneous packets are provided.
o Flow control, in addition to the one provided on the Transport layer. Data link layer error control is not used in LAN protocols such as Ethernet, but in modems and wireless networks.

* Media access control (MAC) sublayer:
o Multiple access protocols for channel-access control, for example CSMA/CD protocols for collision detection and retransmission in Ethernet bus networks and hub networks, or the CSMA/CA protocol for collision avoidance in wireless networks.
o Physical addressing (MAC addressing)
o LAN switching (packet switching) including MAC filtering and spanning tree protocol
o Data packet queueing or scheduling
o Store-and-forward switching or cut-through switching
o Quality of Service (QoS) control
o Virtual LANs (VLAN)

[edit] Protocol examples

* ARCnet
* ATM
* Cisco Discovery Protocol (CDP)
* Controller Area Network (CAN)
* Econet
* Ethernet
* Ethernet Automatic Protection Switching (EAPS)
* Fiber Distributed Data Interface (FDDI)
* Frame Relay
* High-Level Data Link Control (HDLC)
* IEEE 802.2 (provides LLC functions to IEEE 802 MAC layers)
* IEEE 802.11 wireless LAN
* Link Access Procedures, D channel (LAPD)
* LocalTalk
* Multiprotocol Label Switching (MPLS)
* Point-to-Point Protocol (PPP)
* Serial Line Internet Protocol (SLIP) (obsolete)
* Spanning tree protocol
* StarLan
* Token ring
* Unidirectional Link Detection (UDLD)
* and most forms of serial communication.

[edit] Interfaces

The Data Link Layer is often implemented in software as a "network card driver". The operating system will have a defined software interface between the data link and the network transport stack above. This interface is not a layer itself, but rather a definition for interfacing between layers.
[edit] Relation to TCP/IP model

In the frame work of the TCP/IP (Internet Protocol Suite) model, OSI's Data Link Layer, in addition to other components, is contained in TCP/IP's lowest layer, the Link Layer. The Internet Protocol's Link Layer only concerns itself with hardware issues to the point of obtaining hardware addresses for locating hosts on a physical network link and transmitting data frames onto the link. Thus, the Link Layer is broader in scope and encompasses all methods that affect the local link, which is the group of connections that are limited in scope to other nodes on the local access network.

The TCP/IP model is not a top/down comprehensive design reference for networks. It was formulated for the purpose of illustrating the logical groups and scopes of functions needed in the design of the suite of internetworking protocols of TCP/IP, as needed for the operation of the Internet. In general, direct or strict comparisons of the OSI and TCP/IP models should be avoided, because the layering in TCP/IP is not a principal design criterion and in general considered to be "harmful" (RFC 3439). In particular, TCP/IP does not dictate a strict hierarchical sequence of encapsulation requirements, as is attributed to OSI protocols.
[edit] See also

* ODI
* NDIS
* SANA-II - Standard Amiga Networking Architecture, version 2
* S. Tanenbaum, Andrew (2005). Computer Networks (4th Edition ed.). 482,F.I.E., Patparganj, Delhi 110 092: Dorling Kindersley(India)Pvt. Ltd.,licenses of Pearson Education in South Asia. ISBN 81-7758-165-1.

[edit] References

1. ^ "What is Layer 2, and Why Should You Care?". accel-networks.com. http://www.accel-networks.com/blog/2009/09/what-is-layer-2-and-why-should-you-care.html. Retrieved 2009-09-29.

Retrieved from "http://en.wikipedia.org/wiki/Data_Link_Layer"
Categories: OSI protocols | Link protocols
Hidden categories: Articles needing additional references from October 2009 | All articles needing additional references
Personal tools

* New features
* Log in / create account

Namespaces

* Article
* Discussion

Variants

Views

* Read
* Edit
* View history

Actions

Search

Navigation

* Main page
* Contents
* Featured content
* Current events
* Random article

Interaction

* About Wikipedia
* Community portal
* Recent changes
* Contact Wikipedia
* Donate to Wikipedia
* Help

Toolbox

* What links here
* Related changes
* Upload file
* Special pages
* Permanent link
* Cite this page

Print/export

* Create a book
* Download as PDF
* Printable version

Languages

* العربية
* Català
* Česky
* Dansk
* Deutsch
* Ελληνικά
* Español
* Euskara
* فارسی
* Français
* 한 국어
* Bahasa Indonesia
* Italiano
* עברית
* Latviešu
* Bahasa Melayu
* Nederlands
* 日本語
* ‪Norsk (bokmål)‬
* ‪Norsk (nynorsk)‬
* Polski
* Português
* Русский
* Slovenčina
* Slovenščina
* Српски / Srpski
* Srpskohrvatski / Српскохрватски
* Svenska
* Türkçe
* Tiếng Việt
* 中文

* This page was last modified on 15 June 2010 at 01:07.
* Text is available under the Creative Commons Attribution-ShareAlike License; additional terms may apply. See Terms of Use for details.
Wikipedia® is a registered trademark of the Wikimedia Foundation, Inc., a non-profit organization.
* Contact us

Unless otherwise stated, the content of this page is licensed under Creative Commons Attribution-ShareAlike 3.0 License