tutayahoo.blogg.se

Snmp walk tool for mac
Snmp walk tool for mac













  1. SNMP WALK TOOL FOR MAC MAC
  2. SNMP WALK TOOL FOR MAC WINDOWS

Int port = int.Parse(v.Value.ToString()) - (52 * (dellSwitch - 1))

snmp walk tool for mac

Int dellSwitch = 1 + int.Parse(v.Value.ToString()) / 52

snmp walk tool for mac

You need to know these values to correctly iterate through a stack of switches. agent reported an error with the requestĬonsole.WriteLine("Error in SNMP reply. the Agent - see SnmpConstants for error definitions ErrorStatus other then 0 is an error returned by If result is null then agent didn't reply or we couldn't parse the reply. You should catch exceptions in the Request if using in real application. SnmpV1Packet result = (SnmpV1Packet)target.Request(pdu, param) Initialize request PDU with the last retrieved Oid that needs to be incremented on subsequent requests made using the When Pdu class is first constructed, RequestId is set to a random value This Oid represents last Oid returned by the SNMP agent Define Oid that is the root of the MIB tree you wish to retrieve OctetString community = new OctetString(snmpCommunity) ĪgentParameters param = new AgentParameters(community) Private void SnmpWalk(IPAddress ip, string snmpCommunity, string oid, string switchNum) Ports will be labeled SwitchNum/Stack Number/Port Numbers.

snmp walk tool for mac

SNMPWALK the ports on a switch or stack of switches.

SNMP WALK TOOL FOR MAC MAC

Here's an example that will create a list of all the MAC Addresses and Ports on a particular Dell Switch using the OID 1.3.6.1.2.1.17.7.1.2.2.1.2.1 using SnmpSharpNet

SNMP WALK TOOL FOR MAC WINDOWS

If any one you would like to do this programmatically from a Windows Server you can use the SnmpSharpNet library to accomplish the same thing. *= rack models: cisco 2900xl, foundry FI4802 + variants

  • How do I go about using device specific MIBs (.snFWSXFamily)?.
  • Is there a foundry specific string that returns ports and macs? ifindexes would also work.
  • I was able to find the specific device models under foundry > products > registration, but there aren't any MIBs under that folder. 1.3.6.1.1.1.3.3.1.1.38 kinda comes close to what I'm looking for but im not entirely comfortable it's what I'm looking for. 1.3.6.1.2.1.31.1.1.1.1 works on most of the switches but a few of the foundrys do not work. Lastly, it takes the mac, ips, and port and populates the master table.
  • Repalce the mac hash with the actual mac.
  • snmp walk tool for mac

  • Replace the bridge ID with the mac hash.
  • Replace the ifindex with with a bridge ID.
  • Create a multi-array with the port as the key and the ifindex for the value.
  • Since there is no golden command (cue lightbulb over your head), I have to: Then, it loops through all of the racks* and attempts to find which port that mac belongs to. It first pulls a huge list of macs and their ips from both of the cores into a temp table. I work at a datacenter and I'm in the process of writing a php tool that maps all of our devices and can tell us if what is out there is what is being billed for.















    Snmp walk tool for mac