Suggestion on 'hangup request' command
Posted: Wed Jun 18, 2014 3:28 am
HI,
Vicidial Configuration :
Vicidial VERSION: 2.7-401a BUILD: 130508-2256 (Scratch Install) | Asterisk : 1.8.21.0 | Two servers (Asterisk on both server,web interface on both servers,both servers use same database) | DAHDI: 2.7.0.1 | libpri : 1.4.14 | Allo E1 PRI CARD with 2 slots on both servers |No Extra Software After Installation|Intel(R) Xeon(R) CPU E31220 @ 3.10GHz 8 MB Cache| 8 GB RAM | Cent OS 6.4 | Linux version 2.6.32-358.0.1.el6.i686 (mockbuild@c6b10.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC) ) #1 SMP Wed Feb 27 03:24:34 UTC 2013
There is requirement in my project to hangup inbound call in certain cases, For that I have made php script that runs every second and hangup a call if it matchs the condition.
For hangup channel i use below syntax :
echo system("asterisk -rx 'hangup requst $channel'").
It is working fine if i run script from Terminal .
Issue:
When i add script in cronjob at that time script is running fine but echo system("asterisk -rx 'hangup requst $channel'"). command does not execute.
Please suggest how to execute above command from cronjob
Vicidial Configuration :
Vicidial VERSION: 2.7-401a BUILD: 130508-2256 (Scratch Install) | Asterisk : 1.8.21.0 | Two servers (Asterisk on both server,web interface on both servers,both servers use same database) | DAHDI: 2.7.0.1 | libpri : 1.4.14 | Allo E1 PRI CARD with 2 slots on both servers |No Extra Software After Installation|Intel(R) Xeon(R) CPU E31220 @ 3.10GHz 8 MB Cache| 8 GB RAM | Cent OS 6.4 | Linux version 2.6.32-358.0.1.el6.i686 (mockbuild@c6b10.bsys.dev.centos.org) (gcc version 4.4.7 20120313 (Red Hat 4.4.7-3) (GCC) ) #1 SMP Wed Feb 27 03:24:34 UTC 2013
There is requirement in my project to hangup inbound call in certain cases, For that I have made php script that runs every second and hangup a call if it matchs the condition.
For hangup channel i use below syntax :
echo system("asterisk -rx 'hangup requst $channel'").
It is working fine if i run script from Terminal .
Issue:
When i add script in cronjob at that time script is running fine but echo system("asterisk -rx 'hangup requst $channel'"). command does not execute.
Please suggest how to execute above command from cronjob