Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options

Re: changing localaddr

by Khen1950fx (Canon)
on Nov 02, 2011 at 17:30 UTC ( #935454=note: print w/replies, xml ) Need Help??

in reply to changing localaddr

I was thinking along the same lines as NetWallah, but I discovered that -agentaddr isn't recognized by SNMPv2c. Maybe this is closer to what you need.
#!/usr/bin/perl use strict; use warnings; use Net::SNMP::XS; use Net::SNMP qw(:ALL); my ( $session, $error ) = Net::SNMP->session( -hostname => '', -community => 'public', -localaddr => '', -port => SNMP_TRAP_PORT, -version => 'snmpv2c', -community => 'public', -debug => '0x02', -nonblocking => 0, ); if ( not defined $session ) { printf "ERROR: %s.\n", $error; exit 1; } my $result = $session->snmpv2_trap( -varbindlist => [ '', TIMETICKS, 600, '', OBJECT_IDENTIFIER, '', '', OCTET_STRING, 'Hub', '', OCTET_STRING, 'Closet Hub', ], ); if ( not defined $result ) { printf "ERROR: %s.\n", $session->error(); } else { printf "SNMPv2-Trap-PDU sent.\n"; }

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://935454]
[Corion]: ambrus: Yeah - we're in that situation too, except that there is no time to do the reorganizing :-/
[LanX]: ... so my boss started a project with the newest sun servers and invited the traders to come on weekend to test it... and they were so pleased, that they forced him to keep it in production...
[ambrus]: Corion: sure, this is the long-term plan. The short term is that I have to run this ungodly mess to get results from the new input data today.
[Corion]: ambrus: Most of our "automation" is tied to process exit codes and a shell pipeline :-\
[LanX]: ... a week later they realized that one of the databases - which recorded how much the other banks due to this bank - was not correctly plugged
[ambrus]: Corion: I have no problem with exit codes and shell pipeline. My problem is that the current process requires a lot of manual intervention from me, including editing the source codes.
[ambrus]: (Also a lot of manual intervention by two or three other co-workers, who do other parts of the process.)
[ambrus]: Some of the manual part is unavoidable, but not all.
[choroba]: LanX was there a way to recover the numbers from the remaining information?
[Corion]: LanX: Ow ;)

How do I use this? | Other CB clients
Other Users?
Others wandering the Monastery: (12)
As of 2017-03-29 11:55 GMT
Find Nodes?
    Voting Booth?
    Should Pluto Get Its Planethood Back?

    Results (350 votes). Check out past polls.