panxapi -C fails with error on PanOS 4.1

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

panxapi -C fails with error on PanOS 4.1

L1 Bithead

panxapi -C used to work for me. Now that I've upgraded to 4.1 I get

commit: File does not exist: Illegal value for parameter "action" [commit]. Should be one of : [clone, complete, delete, edit, get, rename, set, show]. at /usr/lib/perl5/site_perl/5.8.8/PAN/XAPI.pm line 230

Can anyone point me to a solution?

9 REPLIES 9

L4 Transporter

which panxapi build  are you using ? I just did a small test and it looks fine in my environment.

 

 

 

ksomu@ksomu-VirtualBox:~/pan/PAN-perl-20111226/bin$ panxapi -l admin:admin -h 10.2.133.15 -CD
commit: success: Commit job enqueued with jobid 78

 

admin@PA-5060-1> show jobs id 78

Enqueued                     ID             Type    Status Result Completed
--------------------------------------------------------------------------
2012/01/17 15:27:35          78           Commit       FIN     OK 15:28:00

 

Configuration committed successfully

 

I am using the latest perl package built on dec 26th of 2011.  panos version is 4.1.1

 

thanks,
krishna Somu

I'm using 4.1.3 and PAN-perl-20111226.tgz and getting a similar result...

/usr/local/bin/panxapi -h 192.168.x.x -K asdfasdfasdasdfasdasdf -CD

.

.

.

$VAR1 = {
  action => 'commit',
  type => 'config',
  key => 'asdfasdfasdfasdfasdfasdfasdf'
};

API response:
<response status = 'error' code = '400'><result><msg>Illegal value for parameter &quot;action&quot; [commit]. Should be one of : [clone, complete, delete, edit, get, rename, set, show].</msg></result></response>$VAR1 = {
  status => 'error',
  result => {
    msg => 'Illegal value for parameter "action" [commit]. Should be one of : [clone, complete, delete, edit, get, rename, set, show].'
  },
  code => '400'
};
commit: Illegal value for parameter "action" [commit]. Should be one of : [clone, complete, delete, edit, get, rename, set, show]. status="error" code="400"

Can someone help?

on 4.1.3 use: panxapi -C "<commit></commit>"

Like what you see?

Show your appreciation!

Click Like if a post is helpful to you or if you just want to show your support.

Click Accept as Solution to acknowledge that the answer to your question has been provided.

The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!

These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!

The LIVEcommunity thanks you for your participation!