question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

RPM Probes and data collection via SSH / netconf

See original GitHub issue

Hi

Seems to be failing to scrape any data from the vMX router regarding RPM probes.

Can see messages in the logs that opennti is connecting on port 22 then nothing is happening, as a result the python script is seeing no returned data from the initial “show version”

Aug  2 09:57:02   inetd[7754]: /usr/sbin/sshd[84038]: exited, status 255
Aug  2 09:57:02   sshd[84039]: Accepted password for jon from 10.55.89.10 port 42306 ssh2
Aug  2 09:58:02   sshd[84403]: Did not receive identification string from 10.55.89.10
root@opennti-vm:/home/jon/open-nti# make cron-debug
docker exec -i -t opennti_con /usr/bin/python /opt/open-nti/open-nti.py -s -c
Importing credentials file: /opt/open-nti/data/credentials.yaml 
Importing host file: /opt/open-nti/data/hosts.yaml 
Importing commands file: /opt/open-nti/data/commands.yaml 
Importing junos parsers file: ['show-route-summary.parser.yaml', 'file-list-detail-var-rundb-juniper.eph_iceaaa.parser.yaml', 'show-firewall.parser.yaml', 'show-task-memory.parser.yaml', 'show-services-l2tp-summary.parser.yaml', 'show-bgp-summary.parser.yaml', 'show-route-summary.table.bgp.l3vpn.0.parser.yaml', 'show-pfe-statistics-traffic.parser.yaml', 'show-chassis-routing-engine.parser.yaml', 'show-network-access-aaa-radius-servers-detail.parser.yaml', 'show-mpls-lsp.parser.yaml', 'show-route-summary.table.inet.0.parser.yaml', 'show-route-summary.table.l2circuit.0.parser.yaml', 'show-isis-statistics.parser.yaml', 'show-services-stateful-firewall-flow-analysis.parser.yaml', 'show-snmp-get-jnxOperatingCPU-RE.yaml', 'show-krt-state.parser.yaml', 'show-chassis-fpc.parser.yaml', 'show-subscribers-summary.parser.yaml', 'show-system-configuration-database-usage.parser.yaml', 'show-snmp-statistics.parser.yaml', 'show-interfaces-media.parser.yaml', 'show-route-summary.table.inet.3.parser.yaml', 'show-ldp-traffic-statistics.parser.yaml', 'show-services-rpm-probe-results.parser.yaml', 'show-snmp-get-jnxOperatingCPU-FPC.yaml', 'show-system-buffers.parser.yaml', 'show-system-core-dumps.parser.yaml', 'show-task-io.parser.yaml', 'show-pppoe-statistics.parser.yaml', 'show-version.parser.yaml', 'show-system-storage.parser.yaml', 'show-services-nat-pool-detail.parser.yaml', 'show-security-ipsec-statistics.parser.yaml', 'show-system-virtual-memory.parser.yaml', 'show-lwaftr-statistics.parser.yaml', 'show-services-stateful-firewall-subscriber-analysis.parser.yaml', 'show-route-summary.table.inet6.0.parser.yaml', 'show-system-resource-monitor-summary.parser.yaml', 'show-bfd-session-summary.parser.yaml', 'show-subscribers-summary-port.parser.yaml', 'show-policer-default-arp-policer.parser.yaml', 'show-l2-learning-global-mac-count.parser.yaml', 'show-services-video-monitoring-mdi-flow-fpc-slot-1.parser.yaml', 'show-system-statistics-icmp.parser.yaml', 'show-task-accounting.parser.yaml', 'show-lwaftr-state.parser.yaml', 'show-ddos-protection-protocols-statistics-terse.parser.yaml', 'show-system-processes-extensive.parser.yaml', 'show-bgp-neighbor-10.255.0.206.parser.yaml', 'show-igmp-snooping-statistics.parser.yaml', 'show-network-access-aaa-statistics-address-assignment-pool.parser.yaml', 'rtsockmon.parser.yaml'] 
Importing pfe parsers file: ['.gitignore'] 
Getting hosts that matches the specified tags
The following hosts are being selected:  ['10.100.103.100']
Collector Thread-1 scheduled with following hosts: ['10.100.103.100']
Connecting to host: 10.100.103.100
[10.100.103.100]: Executing command: show version | display xml
[10.100.103.100]: Parsing command: show version | display xml
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib/python2.7/threading.py", line 801, in __bootstrap_inner
    self.run()
  File "/usr/lib/python2.7/threading.py", line 754, in run
    self.__target(*self.__args, **self.__kwargs)
  File "/opt/open-nti/open-nti.py", line 573, in collector
    hostname_tmp = xml_data.xpath(hostname_xpth)[0].text.strip()
AttributeError: 'NoneType' object has no attribute 'strip'

image

Any ideas why its not seemingly logging in and running the commands properly?

Cheers! Jon.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
3fr61ncommented, Aug 3, 2018

The strip function with ‘null’ string

Sent from my iPhone

On 3 Aug 2018, at 11:02, Jon Clayton notifications@github.com wrote:

working now but I’ve rebuilt everything so not sure what the fix was. 😦

Could very well been the lack of hostname.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub, or mute the thread.

1reaction
3fr61ncommented, Aug 3, 2018

Hi, Just to test… could you please add a hostname to the vmx? regards

Read more comments on GitHub >

github_iconTop Results From Across the Web

Connect to the NETCONF Server Using SSH | Junos OS
It uses SSH library routines to establish an SSH connection to the NETCONF server, provide the username and password or passphrase, and create...
Read more >
System Monitoring Configuration Guide for Cisco 8000 Series ...
Collect and export PM statistics to a TFTP server for data storage and ... Enable NETCONF, SSH and configure the management interface.
Read more >
Monitoring Juniper RPM data with InfluxDB and Graphana
Now, this is really the data-gathering portion (subset-of) of what ... Let's implement a couple of very simple RPM probes on our branch...
Read more >
Network Automation - Salt Project Documentation
Most network devices can be managed via Salt Proxy Minions using Salt SSH. ... Retrieve the results of the RPM probes configured on...
Read more >
NetworkDriver — NAPALM 3 documentation
Returns a dictionary with the probes configured on the device. Probes can be either RPM on JunOS devices, either SLA on IOS-XR. Other...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found