WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Need to use tiny core to send snmpget requests. How?  (Read 5745 times)

Offline maapinho

  • Newbie
  • *
  • Posts: 7
Need to use tiny core to send snmpget requests. How?
« on: March 17, 2016, 07:03:08 AM »
Hi,
I have been using tiny core to learn a bit of linux and do some testing. I installed net-snmp but Im unable to execute the "snmpget" commands. Wasn't this supposed to work after installation? How to send requests?

Thanks

Mario

Offline patrikg

  • Wiki Author
  • Hero Member
  • *****
  • Posts: 661
Re: Need to use tiny core to send snmpget requests. How?
« Reply #1 on: March 17, 2016, 07:12:55 AM »
What error message did you get in the terminal ?

Offline maapinho

  • Newbie
  • *
  • Posts: 7
Re: Need to use tiny core to send snmpget requests. How?
« Reply #2 on: March 18, 2016, 11:48:08 PM »
It does not find the command. Tab does not autocomplete. Its like it did not install

Offline curaga

  • Administrator
  • Hero Member
  • *****
  • Posts: 10957
Re: Need to use tiny core to send snmpget requests. How?
« Reply #3 on: March 19, 2016, 01:57:41 AM »
If you look at the file list of net-snmp, it does not include snmpget.
The only barriers that can stop you are the ones you create yourself.

Offline maapinho

  • Newbie
  • *
  • Posts: 7
Re: Need to use tiny core to send snmpget requests. How?
« Reply #4 on: March 19, 2016, 06:39:25 AM »
But is there a way to poll snmp poll v1/v2c agents? Any other application?

Sent from my SM-G900F using Tapatalk


Offline andyj

  • Hero Member
  • *****
  • Posts: 1020
Re: Need to use tiny core to send snmpget requests. How?
« Reply #5 on: March 19, 2016, 09:47:24 AM »
Is this 32-bit or 64-bit? I just (in the last few minutes) built the 64-bit version, in my quest to build PHP 7. It has snmpget. I have a 32-bit version I made a while ago using the latest version of net-snmp so PHP 7 would build, but I haven't uploaded it yet. I don't have access to the 32-bit VM right now (it's at work) so I can't say for sure what files will be in it.

Offline maapinho

  • Newbie
  • *
  • Posts: 7
Re: Need to use tiny core to send snmpget requests. How?
« Reply #6 on: March 21, 2016, 12:41:07 PM »
Andy,
Its 64-bits. Not a very recent one. So is there a way to get snmpget in the one I have without having to install a new one?
How do I check the version I have running?

Mario

Offline Rich

  • Administrator
  • Hero Member
  • *****
  • Posts: 11178
Re: Need to use tiny core to send snmpget requests. How?
« Reply #7 on: March 21, 2016, 04:54:21 PM »
Hi maapinho
Quote
How do I check the version I have running?
Open a terminal and enter  version

Offline maapinho

  • Newbie
  • *
  • Posts: 7
Re: Need to use tiny core to send snmpget requests. How?
« Reply #8 on: March 21, 2016, 05:25:17 PM »
Whats a term.... just kidding.
Version 6.4.1

Sent from my SM-G900F using Tapatalk


Offline andyj

  • Hero Member
  • *****
  • Posts: 1020
Re: Need to use tiny core to send snmpget requests. How?
« Reply #9 on: March 21, 2016, 07:13:32 PM »
I'll confess to having next to no SNMP knowledge, like I said I just built it so I could get a decently featured set of server apps (openldap, net-snmp, mariadb, postgresql, apache, php, open-vm-tools and a bunch of supporting libraries like cyrus-sasl, libiconv, libiodbc, libmcrypt, libaio, libgd) for 64-bit put together and up to date. I can handle the LAMP part. It would be nice if someone experienced in the  esotaric arts like LDAP and SNMP could verify my work. I built net-snmp using this:

./configure --disable-embedded-perl --with-mysql --with-perl-modules --with-defaults --without-rpm

Along with the libraries and mib files there are these executables:

./usr/local/bin/snmpget
./usr/local/bin/net-snmp-create-v3-user
./usr/local/bin/snmpnetstat
./usr/local/bin/snmpset
./usr/local/bin/snmpdf
./usr/local/bin/net-snmp-config
./usr/local/bin/snmpbulkget
./usr/local/bin/mib2c-update
./usr/local/bin/encode_keychange
./usr/local/bin/snmpwalk
./usr/local/bin/snmpdelta
./usr/local/bin/traptoemail
./usr/local/bin/snmpstatus
./usr/local/bin/snmpconf
./usr/local/bin/snmp-bridge-mib
./usr/local/bin/snmptrap
./usr/local/bin/snmpusm
./usr/local/bin/agentxtrap
./usr/local/bin/snmpcheck
./usr/local/bin/snmpinform
./usr/local/bin/tkmib
./usr/local/bin/snmpvacm
./usr/local/bin/snmpgetnext
./usr/local/bin/net-snmp-cert
./usr/local/bin/snmptranslate
./usr/local/bin/snmptable
./usr/local/bin/mib2c
./usr/local/bin/fixproc
./usr/local/bin/snmpbulkwalk
./usr/local/bin/ipf-mod.pl
./usr/local/bin/snmptest
./usr/local/sbin/snmptrapd
./usr/local/sbin/snmpd

Does this look complete (enough)? I haven't had time to double check it. I got it to compile, I hand made the extensions, and I moved on. Running an old binary on a new system is a lot less of a problem than running a new binary on an old system. Have you tried other 7.0 extensions (actually compiled on 7.0 and not just copied up from prior versions) to see if they run OK?

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14516
Re: Need to use tiny core to send snmpget requests. How?
« Reply #10 on: March 21, 2016, 11:03:38 PM »
...and a bunch of supporting libraries like cyrus-sasl, libiconv, libiodbc, libmcrypt, libaio, libgd) for 64-bit put together and up to date.

libiconv functions have been provided by glibc in the last three or four versions of tinycore so it is not required - please don't build new extensions that rely on a libiconv extension rather than the iconv functions in glibc.

Offline maapinho

  • Newbie
  • *
  • Posts: 7
Re: Need to use tiny core to send snmpget requests. How?
« Reply #11 on: March 22, 2016, 02:45:43 AM »
Hi Andy,
Before going further let me introduce myself as what you might call a "Windows guy". So I cannot answer most of what you have asked. I can say though that snmpget, snmpwalk and snmpgetnext is what I'm looking for.

Initially I understand you built and I could download from tinycorelinux.net site. But if I understand correctly you have built it for yourself. Is that it?

Can you provide details on how I can do it myself? that ./configure command. Where should I run it? Any links you can provide?

To test snmp basic snmp I just use: demo.snmplabs.com/
« Last Edit: March 22, 2016, 02:48:26 AM by maapinho »

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14516
Re: Need to use tiny core to send snmpget requests. How?
« Reply #12 on: March 22, 2016, 02:56:43 AM »

Offline andyj

  • Hero Member
  • *****
  • Posts: 1020
Re: Need to use tiny core to send snmpget requests. How?
« Reply #13 on: March 22, 2016, 05:25:47 AM »
I am building them with the intent of uploading them when I'm done. I just haven't finished testing them, and I also still have a lot of other files to prepare before I can submit them. See Juanito's link. I could send them to you offline so you can help me test if you PM me.

@junanito I will try to convince the configure scripts to get the iconv functions from glibc. They can be a little hard to "adjust". Also, some of these packages' fail to make on lto-wrapper, so I'm having to not use the -lto compiler flag.

Online Juanito

  • Administrator
  • Hero Member
  • *****
  • Posts: 14516
Re: Need to use tiny core to send snmpget requests. How?
« Reply #14 on: March 22, 2016, 05:28:41 AM »
thanks - I only ever recall one package that didn't automatically use iconv() from glibc (as long as libiconv is not present)...