10-12-2010 11:41 AM
(Before anyone says anything , yes, I know SNMP is not an advertised feature of the SLM2008, but where's the fun in that?)
So does anyone know how to edit the switch.cfg file generated by the device when you go to save the configuration? (No, its not text, its binary, and its "obviously" checksummed in some manner, since any changes to the file cause it to be rejected when attempting to upload it.
It seems SNMP is enabled .. sorta.. I'm not entirely certain if the firmware tries to disable it intentionally and fails due to a bug, or if there's some other problems with SNMP...
If you reset the device to factory defaults, either by hitting the reset button long enough or via the "Admin->Factory Default" menu option, SNMP is left enabled. (Note the "Admin->Factory Default" option is the way to reset everything but keep a different IP address)
$ snmpwalk -v 2c -c public 192.168.0.248 |more
SNMPv2-MIB::sysDescr.0 = STRING: Linksys SLM2008 - 8 Port Gigabit Switch - 2.0.0.10
SNMPv2-MIB::sysObjectID.0 = OID: SNMPv2-SMI::zeroDotZero
DISMAN-EVENT-MIB::sysUpTimeInstance = Timeticks: (474000) 1:19:00.00
SNMPv2-MIB::sysContact.0 = STRING: SYSTEM CONTACT
SNMPv2-MIB::sysName.0 = STRING:
SNMPv2-MIB::sysLocation.0 = STRING: SYSTEM LOCATION
SNMPv2-MIB::sysServices.0 = INTEGER: 3
<snip>
Note SNMP goes away as soon as you change anything on the System Settings page. (Even if you leave the default password as default.) Tweaking the other pages does not seem to... (Albeit, I've not gone through every setting.)
Looking at a few config files, it "seems" fairly obvious the default system password, the default read-only, and read-write community strings are in there, so the question becomes, how to edit the config file, and change the passwords......
Any ideas, or anyone ever poked that far under the covers?
David
10-18-2010 04:46 AM
I find the following script I wrote works fairly successfully.
Configure the switch as you wish, then run the script.
Give it a hostname/ip address, or the name of a config file you've downloaded. It'll prompt for adminstrator name, and password, if its a remote host.
Its not had a great deal of testing, since I've only got the one switch, but it worked in my case. (To change the read-write private string, and re-enable SNMP). I'd not make the community passwords too long, since there's obviously no documentation on maximum length. (besides the obvious "public" == 6 characters, and "private" == 7 characters).... I chose a 15 character maximum based on some guesses from other strings in the cfg file, but it could be wrong, so perhaps keeping them short would be best.
Web enteredSystem Location does not appear in SNMP, but the System Name does, you can however do a snmpset, and change it till the next reboot. If there's a way to configure SNMP traps, I don't know about it.
If it blows up, you're on your own, no guarentees of fitness for any purpose are provided, but I hope it helps someone in the future...
Now I need to go configure cacti monitoring against it.....
David
08-05-2012 07:01 PM
Very probably the reason it's not supported, and not easy to enable, is the fact that it doesn't work very well.
Reading
Port: 101 In: 3483196972 Out: 1244538319
Port: 101 In: 18446744072907087039 Out: 124500312
Port: 101 In: 3501862218 Out: 1245490073
Trying
Willie
01-27-2017 03:34 PM
The script worked fine for me too. Thanks.
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide