Announcement

Collapse
No announcement yet.

SNMP (Linux SDK - Xport Pro)

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • SNMP (Linux SDK - Xport Pro)

    [Updated 21-APR-2011]

    1.) make menuconfig

    Network Applications >> net-snmp >> Build mini agent >> Build Applications (snmpget, snmpgetnext, snmpset, snmptranslate, snmpwalk) >> Build static (BUG - requires manual file edit,search forum for note on this) >> Install MIBs >> Enable MIB Loading >> Additional MIBS (mibII if-mib ucd_snmp agent/extend), then exit saving changes.
    2.) make

    3.) a build folder is created under lantronix/linuxsdk/user/net-snmp/build

    The snmpd file within the build/agent folder is compiled with mibroup folders, etc inside the file. The snmpd file is automatically built into the image file and will be under /bin/ on the Xport
    4.) Ceate a snmpd.conf file under lantronix/vendors/lantronix/xport_pro/romfs_extra/etc if you want it build into the image next time you run make. Or you can simply create and edit through telnet using vi.

    agentaddress 161
    rocommunity public (change to whatever you want)
    syslocation Tampa, FL USA
    syscontact John Doe
    5.) Edit the lantronix/venders/lantronix/xport_pro/romfs_extra/etc/start file and add this line as the last line in the file:

    /bin/snmpd -c /etc/snmpd.conf
    6.) after all of this you can do the following to test from your pc, assuming you have installed net-snmp (http://sourceforge.net/projects/net-...2.exe/download)

    snmpwalk -v 1 -c public 192.168.1.100 syslocation (IP is XPort IP)

    and you will get
    SNMPv2-MIB::sysLocation.0 = STRING: Tampa, FL USA
    PS - If anyone else needs help with instructions posted above let me know.
    Last edited by techadmin; 04-21-2011, 03:28 PM.

  • #2
    QUESTION:
    I want to add /dev/ttyS0 incoming serial data to SNMP monitoring. Anyone gone down this path that can help me out?

    One option would be to cat /dev/ttyS0 > file.txt, then awk the file contents. However, I do not wish to use flash due to 100,000 write cycle limit. Maybe this can be done saving to ram, just looking for a simple solution, if their is such a thing.

    Comment


    • #3
      I did not get the question. Sorry for that.

      Do you mean to say, You want to get the same data came from serial port, from SNMP master. Is it true?

      Comment


      • #4
        Great how-to for getting the SNMP compiled in, but it is not working for me.

        I have it compiled in and is up and running from startup.
        / # ps aux | grep snmp
        78 root 1582 S /bin/snmpd -c /etc/snmpd.conf
        and the device has net connection
        / # ifconfig
        eth0 Link encap:Ethernet HWaddr 00:20:4A:C3:00:02
        inet addr:192.168.2.193 Bcast:192.168.2.255 Mask:255.255.255.0
        When I run the snmpwalk from any other system, I get a timeout.

        snmpwalk -v 1 -c public 192.168.2.193 syslocation
        Timeout: No Response from 192.168.2.193
        This is on an older XPort Pro module. I believe it is the 8MB, not the 16MB. I put in a request to my boss to get some new 16MB modules just in case that could be part of the problem.

        Any advice will be appreciated!
        Thanks
        Last edited by tulinski; 12-14-2011, 07:49 PM.

        Comment


        • #5
          Update:

          Found the error. I had a typo in my snmp.conf file.

          Comment


          • #6
            Cannot change Community Name

            Originally posted by techadmin View Post
            [Updated 21-APR-2011]

            1.) make menuconfig



            2.) make

            3.) a build folder is created under lantronix/linuxsdk/user/net-snmp/build



            4.) Ceate a snmpd.conf file under lantronix/vendors/lantronix/xport_pro/romfs_extra/etc if you want it build into the image next time you run make. Or you can simply create and edit through telnet using vi.



            5.) Edit the lantronix/venders/lantronix/xport_pro/romfs_extra/etc/start file and add this line as the last line in the file:



            6.) after all of this you can do the following to test from your pc, assuming you have installed net-snmp (http://sourceforge.net/projects/net-...2.exe/download)



            PS - If anyone else needs help with instructions posted above let me know.
            Hi,

            I am not able to change the community name in my XPort Pro 16MB unit. I am following the steps you recommend below, all of them except build static that i am not able to find, but but when executing make the snmpd.conf contents are the default ones.

            Thanks in advance!!
            Last edited by JTORRES; 05-21-2015, 01:50 PM.

            Comment

            Working...
            X