according to http://www.cisco.com/c/en/us/td/docs/switches/lan/catalyst3650/software/release/3se/consolidated_guide/configuration_guide/b_consolidated_3650_3se_cg/b_consolidated_3650_3se_cg_chapter_0110101.html#concept_5EF41C4D38FF48A1B413B921718585E0 the switch should use a value from a specific range for each interface type.
What I notice is instead that the switch starts with 1 for the Management interface (Gi0/0), then 2 for Null0, then it uses 3 to 26 (for 3650-24P) or 3 to 50 (for 3650-48P), then 27 to 30 or 51 to 53 for stack ports, then is the time of SVI(s) and finally port-channels. But if a second stack is added, then it is computed before SVI(s) and the port-channels. So you'll never have a stable ifindex to point to with your network management ifindex-based software, because it depends on stack members (how many) and models and their exact position (stack number).
Old 3750 has a fixed schema so that you know in advance every ifindex value for every stack member mib object (for example ifindex of the Fa1/0/1 interface is always 10001, ifindex of the Fa2/0/1 interface is always 10501, ifindex value of the Port-channel 1 is always 5001 and so on).
With 3650, ifindex value of the interface Port-Channel 1 is 36 for a 3650-24P standalone and 60 for a 3650-48P standalone, but if you have two 3650-48P then it is 115. And if you have a mix of 3650 (24P and 48P) it becomes almost impossible to keep up with all the possible combinations.
How can I obtain the same behavior of 3750's ifindex values on 3650 also or, more simply, how to get what the above link states ?
Thanks in advance
I would advise to use this command "snmp-server ifindex persist"
Read the below link for further detail::
***Ratings Encourages Contributors ****
Unfortunately this does not solve the main problem: the switch still doesn't respect any range rule while assigning ifindex values and this makes difficult preparing generic probes (Gi2/1/1 ifindex value of a 3650-24P will be anyway different from the Gi2/1/1 ifindex value of another 3650-24P if their stack1 switch model is not the same...)
Anyway thanks a lot for the answer!