Sponsored Content
Full Discussion: snmpd manager question
Operating Systems Solaris snmpd manager question Post 302195258 by jalburger on Wednesday 14th of May 2008 03:41:52 PM
Old 05-14-2008
I could even code for this if I could determine the originating IP address for the SNMP set packet in my subagent. But...I don't know if that is possible or how to do it. ???
 

10 More Discussions You Might Find Interesting

1. UNIX for Advanced & Expert Users

Logical Volume Manager question

After creating a make recover tape on a TAC-4 9000/770, the system lost three of five volume groups from the /etc/lvmtab. What would be the best way to recreate the volume groups in the lvmtab? (1 Reply)
Discussion started by: spawarrior
1 Replies

2. UNIX for Dummies Questions & Answers

snmpd daemon error

Good day I always find these error messages on /var/adm/messages it appear every 15 mn , does any body know how to stop these messages without stopping the daemon , i tried to restart the daemon by uising Kill -HUP 332 please find below the error messages that appear always in... (1 Reply)
Discussion started by: itsgeorge
1 Replies

3. AIX

snmpd modification problem

Hi Gurus, I am relatively new in AIX. I have a problem in modifying the community string in snmpd. I have edited the /etc/snmpd.conf file and changed the default community name 'public' to new one (P@@$w0rd). When I tried to query my aix server with the new string , it is not giving any... (1 Reply)
Discussion started by: helloajith
1 Replies

4. Linux

Snmpd

Hello to all. For setting my MRTG i want get snmp-info with LAN interface eth0 but information about snmpd daemon very small :( (0 Replies)
Discussion started by: jess_t03
0 Replies

5. HP-UX

SNMPD: need a little help.

Hi there all, I am running here an HP UX 11i v1. I got snmpd running here now. But how do I configure it so it also shows the HD's and swap and RAM's? So I can get the info back to Solarwinds Orion? All I get now is network card status. I want as many info as posible.. Thanx and... (0 Replies)
Discussion started by: draco
0 Replies

6. Debian

gnome file manager configuration question

Is there a way to configure the gnome file manager to open each directory in the same window instead of opening a new one? (Debian 5.0.0) (5 Replies)
Discussion started by: snorkack59
5 Replies

7. UNIX for Advanced & Expert Users

Veritas Volume Manager question (Disk layout with 4 plexes)

I am trying to build a veritas volume similar to an existing volume on another server. The output on source server is: usbtor12# vxprint -hrtg appdg v anvil_sqlVOL - ENABLED ACTIVE 629145600 SELECT - fsgen pl anvil_sqlVOL-01 anvil_sqlVOL ENABLED ACTIVE 629145600... (3 Replies)
Discussion started by: momin313
3 Replies

8. Infrastructure Monitoring

AIX - snmpd version

Hi, I have a P595 server with AIX 5.3 and i need to know what version of snmpd i use on this: Example: On solaris i use Net-snmpd 5.4.2.1 (netsnmp-5.4.2.1-sol9-sparc-local) because i can see the package. How can i see what snmpd package is installed on the AIX? Thanks... (3 Replies)
Discussion started by: anonymouzz
3 Replies

9. AIX

Disable snmpd for good

Hi everyone, I am struggling with something that I thought it would be really easy. I want to disable snmpd, but every time y reboot my server, it starts again. I've commented it out on the rc.tcpip file, but still it starts automatically. # Start up the Simple Network Management Protocol (SNMP)... (4 Replies)
Discussion started by: Janpol
4 Replies

10. Red Hat

Snmpd dying on centos7.1

Hello All, SNMPD dying after 2 mins once it started. Here is the configuration Oct 12 04:43:00 localhost systemd: Starting Simple Network Management Protocol (SNMP) Daemon.... Oct 12 04:43:00 localhost snmpd: dlopen failed: /usr/lib64/libcmaX64.so: cannot open shared object file: No such... (1 Reply)
Discussion started by: shekar777
1 Replies
NETSNMP_AGENT_API(3)						     Net-SNMP						      NETSNMP_AGENT_API(3)

NAME
netsnmp_agent_api - embedding an agent into a external application SYNOPSIS
#include <net-snmp/net-snmp-config.h> #include <net-snmp/net-snmp-includes.h> #include <net-snmp/agent/net-snmp-agent-includes.h> int main (int argc, char *argv[]) { int agentx_subagent = 1; /* Change this if you're a master agent. */ snmp_enable_stderrlog(); /* If we're an AgentX subagent... */ if (agentx_subagent) { /* ...make us an AgentX client. */ netsnmp_ds_set_boolean(NETSNMP_DS_APPLICATION_ID, NETSNMP_DS_AGENT_ROLE, 1); } init_agent("yourappname"); /* Initialize your MIB code here. */ init_my_mib_code(); /* `yourappname' will be used to read yourappname.conf files. */ init_snmp("yourappname"); /* If we're going to be a SNMP master agent... */ if (!agentx_subagent) init_master_agent(); /* Listen on default port (161). */ /* Your main loop here... */ while (whatever) { /* if you use select(), see snmp_api(3) */ /* --- OR --- */ agent_check_and_process(0); /* 0 == don't block */ } /* At shutdown time: */ snmp_shutdown("yourappname"); } Then: $(CC) ... `net-snmp-config --agent-libs` DESCRIPTION
Our goal is to create a easy to use interface to the Net-SNMP package such that you can take code that you have written that has been designed to be a Net-SNMP MIB module and embed it into an external application where you can either chose to be a SNMP master agent or an AgentX sub-agent using the same MIB module code. Our suggestion is that you use our (or another) SNMP agent as the AgentX master agent and chose to become an AgentX subagent which then attaches to the master. The Net-SNMP package provides a pair of libraries that enables easy embedding of an SNMP or AgentX agent into an external software package. AgentX is an extensible protocol designed to allow multiple SNMP sub-agents all run on one machine under a single SNMP master agent. It is defined in RFC 2741. You will need to perform a few tasks in order to accomplish this. First off, you will need to initialize both the SNMP library and the SNMP agent library. As indicated above, this is done slightly differently depending on whether or not you are going to perform as a master agent or an AgentX sub-agent. CONFIGURATION
If you intend to operate as an AgentX sub-agent, you will have to configured the Net-SNMP package with agentx support (which is turned on by default, so just don't turn it off) Additionally, you will need to link against the net-snmp libraries (use the output of "net-snmp-config --agent-libs" to get a library list) and call subagent_pre_init() as indicated above. COMPILING
In order to make use of any of the above API, you will need to link against at least the four libraries listed above. FUNCTIONS
where to find out more information on them. It is certainly not a complete list of what is available within all the net-snmp libraries. snmp_enable_stderrlog() Logs error output from the SNMP agent to the standard error stream. netsnmp_ds_set_boolean() Please see the default_store(3) manual page for more information about this API. init_agent(char *name) Initializes the embedded agent. This should be called before the init_snmp() call. name is used to dictate what .conf file to read when init_snmp() is called later. init_snmp(char *name) Initializes the SNMP library. Note that one of the things this will do will be to read configuration files in an effort to config- ure your application. It will attempt to read the configuration files named by the name string that you passed in. It can be used to configure access control, for instance. Please see the netsnmp_config_api(3), snmp_config(5), and snmpd.conf(5) manual pages for further details on this subject. init_master_agent(void) Initializes the master agent and causes it to listen for SNMP requests on its default UDP port of 161. agent_check_and_process(int block) This checks for packets arriving on the SNMP port and processes them if some are found. If block is non-zero, the function call will block until a packet arrives or an alarm must be run (see snmp_alarm(3)). The return value from this function is a positive integer if packets were processed, zero if an alarm occurred and -1 if an error occured. snmp_shutdown(char *name); This shuts down the agent, saving any needed persistent storage, etc. SEE ALSO
http://www.net-snmp.org/tutorial-5/toolkit/ select(2), snmp_api(3), default_store(3), snmp_alarm(3), netsnmp_config_api(3), snmp_config(5), snmpd.conf(5) V5.6.2.1 13 Aug 2010 NETSNMP_AGENT_API(3)
All times are GMT -4. The time now is 02:42 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy