Sponsored Content
Full Discussion: Accept SNMP Packets...
Special Forums UNIX and Linux Applications Infrastructure Monitoring Accept SNMP Packets... Post 302471240 by karlochacon on Friday 12th of November 2010 10:15:04 AM
Old 11-12-2010
any idea

any idea guys?

I was thinking maybe using hosts.allow/deny

but I am not sure how to use it

hosts.allow
snmpd: 192.168.1.2 192.168.1.3

basically I want any kind of connection to my server but SNMP only 6 servers

how should I ply with hosts.deny/allow or SNMP to do this?
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

sending packets

How can i send a packet, and what is an empty packet? (8 Replies)
Discussion started by: Avatar0fEvil
8 Replies

2. Programming

Packets Getting Lost

I am working on a project, which has the following type of hardware setup. A special hardware device is receiving data from an external network interface. So we can have multiple such a hardware devices. Now these hardware devices will route the captured incoming data through the external... (4 Replies)
Discussion started by: S.P.Prasad
4 Replies

3. IP Networking

counting the packets

there are a number of clients connected to a server.... how can i count that each clients recieve ...? how do i moniter the activity of the client..? (2 Replies)
Discussion started by: damn_bkb
2 Replies

4. Infrastructure Monitoring

capture snmp packets in AIX

Hi, I want to capture snmp packets in AIX. When i give print from AIX6.1, Printer will give its response thru' snmp. I used iptrace command like below, but it is not capturing snmp packets other packets are captured like udp, tcp.. 1. iptrace command: /usr/sbin/iptrace -a -i en0... (1 Reply)
Discussion started by: meeraramanathan
1 Replies

5. HP-UX

packets statistics

Hi there, are there any functions that can get the packets statistics on UNIX ? thanks. (2 Replies)
Discussion started by: Frank2004
2 Replies

6. IP Networking

Sending data from DELL OMSA SNMP and Custom SNMP MIB to same UDP port 161

Hi , Currently DELL OMSA SNMP sends data through default udp port 161.I want my custom SNMP MIB also to send data in the same udp port 161.Whether its possible.If yes where to configure .I tried starting my custom MIB in udp port 161,but it throws port already in use.Kindly guide. (0 Replies)
Discussion started by: prabakar4all
0 Replies

7. Red Hat

Sending data from DELL OMSA SNMP and Custom SNMP MIB to same UDP port 161

Hi , Currently DELL OMSA SNMP sends data through default udp port 161.I want my custom SNMP MIB also to send data in the same udp port 161.Whether its possible.If yes where to configure .I tried starting my custom MIB in udp port 161,but it throws port already in use.Kindly guide. (1 Reply)
Discussion started by: prabakar4all
1 Replies

8. IP Networking

SNMP Problem - SNMP not getting to the agent.

I am having a problem with an SNMP event, and I am not sure where I should be looking to solve this problem. Description: There is an SNMP event in our system that for one reason or another is not getting sent out as an email because it is never getting to our SNMP agent. I see where the... (0 Replies)
Discussion started by: broberts
0 Replies

9. Infrastructure Monitoring

SNMP traps to SNMP server

Dear Champs, I am new to unix, and need to configure linux server to send below traps to a SNMP server. Monitoring TRAP Disk Space Low Monitoring TRAP Memory Low Monitoring TRAP CPU high Monitoring TRAP Admin login/Logoff Please help me how to send this information to my SNMP server... (2 Replies)
Discussion started by: stavar
2 Replies

10. UNIX for Dummies Questions & Answers

Need to transfer all kernel logs (var/log/messages) to the snmp listener as snmp trap

i am working with embedded system -Dell DCS management sub system. my question is as below: currently we are using linux kernel 2.6.30 build and we have a kernel logs stored to the /var/log/messages path. now we have to transfer all this logs to the specified SNMP target as a part of SNMP... (4 Replies)
Discussion started by: vipul_prajapati
4 Replies
XML::Smart::FAQ(3pm)					User Contributed Perl Documentation				      XML::Smart::FAQ(3pm)

NAME
XML::Smart::FAQ - Frequently Asked Questions about XML::Smart. SYNOPSIS
This is the Frequently Asked Questions list for XML::Smart. QUESTIONS
For new questions send an e-mail to the author, but please, read first all the F.A.Q. Do I need to install XML::Parser to can use XML::Smart? No! XML::Smart already comes with 2 independent parsers, XML::Smart::Parser and XML::Smart::HTMLParser. If XML::Parser is found XML::Smart will use it by default, and the 2nd options will be XML::Smart::Parser. Note that for complex parsing XML::Parser is recommended, but XML::Smart::Parser will work fine too. What is the best version of XML::Smart to install? Is always the last! Always take a look for new versions before aks for help on XML::Smart. Note that internally XML::Smart is complex, since the main idea of it is to remove the complexity from the hand of the programmer. Actually the idea is to enable the Perl programmer to use and create XML data without really know the XML format. Where can I learn about XML? http://www.xml.com How to apply a DTD to a XML::Smart object tree? Take a look in the method apply_dtd(). Example of use: $xml->apply_dtd(q` <!DOCTYPE cds [ <!ELEMENT cds (album+)> <!ATTLIST cds creator CDATA date CDATA #REQUIRED > <!ELEMENT album (artist , tracks+)> <!ELEMENT artist (#PCDATA)> <!ELEMENT tracks (#PCDATA)> ]> `); This will format automatically elements, attributes, etc... How XML::Smart works? To create XML::Smart, first I have created the module Object::MultiType. With it you can have an object that works at the same time as a HASH, ARRAY, SCALAR, CODE & GLOB. So you can do things like this with the same object: $obj = Object::MultiType->new() ; $obj->{key} ; $obj->[0] ; $obj->method ; @l = @{$obj} ; %h = %{$obj} ; &$obj(args) ; print $obj "send data " ; Seems to be crazy, and can be more if you use tie() inside it, and this is what XML::Smart does. For XML::Smart, the access in the Hash and Array way paste through tie(). In other words, you have a tied HASH and tied ARRAY inside it. This tied Hash and Array work together, soo you can access a Hash key as the index 0 of an Array, or access an index 0 as the Hash key: %hash = ( key => ['a','b','c'] ) ; $hash->{key} ## return $hash{key}[0] $hash->{key}[0] ## return $hash{key}[0] $hash->{key}[1] ## return $hash{key}[1] ## Inverse: %hash = ( key => 'a' ) ; $hash->{key} ## return $hash{key} $hash->{key}[0] ## return $hash{key} $hash->{key}[1] ## return undef The best thing of this new resource is to avoid wrong access to the data and warnings when you try to access a Hash having an Array (and the inverse). Thing that generally make the script die(). Once having an easy access to the data, you can use the same resource to create data! For example: ## Previous data: <hosts> <server address="192.168.2.100" os="linux" type="conectiva" version="9.0"/> </hosts> ## Now you have {address} as a normal key with a string inside: $XML->{hosts}{server}{address} ## And to add a new address, the key {address} need to be an ARRAY ref! ## So, XML::Smart make the convertion: ;-P $XML->{hosts}{server}{address}[1] = '192.168.2.101' ; ## Adding to a list that you don't know the size: push(@{$XML->{hosts}{server}{address}} , '192.168.2.102') ; ## The data now: <hosts> <server os="linux" type="conectiva" version="9.0"/> <address>192.168.2.100</address> <address>192.168.2.101</address> <address>192.168.2.102</address> </server> </hosts> Than after changing your XML tree using the Hash and Array resources you just get the data remade (through the Hash tree inside the object): my $xmldata = $XML->data ; But note that XML::Smart always return an object! Even when you get a final key. So this actually returns another object, pointhing (inside it) to the key: $addr = $XML->{hosts}{server}{address}[0] ; ## Since $addr is an object you can TRY to access more data: $addr->{foo}{bar} ; ## This doens't make warnings! just return UNDEF. ## But you can use it like a normal SCALAR too: print "$addr " ; $addr .= ':80' ; ## After this $addr isn't an object any more, just a SCALAR! When I generate the XML data new lines ( ) are added to the content! You should use the options for the method data() and save() to not add identation to the generated data: $XML->data( noident => 1 ) ; ## or better: $XML->data( nospace => 1 ) ; Your question is not here? Just send me an e-mail. ;-P AUTHOR
Graciliano M. P. <gm@virtuasites.com.br> I will appreciate any type of feedback (include your opinions and/or suggestions). ;-P Enjoy and thanks for who are enjoying this tool and have sent e-mails! ;-P ePod This document was written in ePod (easy-POD), than converted to POD, and from here you know the way. perl v5.10.1 2004-12-08 XML::Smart::FAQ(3pm)
All times are GMT -4. The time now is 12:43 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy