Frame fields

bermovickbermovick Member Posts: 1,135 ■■■■□□□□□□
I'm confused why an Ethernet frame has a 'type' field if one of the points made in the OSI model is that each layer doesn't need to care about how any other layer works.

I've tried rolling it around in my head, and I'm just not seeing why it's needed.
(I think it's even gotten me confused about other things about layer 2 in the process too!) icon_cry.gif
Latest Completed: CISSP

Current goal: Dunno

Comments

  • tierstentiersten Member Posts: 4,505
    How do you know what the next layer is without a type field? An underlying layer doesn't need to know how the next layer works but it still needs to know what it is.
  • bermovickbermovick Member Posts: 1,135 ■■■■□□□□□□
    But what does anything that works at layer 2 care? I'm just not understanding it. Perhaps it makes more sense later on, but why does a switch care if the frame is encapsulating an IP packet if it just examines the MAC addresses to see where to send the packet next?

    Sometimes I feel I'm just 'not getting it'.
    Latest Completed: CISSP

    Current goal: Dunno
  • tierstentiersten Member Posts: 4,505
    bermovick wrote: »
    But what does anything that works at layer 2 care?
    No but what happens when it arrives at the destination?
  • tierstentiersten Member Posts: 4,505
    Monkerz wrote: »
    "Type Field" is a length field specifying the number of bytes in the LLC and data fields.
    The type field actually is ethertype or payload size but generally in most networks it will be type. Depending on the value, it can either be size of payload or ethertype. If it is 1536 or above then it is an ethertype. If it is lower than 1536 then it is size of payload and you need a 802.2 header to show type.
  • bermovickbermovick Member Posts: 1,135 ■■■■□□□□□□
    OK; I grabbed Odom's book (Lammle's CCENT book doesn't seem to work very well for me. At least I got it cheap), and I'm actually staring at the OSI table on page 34 and I'm still not getting it, since it seems to me the destination doesn't care about layer 3 much other than "yup, thats my IP address" before passing it up to the Transport layer.

    OK; I'm guilty of tunnel vision there - what if it's not IP? The books only discuss IP, but if it were IPX layer3 would need to know this ahead of time so I suppose it does make sense now... sortof.

    Maybe it's good that I'm going through this; it converts the raw information into semi-practical (and easier remembered) information, but it's frustrating haha.
    Latest Completed: CISSP

    Current goal: Dunno
  • tierstentiersten Member Posts: 4,505
    bermovick wrote: »
    since it seems to me the destination doesn't care about layer 3 much other than "yup, thats my IP address" before passing it up to the Transport layer.
    You can't just assume that every ethernet frame that comes in is IPv4 as you don't just have IP on a network. Even on the most basic network you'll have ARP, ICMP and IPv4 packets. How does it know that the payload is an IPv4 datagram or an ARP request? Looking at the packet and going well... if these octets at position blah to blah match up with my IP then I'm going to assume it is an IPv4 packet is unreliable and inefficient.

    Instead you can look at the ethertype field in whatever header it is located in and go it is 0x800 so therefore I know that this is an IPv4 packet. Or it is 0x806 so I know it is ARP.
    bermovick wrote: »
    OK; I'm guilty of tunnel vision there - what if it's not IP?
    It'd be a different ethertype assuming that they're following the standard.
  • bermovickbermovick Member Posts: 1,135 ■■■■□□□□□□
    Yeah; the second half of my previous post was more of musing & trying to get it to fit, and I (tentatively) got it to. I've looked further and verified each layer gets a piece of information from the layer above it similarly; layer 2 has the 'type' field, layer 3 has the 'protocol field', layer 4's port since that links it to the appropriate higher-layer application.
    Latest Completed: CISSP

    Current goal: Dunno
Sign In or Register to comment.