Ascend Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: (ASCEND) MIB to get user phone number
> little question... I've installed the CMU SNMP client/server/development
> package yesterday... aaahhhh... But how to use it??? My linux box
> is functionable (but I don't want this :))) ) I have a /usr/lib/mib.txt
> with many things in it. Can someone who also uses this unix software
> please tell me how I can customize it to use it with the MAX ???
> (I have already downloaded the ascend.mib... (do I need other
> files??, what to do with this file??))
You will need all of the Ascend *.mib files from the ftp site. Once you
download them, add them to the existing mib.txt, like so:
# cat ascend.mib >> mib.txt
Then all of your command should become useable with the Ascend boxes.
If in doubt, always check the man page.
How do you figure out those strange numbers to use along with the
commands? Simple. Imagine you want to find various info (session
index, ipaddress and name) about all the active users on the system.
# grep -in activeuser mib.txt
14550: ssnActiveUserName
14552: ssnActiveUserIPAddress
14554: ssnActiveUserSubnetMask
14591: ssnActiveUserName OBJECT-TYPE
14599: ssnActiveUserIPAddress OBJECT-TYPE
14607: ssnActiveUserSubnetMask OBJECT-TYPE
Now you check the object at line 14591:
# vi +14591 mib.txt
>From there you learn that this particular subidentifier (number 4)
belongs to sessionActiveEntry. You back off to that object, and
you see that this particular object (number 1) meets all your
requirements (has all the information you need) and belongs to
sessionActiveTable. Above it you find that sessionActiveTable
(number 3) belongs to sessionStatusGroup. Session StatusGroup is
number 12. From the RFC 1700 (Assigned Numbers) you already know
that the path to the enterprise mibs is .1.3.6.1.4.1 and that Ascend
is 529. Now you are ready to put it together: .1.3.6.1.4.1.529.12.3.1
>From the description of sessionActiveEntry you know that it contains
more information you need, so you use grep to filter out unnecessary
stuff:
# snmpwalk -v 1 yourmax public .1.3.6.1.4.1.529.12.3.1 | egrep 'Index|Name|UserIPAddress' | sed 's/^.*= //g'
The last part (sed) trims the display a bit.
Naturally, it is hard to use them always from the command line
(remembering and typing those variables or there numeric equivalents
*is* a pain). You'd be best off if you put the most often used
ones in shell scripts. For example, the above could be set up to
automatically scan all you routers:
====
#!/bin/sh
MAXES="mymax1 mymax2 mymax3 mymaxetc mymaxmore"
for i in $MAXES
do
echo "=== $i ==="
snmpwalk -v 1 $i public .1.3.6.1.4.1.529.12.3.1 | egrep 'Index|Name|UserIPAddress' | sed 's/^.*= //g'
done
====
Naturally, if you have a lof of maxes, you can set up a text file with
the listing.
Let's see, have I missed anything? Oh, yeah, after you download all of
the Ascend mibs, just read through them. It's a quick and easy read,
and you will have an idea of what you can do with them (they're very
nicely commented). Pay attention to the "ACCESS" field definition for
each object. It will tell you whether you can modify it or just read.
t.
---------------------------------------------------------------------
Tony Porczyk * tony@infobound.com * www.infobound.com * San Jose, Ca.
GIT/ED d++(!d) s++:++ a? C++++ USB++++$ P+ E- W(--) N++ !k w--- M- V?
PS+++ PE++ Y+ PGP-- t+@ 5++ X-- R* b- D---- e* V-- h* r+++(*)+++(*)>?
---------------------------------------------------------------------
++ Ascend Users Mailing List ++
To unsubscribe: send unsubscribe to ascend-users-request@bungi.com
To get FAQ'd: <http://www.nealis.net/ascend/faq>
References: