Menu

Scraper for HP/H3C Comware

2014-06-24
2014-07-23
  • Christian Wendell Gueco

    Hello Jonathan!

    Before anything else this software really is awesome I might say. I does really work. Thanks a lot.

    I would like to add/contribute this scraper for HP/H3C Comware network devices (different platfrom from HP and this is not Procurve). I would like to send this file (once I see the attach button) :)

    • Christian
     
  • Christian Wendell Gueco

    Here it is :)

     
  • Christian Wendell Gueco

    Btw, this scaper assumes the account has already administrative priveledge and no escalation is required. There some minor error logs but works well for ASeries and ESeries switches.

     
  • Jonathan Yantis

    Jonathan Yantis - 2014-06-24

    Christian,

    Hey I just want to say this is awesome as well, I've been waiting for someone to submit an H3C scraper and it's really good to see one. I'm glad you like the program over-all and I'm currently working on a 2.0 version that will allow the scrapers to remain logged in to all devices at all times which should dramatically improve performance. The scrapers themselves should only need minor changes if things go to plan.

    I've added your scraper to the SVN trunk and will backrev it to v1.12 here soon. I made a few documentation edits but that's about it. If you are subscribed to this thread, I may post back if I get any feedback from others or patches that you might want to retest in your environment.

    Thanks again and let me know if you come up with improvements or anything else. If you can, re-download the repository version and make any future edits to it. You can find it here:

    https://sourceforge.net/p/netdbtracking/code/HEAD/tree/trunk/netdbscraper/comwarescraper.pl

    Jonathan

     
    • Christian Wendell Gueco

      Hi Jonathan,

      Thanks for accepting this scraper into the new revision. I have made some minor modifications on this scraper. Kindly see attached.

      I was researching your code and noticed the "dobackup" argument scraper device options input. After some testing, I have revised this comwarescraper to use the dobackup option to get the H3C comware devices configuration (command: "display current-configuration"). There is a simple subroutine "getDeviceConfig()" which handles this. This saves it by default in the "$rootdir/data/config/<devicename>.cfg" but the option "-oc file" can be use on the command line.

      I have tested/ran it with around 30+ HP/H3C devices and have been retrieving the configurations so far (except when the link is congested).

      Let me know if this code is okay. I also used the same code for Cisco IOS and Juniper JUNOS for our network and so far works well (i.e. modified the scrapers).

      Best Regards,

      • christian

      Note: I use a little bash scripting with subversion to get me notified (via email) if there are any configuration changes. This is my alternative to RANCID :)

       
  • Jonathan Yantis

    Jonathan Yantis - 2014-07-23

    Christian,

    I've added this latest version to the trunk repository, thanks again. So the dobackup is part of some local functionality we have here that I have not generalized to the rest of the program, but I don't see any problem with adding this to the scraper. I may adopt this method for the rest of the scrapers, but I was hoping to expand this type of functionality in the 2.0 version. I'm struggling with scaling the scrapers to be always online and logged in though, so we'll see. I was hoping to eventually add vlan change and description change functionality as well.

    Overall, looks great to me. Thanks for contributing and I'll keep you posted if I expand the config backup functionality etc.

    Jonathan

     

Log in to post a comment.