Send netdisco-users mailing list submissions to
        netdisco-users@lists.sourceforge.net

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.sourceforge.net/lists/listinfo/netdisco-users
or, via email, send a message with subject or body 'help' to
        netdisco-users-requ...@lists.sourceforge.net

You can reach the person managing the list at
        netdisco-users-ow...@lists.sourceforge.net

When replying, please edit your Subject line so it is more specific
than "Re: Contents of netdisco-users digest..."
Today's Topics:

   1. Re: Errors after upgrading to 2.033006 (Soppe, Peter)
   2. Change of snmp credentials (o...@leferguson.com)
   3. Re: Special Report needed aka "IP-Inventory with extra
      columns" (Sebastian R?sch)
   4. Re: Special Report needed aka "IP-Inventory with  extra
      columns" (Sebastian R?sch)
--- Begin Message ---
Hello Oliver,

thanks for your help. The space was missing. I added the space to the config, 
restarted the services and everything works as expected.

Regards,
  Peter


Peter Soppe
Leiter Technik

ICSmedia GmbH
Soester Strasse 13
D - 48155 Muenster

t:   +49 251 6060-416
f:   +49 251 6060-190
m:   +49 151 16786000

     p...@icsmedia.de
     www.icsmedia.de


Geschaeftsfuehrer: Ulrich Moeller, Kai Mallmann
Amtsgericht Muenster HRB 4697 - USt-IdNr. DE179964809


-----Original Message-----
From: Oliver Gorwits [mailto:oli...@cpan.org]
Sent: Monday, July 18, 2016 3:34 PM
To: netdisco-users@lists.sourceforge.net
Subject: Re: [Netdisco] Errors after upgrading to 2.033006

Peter,

Sorry if we asked this before... are there some space characters in the
config before the name/user/pass statements? such as:

database:
   name:
   user:
   pass:

The spaces must be there so the config item is read as a dictionary
(hash).

regards,
oliver.




--- End Message ---
--- Begin Message ---
I finally tracked down what was causing some strange results, and not sure if 
there is a better way to solve this.  And/or if it might merit consideration in 
the product.

Some systems (net-snmp for example) come by default with a limited view of snmp 
under "public".

Some systems are stuck on "public" because you may not be able to get a client 
to change them, or their admins forgot how.

This led me to a problem.  I had a couple of linux systems which had not been 
changed to our normal snmp community string.  When Netdisco saw them it tried 
that and failed, then tried public and worked.  A bit.  No ports for example.

So I noticed, and fixed the servers to the right snmp community string.

And waited... no change.  So discovered them again - no change.  Hmmm...  Maybe 
(thinks I) it remembers, so I deleted the host and rediscovered.  No change.

I finally found there is a "community" table that stashes an IP and the 
community tags that last worked.  It does not appear to go away even if you 
delete that host (well, to be fair it's indexed by IP and only indirectly then 
tied to the host).  When I truncated that, it obviously had to start over.

Is there a "proper" way to make it start over?

Yes, I know I can limit "public" to specific devices, but actually I like that 
it tries that on any new items, as often it provides useful information to 
identify and fix them.

Should deleting a host perhaps clear out any IP's in the community table that 
have been associated with that device?

Was there a better approach?

Linwood


--- End Message ---
--- Begin Message ---
Hello Andy,

I didn´t know that such a type exists. Thanks for that info!

Regards
Sebastian


-----Ursprüngliche Nachricht-----
Von: Andy Ruhl [mailto:acr...@gmail.com] 
Gesendet: Mittwoch, 13. Juli 2016 19:21
An: Sebastian Rösch <roe...@alcera.de>
Cc: netdisco-users@lists.sourceforge.net
Betreff: Re: [Netdisco] Special Report needed aka "IP-Inventory with extra 
columns"

On Wed, Jul 13, 2016 at 10:14 AM, Andy Ruhl <acr...@gmail.com> wrote:
> On Wed, Jul 13, 2016 at 7:03 AM, Sebastian Rösch <roe...@alcera.de> wrote:
>> As I was not able to get the query working in the webinterface I 
>> tried to execute a query in the shell…. I was trying to combine the 
>> following select statement with a join. So I started with executing 
>> them for their own. But the select doesn´t work, the join statement 
>> works, but I would like to limit the output of it to nodes from a 
>> specific subnet…. I thought this could be done in a way like described here:
>> http://stackoverflow.com/questions/12970187/nested-select-statement-w
>> ith-left-join
>>
>>
>>
>>
>>
>> bin/netdisco-do psql -e "COPY (SELECT * FROM node_ip WHERE node_ip.ip 
>> LIKE
>> '%10.200.%') TO STDOUT WITH CSV HEADER"
>>
>>
>>
>> bin/netdisco-do psql -e "COPY (SELECT * FROM node INNER JOIN node_ip 
>> ON node.mac = node_ip.mac) TO STDOUT WITH CSV HEADER"
>
> The postgres way to limit a search to a subnet given that the column 
> is of a type of "net address", is something like this:
>
> ip<<'10.200.0.0/16'

I did a little more homework after I replied and the ip column in node_ip is in 
fact of type "inet", so you can use CIDR notation for a subnet range. The << 
means "contained within".

Andy

--- End Message ---
--- Begin Message ---
Hello Oliver,

In my posting I only posted a part of the sql query or that what I want to 
achieve. What I need is to get a list of all devices from a subnet, including 
the device and port, the are connected to.

My query is very basic and also doesn´t filter for the last seen device on that 
port, so I get multiple results per node with different timestamps... I think 
it should be possible to filter for the most current entry/timestamp, but I 
assume, that it is much more easy to use netdisco internal db views... But I´m 
not familiar with all that, so it is not easy for me to to use this features, 
I´m familiar with some basics in sql language...

bin/netdisco-do psql -e "COPY (SELECT 
node.mac,node.switch,node.port,node.time_first,node.time_last,node_ip.ip,node_ip.dns
 FROM node INNER JOIN node_ip ON node.mac = node_ip.mac Limit 1) TO STDOUT WITH 
CSV HEADER"



Maybe you can understand it better, If you know the background: Customer want´s 
to move devices from a specific network to a new vlan. So because the customer 
doesn´t know the switchports, where the devices are connected, I have to 
identify them, it is a whole /24 subnet. Now in netdisco I have no view, where 
I can see that at once in a big picture. What I would need is a combination of 
the IP-Inventory (I get all the used Nodes from a subnet (MAC + IP Adresses) 
and the Node View (I get the device and port where a device is connected). That 
would be awesome....


Best Regards
Sebastian

-----Ursprüngliche Nachricht-----
Von: Oliver Gorwits [mailto:oli...@cpan.org] 
Gesendet: Montag, 18. Juli 2016 15:27
An: netdisco-users@lists.sourceforge.net
Betreff: Re: [Netdisco] Special Report needed aka "IP-Inventory with extra 
columns"

Hi Sebastian,

Andy has replied about using the << operator in the SQL to limit within an IP 
prefix.

I'd like to add a couple of points, sorry if they're not particularly helpful...

1. the IP inventory query is documented in the code although it's not 
particularly straightforward: 
https://metacpan.org/source/OLIVER/App-Netdisco-2.033006/lib/App/Netdisco/Web/Plugin/Report/IpInventory.pm#

2. You don't really ever get a device/port for an IP because IP data comes from 
ARP tables on routers, and it's the MAC address which is on a port. The IP 
could appear in multiple locations quite legitimately (different VLANs for 
instance).

It depends what you want to achieve and for what purpose. Of course the IPs are 
listed on the Ports tab of the Device view, if you're happy to see the data per 
device rather than per IP subnet.

regards,
oliver.

On 2016-07-13 15:03, Sebastian Rösch wrote:
> Hi all,
> 
> I´ve got a little problem….I need a report from netdisco, which is not 
> available so far. If the "Ip Inventory" Report would be extend for the 
> columns device and port, that would exactly meet my requirements very 
> well. But I don´t know how to do that….
> 
> As I was not able to get the query working in the webinterface I tried 
> to execute a query in the shell…. I was trying to combine the 
> following select statement with a join. So I started with executing 
> them for their own. But the select doesn´t work, the join statement 
> works, but I would like to limit the output of it to nodes from a 
> specific subnet…. I thought this could be done in a way like described 
> here:
> http://stackoverflow.com/questions/12970187/nested-select-statement-wi
> th-left-join
> 
> 
> bin/netdisco-do psql -e "COPY (SELECT * FROM node_ip WHERE node_ip.ip 
> LIKE '%10.200.%') TO STDOUT WITH CSV HEADER"
> 
> bin/netdisco-do psql -e "COPY (SELECT * FROM node INNER JOIN node_ip 
> ON node.mac = node_ip.mac) TO STDOUT WITH CSV HEADER"
> 
> Any ideas how I can get this working? Of course I would prefer to get 
> it running as a report or the best way would be to modify the IP 
> Inventory tool….
> 
> Regards,
> 
> Sebastian
> ----------------------------------------------------------------------
> -------- What NetFlow Analyzer can do for you? Monitors network 
> bandwidth and traffic patterns at an interface-level. Reveals which 
> users, apps, and protocols are consuming the most bandwidth. Provides 
> multi-vendor support for NetFlow, J-Flow, sFlow and other flows. Make 
> informed decisions using capacity planning 
> reports.http://sdm.link/zohodev2dev
> 
> _______________________________________________
> Netdisco mailing list
> netdisco-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/netdisco-users



--- End Message ---
------------------------------------------------------------------------------
_______________________________________________
Netdisco mailing list - Digest Mode
netdisco-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/netdisco-users

Reply via email to