I have noticed that when you set up your vlan interface , a default mtu is set. Vlan mtu equals 9192. When I added ipv6 addressing I think I set it to 9174. Must have been default, I don't remember. Is it better to match these two numbers? What are the implications of setting them the same as oppossed to a little different like they currently are?
I believe we need to start by defining MTU, which is not other thing than the size of the packets/frames that can be received or sent over a logical/physical interface. Note that the size will depend on the fact that we are talking about frames (at layer 2) or packets (at layer 3); this is why I stated that the MTU is the size of the packet/frame that a logical/physical interface can process.
When a host will be sending data, it will be encapsulated in a way similar to this one:
When the MTU related to the logical interface (aka Protocol MTU) is calculated, we are talking about the size of the IP packets that the interface can process. This value includes the size of the data being sent (the payload) plus the L4 and L3 headers' size. Note that the L2 header size is not taken in to consideration. For regular Ethernet networks generally this protocol MTU is 1500 bytes:
PAYLOAD (1460Bytes)+ TCP Header (20 bytes)+ IP Header (20 bytes)= A packet (1500 bytes)
When the MTU related to the physical interface (aka Interface MTU) is calculated, we are talking about the size of the frames that the interface can process. This counts the amount of data being sent plus the L4, L3 and L2 headers. For instance a regular Ethernet frame has a size of 1518bytes:
PAYLOAD (1460Bytes)+ TCP Header (20 bytes)+ IP Header (20 bytes)+ Ethernet Header (18 bytes)= A frame (1518 bytes)
Now we can understand why we see more than one MTU value in the "show interfaces extensive" output for the same interface:
Note that the Interface MTU is 18bytes bigger than the Protocol MTU because the first one takes in to consideration the Ethernet header size.
Knowing the above information, now lets review your questions:
Q.I have noticed that when you set up your vlan interface , a default mtu is set. Vlan mtu equals 9192. When I added ipv6 addressing I think I set it to 9174. Must have been default, I don't remember. Is it better to match these two numbers?
A/ You wont be able to match them. One represents the size of the packets (Protocol MTU, a L3 concept) and the other one the size of the frames (Interface MTU, a L2 concept). The last one includes 18 more bytes than the first one.
Q.What are the implications of setting them the same as opposed to a little different like they currently are?
A/ A packet of a size of 1500 bytes can be sent over a logical interface that has a Protocol MTU of 1500. But when the Ethernet header is added, that packet becomes a frame of 1518 bytes, and having a physical interface configured with a Interface MTU of 1500 will avoid/prevent that 1518 frame to be sent. This is why when you manually set the Protocol MTU, the Interface MTU will automatically change to a value 18ytes bigger.
Q. I changed my mtu to a different value, i could not match the ipv6 with the base interface mtu. vlan mtu vs. vlan.0 ipv6 mtu. Says ipv6 number must not be greater than vlan mtu
A/ They are never supposed to be the same. The interface MTU will be normally (if not always) 18bytes bigger than the protocol MTU because while the protocol MTU talks about packets' sizes, the interface MTU talks about frames' sizes that include the 18 more bytes of the Ethernet header.
Q. 1536 on other devices is advisable?
R/ You have to understand if you are configuring Protocol or Interface MTU. Lets say you are configuring the Protocol MTU (defining the size of the packets that can be sent by a logical interface). If the SRX will send a packet size of 8982 bytes, after this packet gets encapsulated at L2 (an Ethernet header of 18 bytes will be added), the size of the resulting frame will be of 9000bytes. The sending physical interface should have a Interface MTU of 9000, else it will drop that frame because it exceeds the size of the frames that the interface can send.
Once the 9000 bytes frame reaches the remote physical interface, it will be accepted only if the remote physical interface has a Interface MTU of 9000 or higher. Once the Ethernet header is removed, we will have a 8982 bytes packet, that could be accepted/processed only if the logical interface has a Protocol MTU of 1500 or higher.
I hope that the above information helps you.
Pura Vida from Costa Rica - Mark as Resolved if it applies. Kudos are appreciated too!