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

init error #1

Closed
loganbest opened this issue Jul 7, 2015 · 5 comments
Closed

init error #1

loganbest opened this issue Jul 7, 2015 · 5 comments

Comments

@loganbest
Copy link

I'm running Python 2.7.10.

 $ ./mnet-graph.py -r x.x.x.x -f gscnetwork.svg -d 10 -c ./mnet.conf
MNet-Graph v0.1
Written by Michael Laforest <mjlaforest@gmail.com>

Config file: ./mnet.conf
  Root node: x.x.x.x
Output file: gscnetwork.svg
Crawl depth: 10
Diagram title: MNet Network Diagram

Traceback (most recent call last):
  File "./mnet-graph.py", line 666, in <module>
    main(sys.argv[1:])
  File "./mnet-graph.py", line 487, in main
    crawl_node(opt_root_ip, opt_depth)
  File "./mnet-graph.py", line 256, in crawl_node
    system_name = shorten_host_name(get_snmp_val(ip, OID_SYSNAME) or 'UNKNOWN')
  File "./mnet-graph.py", line 109, in get_snmp_val
    cmdgen.CommunityData(community),
TypeError: __init__() takes at least 3 arguments (2 given)
@MJL85
Copy link
Owner

MJL85 commented Jul 7, 2015

What version of PySNMP are you using? I believe you can check it with the below. I've tested it with 4.2.5.

michael# python2
Python 2.7.8 (default, Dec  4 2014, 15:36:21)
[GCC 4.2.1 Compatible FreeBSD Clang 3.4.1 (tags/RELEASE_34/dot1-final 208032)] on freebsd10
Type "help", "copyright", "credits" or "license" for more information.
>>> import pysnmp
>>> print pysnmp.__version__
4.2.5
>>> quit()

@loganbest
Copy link
Author

4.2.1

@loganbest
Copy link
Author

Any luck with this?

NINJA EDIT: This is particularly erroring on OSX 10.7.5, but I get the same on 10.10 as well

@liftedkilt
Copy link

Just for kicks - did you update to the new version of the script? You'll
need to install netaddr for python as well (easy_install netaddr)

On Wed, Jul 8, 2015, 11:01 PM Logan Best notifications@github.com wrote:

Any luck with this?


Reply to this email directly or view it on GitHub
#1 (comment).

@MJL85
Copy link
Owner

MJL85 commented Jul 18, 2015

Added package to pip which should hopefully fix this issue. If it doesn't please open a new ticket. Closing because there have been so many revisions in the past week I doubt this is still relevant.

@MJL85 MJL85 closed this as completed Jul 18, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants