Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding support for loop-telecom devices #14674

Merged
merged 38 commits into from Jan 2, 2023
Merged

Adding support for loop-telecom devices #14674

merged 38 commits into from Jan 2, 2023

Conversation

ghost
Copy link

@ghost ghost commented Nov 24, 2022

Adding support for telecom products from Loop-Telecom.

Hardware setup:

  • AM3440-CCPB-A with 3 ethernet ports (SNMP, ETH 1 & ETH 2
  • 2x 150W-dc psu
  • 10x fxs cards
  • 1x CLKa card

What's working

  • Initial os detection
  • Reading current power draw
  • Detecting Ethernet ports (speed, mode (half/full duplex), packets in, out and errors)
  • Read chassi temprature
  • Status for all line cards insert.
  • Status for PSUs
  • Console, telnet & ssh access status
  • Misc voltage & current draw

What's not working

  • Collecting packet count and graphing port traffic (think I'm collecting the data correctly. Do i have to I have to define that I want to create graphs for each port?)
  • States for PSU and line cards stops working after the poller run for the first time. If I delete and add the device again the states are working again. Looks the the {{$index}} for the linecars num_oid reports the slot name insted of slot number. Not sure if i can fix this in the yaml file or if I have to do the integration with php instead.
  • Hardware name includes the name of the mib ( L-AM3440-A-Private::loop-AM3440-CCPB-A. should be just "loop-AM3440-CCPB-A")
  • Problems saving test data

DO NOT DELETE THE UNDERLYING TEXT

Please note

Please read this information carefully. You can run ./lnms dev:check to check your code before submitting.

  • Have you followed our code guidelines?
  • If my Pull Request does some changes/fixes/enhancements in the WebUI, I have inserted a screenshot of it.
  • If my Pull Request makes discovery/polling/yaml changes, I have added/updated test data.

Testers

If you would like to test this pull request then please run: ./scripts/github-apply <pr_id>, i.e ./scripts/github-apply 5926
After you are done testing, you can remove the changes with ./scripts/github-remove. If there are schema changes, you can ask on discord how to revert.

@CLAassistant
Copy link

CLAassistant commented Nov 24, 2022

CLA assistant check
All committers have signed the CLA.

@Jellyfrog
Copy link
Member

Mark it as a draft pr instead

@Jellyfrog Jellyfrog marked this pull request as draft November 24, 2022 16:35
@Jellyfrog Jellyfrog changed the title Draft! Adding support for loop-telecom devices Adding support for loop-telecom devices Nov 24, 2022
@Jellyfrog Jellyfrog added the Device 🖥️ New or added device support label Nov 24, 2022
@@ -0,0 +1,13 @@
<?php
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi,
You can probably do it in YAML and provide snmp_hexstring as user-func.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you provide me with an example on how to do this?
I could not find this anywhere in the documentation.

Thank you!

@PipoCanaja
Copy link
Contributor

Hi
Please rename the mibfile to L-AM3440-A-Private as this is the official MIB definition.
Thanx

@ghost
Copy link
Author

ghost commented Nov 28, 2022

@Jellyfrog any idea why the save-test-data.php fails ?

mib: L-AM3440-A-Private
modules:
os:
hardware: SNMPv2-MIB::sysObjectID.0
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Delete this line and set hardware_mib: L-AM3440-A-Private instead.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

break;
}
//Set port mode
switch ($port['ethernetStatusMode']) {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

These are not valid ifType values. See IANAifType-MIB

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has now been replaced by setting the ports to ethernetCsmacd. Is there any way to specify physical port type?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That would probably be in inventory (usually supplied by ENTITY-MIB)

@murrant
Copy link
Member

murrant commented Dec 15, 2022

FYI, I merged #14699 which will handle whitespace in front of the number.

@ghost ghost marked this pull request as ready for review December 16, 2022 13:09
@ghost ghost requested review from murrant and PipoCanaja and removed request for murrant December 19, 2022 08:37
@ghost
Copy link
Author

ghost commented Dec 27, 2022

@murrant @PipoCanaja any thing else needed to merge the pull request?

@Jellyfrog Jellyfrog added the Needs Tests 🦄 https://docs.librenms.org/Developing/os/Test-Units/ label Jan 2, 2023
@Jellyfrog
Copy link
Member

Missing json test data

@github-actions
Copy link

github-actions bot commented Jan 2, 2023

Please add test data so we can ensure your change is not broken in the future.
Read the docs to find out how: https://docs.librenms.org/Developing/os/Test-Units

@ghost
Copy link
Author

ghost commented Jan 2, 2023

Missing json test data

Json test data has now been added :)

@Jellyfrog Jellyfrog removed the Needs Tests 🦄 https://docs.librenms.org/Developing/os/Test-Units/ label Jan 2, 2023
@Jellyfrog
Copy link
Member

There is no other name for the operating system? (librenms works with OSes rather than vendors)

@ghost
Copy link
Author

ghost commented Jan 2, 2023

There is no other name for the operating system? (librenms works with OSes rather than vendors)

Unfortunately not. I have not found any mentioning of the OS name anywhere in the device or other devices I have used from the same vendor the last 5 years. Therefor I assume they use the same OS on all devices.

@Jellyfrog Jellyfrog merged commit cf3f69e into librenms:master Jan 2, 2023
@Jellyfrog
Copy link
Member

Good job here!

@librenms-bot
Copy link

This pull request has been mentioned on LibreNMS Community. There might be relevant details there:

https://community.librenms.org/t/23-1-0-changelog/20671/1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Device 🖥️ New or added device support
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants