Asterisk 12 and Perl AGI script not working

If you have the right permissions and everything that script should have returned (with agi set debug on )
.
.
[2015/07/02 10:45:47] <DAHDI/i1/1234-a>AGI Tx >>
[2015/07/02 10:45:47] <DAHDI/i1/1234-a>AGI Rx << NOOP ------------------------- CHKRT AGI Called - DNID = 1234556678897
[2015/07/02 10:45:47] <DAHDI/i1/1234-a>AGI Tx >> 200 result=0
.

Check your permissions and any inadvertent stdout/stdin redirection you might have, AGI uses those devices to communicate with Asterisk.

IWFM

rasterisk -V
Asterisk 11.17.1

but the script per se does nothing but return the NOOP on stdout, is that all you want?

If you want to check your stdout at a perl level add

print “Some identifiable gibberish\n”;

to your script and you should see it in the cli.

(I also suggest you DON’T use Asterisk 12 as it only gets security fixes, I would use 11 as 13 is as yet not completely stable with FreePBX)

[edit]

relooking at your post you are calling the script wrong, it should be:-

agi(script,arg1,arg2. . .)

you are redirecting STDOUT by inappropriately “”""“quoting”"""" the call , google can expose your error, but the answer will be a little esoteric :slight_smile:

(How’s that for mindreading ? )