[asterisk-users] Asterisk Help

Noah Miller noahisaacmiller at gmail.com
Mon Jul 9 14:24:55 CDT 2007


Hi Arun -

> I need help in configuring a auto dialer system using Asterisk. I'm holding
> my customers number in MySQL want to fetch 10 numbers one time and dial if
> gets connected and answered by customer wants to play a sequence of message
>
> I've tried here is my code to place calls but in this I see no of failure
> calls are more than 50%. so please advise.
>                           $oSocket = fsockopen($strHost, 5038, $errnum,
> $errdesc) or die("Connection to host failed");
>                                 fputs($oSocket, "Action: login\r\n");
>                                 fputs($oSocket, "Username: $strUser\r\n");
>                                 fputs($oSocket, "Secret:
> $strSecret\r\n\r\n");
>                                 fputs($oSocket, "Action: Originate\r\n");
>                                 fputs($oSocket, "Channel: $strChannel\r\n");
>                                 fputs($oSocket, "CallerId:
> $strCallerId\r\n");
>                                 fputs($oSocket, "Context: $strContext\r\n");
>                                 fputs($oSocket, "Exten: $strExten\r\n");
>                                 fputs($oSocket, "Priority:
> $strPriority\r\n\r\n");
>                                 fputs($oSocket, "Action: Logoff\r\n\r\n");

It would be very difficult to determine what's wrong without seeing
more information.  For a wild guess, I'd say that the individual MySQL
records probably have formatting differences that don't match the
format of your code.  If so, the data that's pulled in may be bad by
the time it gets to your dial statements.  Just a random guess.

Can you send some CLI output, or turn on logging and give us a little more info?


- Noah



More information about the asterisk-users mailing list