[asterisk-users] System() command refuses to execute bash script

Stefan Viljoen viljoens at verishare.co.za
Mon Mar 2 08:27:07 CST 2015

Hi All

I'm using this extension to  try and get Asterisk to run a bash

exten=>802,n,System(/bin/sh -f /root/wireless.sh)

This file is

-rwxr-xr-x  1 root root   171 Mar  2 16:23 wireless.sh

e.g. root owns the file, and it has execute permissions for all users.

Asterisk runs as root as well.

Asterisk executes the command without any errors at max verbosity.

The file wireless.sh contains:

touch wireless-executed

In my /root folder however, the file


is never written - indicating the script does not execute, even though it is
owner by the same user asterisk runs as, and is world-executable.

How can I use System to run a bash script?




More information about the asterisk-users mailing list