1 2 3 Previous Next 61 Replies Latest reply: Sep 20, 2016 2:38 PM by NC-Expert_CCIE_Mentor RSS

    arp works on layer 2 or layer 3?

    sagar

      arp works on layer 2 or layer 3?

        • 1. Re: arp works on layer 2 or layer 3?
          Michael

          ARP works at layer 2, its not carried inside layer 3 header.

           

           

          Thanks

          Michael

          • 2. Re: arp works on layer 2 or layer 3?
            Don

            ARP is a protocol that map a known IP address to its corresponding MAC Address in an IPv4 network. Whether ARP operate at layer 2 or layer 3, that is a controversial topic. My personal  opinion is that ARP operate at layer 2, when you think about it an ARP frame does not get broadcast pass the local network. Also it is referenced in the OSI model as a link layer protocol.

             

            All the best !

            Don

            • 3. Re: arp works on layer 2 or layer 3?
              sagar

              But it map ip to mac if it operate at layer 2  than how can it know about ip?

              • 4. Re: arp works on layer 2 or layer 3?
                Aref - CCNPx2 (R&S - Security) / Network+ / Security+

                Hi Sagar,

                 

                Good year 2016.

                 

                In my opinion ARP would be considered as a Layer 2.5 protocol, the reason of why I would say that is the fact that ARP broadcast packet contains the destination ip address which is looking for its mac address, and when that packet arrives at the destination host the L3 information is being involved and processed, the destination host reads the L3 information inside the packet, and based on its L3 information it replies. I would say ARP would not fit completely into L3 but it exceeds the normal L2 features.

                 

                Regards | Aref.

                • 5. Re: arp works on layer 2 or layer 3?
                  Michael

                  ARP contains fields that contain the source address and destination IP address, IP header is not used to add this information, the packet is passed to the data link layer that sends out a broadcast on the network, when the packet arrives at the destination its passed to the ARP protocol which create the ARP reply containing the missing MAC address, this will be sent as unicast message to the destination that sent the request.

                  • 6. Re: arp works on layer 2 or layer 3?
                    Dan

                    What a great question!  I love the response that says "Whether ARP operate at layer 2 or layer 3, that is a controversial topic"  Ha Ha!  It is so reassuring to see that I am not the only one who wonders about these kinds of things, and that the reason they don't make sense isn't my fault!

                     

                    --Dan

                    • 7. Re: arp works on layer 2 or layer 3?
                      abdo refky

                      sybex book dissagree with you Don  . accroding to this . ARP done at layer 3

                      the packet and destination hardware addresses are then both sent to the Data Link layer for framing.

                      which mean that layer 3  give layer 2 : the destination MAC-address + the packet

                      • 8. Re: arp works on layer 2 or layer 3?
                        Juergen Ilse CCNA R&S

                        I think, the best answer was given by Aref: ARP is a kind of "layer2.5 protocol". ARP will not be forwarded at Layer3, it uses no Layer3 addressing for sending and receiving information, but the requested information is Layer3 information and the answer contains that Layer3 information. ARP is necessary for Layer3 addressing within the Layer2 nework segment, but itself uses only Layer2 adressing for sending and receiving frames. ARP Frames do not contain a Layer3 header, so they are sure not Layer3, but they contain Layer3 information, so they are not only Layer2.

                        • 9. Re: arp works on layer 2 or layer 3?
                          abdo refky

                          look at the protocol-type  field at the ethernet header

                          The following trace shows an ARP broadcast—notice that the destination hardware

                          address is unknown and is all Fs in hex (all 1s in binary)—and is a hardware address

                          broadcast:

                           

                          Flags: 0x00

                          Status: 0x00

                          Packet Length: 64

                          Timestamp: 09:17:29.574000 12/06/03

                          Ethernet Header

                          Destination: FF:FF:FF:FF:FF:FF Ethernet Broadcast

                          Source: 00:A0:24:48:60:A5

                          Protocol Type: 0x0806 IP ARP <--------------------------------------------------- the packet is going to layer 3

                           

                          ARP - Address Resolution Protocol

                          Hardware: 1 Ethernet (10Mb)

                          Protocol: 0x0800 IP

                          Hardware Address Length: 6

                          Protocol Address Length: 4

                          Operation: 1 ARP Request

                          Sender Hardware Address: 00:A0:24:48:60:A5

                          Sender Internet Address: 172.16.10.3

                          Target Hardware Address: 00:00:00:00:00:00 (ignored)

                          Target Internet Address: 172.16.10.10

                          Extra bytes (Padding):

                          ................ 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A

                          0A 0A 0A 0A 0A

                          Frame Check Sequence: 0x00000000

                          • 10. Re: arp works on layer 2 or layer 3?
                            Juergen Ilse CCNA R&S

                            Layer3 packets contain a layer3 header with layer3 addresses for source and destination. That is *not* the case for ARP. ARP carries layer3 information, but not in an Layer3 header but as payload. So it is a layer2 protocol dealing with layer3 information (and no, that ethertype 0806 is named "IP ARP" makes this frame not to a real layer3 packet, at least in my opinion).

                            • 11. Re: arp works on layer 2 or layer 3?
                              Ismael da Silva Mariano

                                     Hello,Sagar! How are you doing?

                               

                                     Think the diagram bellow shows everyhting (from Internet Protocols - DocWiki):

                               

                               

                              ARP.jpg

                               

                                        Compared to the OSI  model, Cisco puts ARP as a 2.5 protocol!

                               

                                        Really, when you see the fields of ARP , there are components of layers 2 and 3 :

                               

                               

                               

                                      But ARP messages are transmited encapsulated in a layer2 protocol , see( from Arp and rarp):

                               

                               

                              ARP encapsulation.jpg

                               

                                          Just as any layer3 protocol.

                               

                               

                               

                                   In the TCP/IP model  ,see bellow (From Todd Lammle study guide):

                               

                              DoD PROTOCOLS.jpg

                                    ARP is completely inside the Internet layer!

                               

                               

                                   Conclusion, agree with the ones who say LAYER 2.5!

                               

                               

                               

                                  See here a good explanation of ARP protocol : The TCP/IP Guide - TCP/IP Address Resolution Protocol (ARP)

                               

                               

                                 Cheers!!!!

                              • 12. Re: arp works on layer 2 or layer 3?
                                abdo refky

                                it's not the name .

                                the ethertype field , identify the layer 3 protocol which will handel the payload .

                                the payload field (or the data ) is the next field . ( this field contain the data came from upper layer )

                                which is this data .

                                ARP - Address Resolution Protocol

                                Hardware: 1 Ethernet (10Mb)

                                Protocol: 0x0800 IP

                                Hardware Address Length: 6

                                Protocol Address Length: 4

                                Operation: 1 ARP Request

                                Sender Hardware Address: 00:A0:24:48:60:A5

                                Sender Internet Address: 172.16.10.3

                                Target Hardware Address: 00:00:00:00:00:00 (ignored)

                                Target Internet Address: 172.16.10.10

                                Extra bytes (Padding):

                                ................ 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A 0A

                                0A 0A 0A 0A 0A

                                 

                                this next photo is what done at layer 3

                                arpformat.png

                                • 13. Re: arp works on layer 2 or layer 3?
                                  abdo refky

                                  Ismael . is there a reason rather than the diagram for considering it 2.5 ?

                                   

                                  does layer 2 do any thing rather than the transmation ?

                                  The TCP/IP Guide - ARP Message Format

                                  and i qoute from this link you sent .

                                  """After the ARP message has been composed it is passed down to the data link layer for transmission """

                                   

                                  does

                                  1 : layer 2 add anything to the arp message ? .

                                  or

                                  2: it's just used for transmission that packet which has been fully created at the upper layer

                                  1 2 3 Previous Next