#Passing params along with the query?

1 messages · Page 1 of 1 (latest)

warped apex
#

Hi all,

After upgrading to 23.05 and commenting out NetConnections metric, the DNS spam issue we were having went away. It was similar to https://github.com/NetApp/harvest/issues/1353#issuecomment-1479762245

However, the customer asked if instead of having to comment it out, could it not be fixed the following way:

"on the command/Harvest implementation, can any switches be added to stop the resolution of addresses or an RFE submitted to exclude resolution of 169/8 IPs? Seems to me like addition of -service !ctlopcp to network connections active show fixes the bulk, all but a handful, of DNS resolution failures"

Looking through the documentation, it looks like the ability to pass filters like that is not currently possible? If I had to guess, this was done on purpose?

Thanks in advance

GitHub

Describe the bug The harvest 22.08 seems to be making a huge number of queries to our internal DNS. In fact, the IP's checked mostly are those for the Vserver "Cluster", those IP'...

tame raven
#

@warped apex We are not sure as to which service is responsible for the DNS spam. Harvest has built-in support for Filters in Rest Templates. For instance, you can refer to the following example in our GitHub repo: https://github.com/NetApp/harvest/blob/main/conf/rest/9.12.0/volume_analytics.yaml#L9-L12

You can apply a similar approach to the netconnections template. Here's how you can do it

name:                         NetConnections
query:                        api/private/cli/network/connections/active
object:                       net_connection

counters:
  - ^^cid                        => cid
  - ^blocks_lb                   => blocks_lb
  - ^lif_name                    => lif
  - ^local_address               => local_address
  - ^local_port                  => local_port
  - ^lru                         => lru
  - ^node                        => node
  - ^proto                       => proto
  - ^remote_ip                   => remote_ip
#  - ^remote_host                 => remote_host  # ONTAP will try to resolve all ip addresses from every active connection
  - ^service                     => service      # see issue #1353
  - ^vserver                     => svm
  - filter:
      - service=!ctlopcp

export_options:
  instance_keys:
    - cid
  instance_labels:
    - blocks_lb
    - lif
    - local_address
    - local_port
    - lru
    - node
    - proto
    - remote_ip
    - service
    - svm
warped apex
#

Thanks, I could not find that anywhere on the docs site