Posted on April 8, 2015 4:28 pm
 |  Asked by Rich Wellner
Print Friendly, PDF & Email

My quest is simple. I can get all kinds of things to work from pyeapi, but I need to be able to manage acls and I can’t get even something simple like “show ip access-list” to work.

I’ve tried a bunch of variations:

node.run_commands([‘enable’,’show ip access-list’])

node.run_commands([‘enable’, ‘configure’, ‘show ip access-list’])

node.enable([‘show ip access-list’])

node.config([‘show ip access-list’])

All result in something like:

pyeapi.eapilib.CommandError: CLI command 3 of 3 ‘show ip access-list’ failed: invalid command

Anyone know the correct way to do this?

Posted by Andrei Dvornic
Answered on April 8, 2015 4:30 pm

The correct command is ”show ip access-lists”. Abbreviations are not supported in eAPI, for forward compatibility reasons (they might become ambiguous).

I hope this helps!

Posted by Rich Wellner
Answered on April 8, 2015 5:28 pm

Oh good lord. What’s the emoticon for being an idiot? ;-)


Thanks much for the quick response.¬†node.enable([’show ip access-lists’]) works perfectly.

Post your Answer

You must be logged in to post an answer.