I've tried that what you said over there, but it didn't work, so I changed it a little, but it's still not working.
Now agi_extension is showing the number I'm dialing, is this ok, or must it show something else?
Edit: Sorry that I'm such a pain in the you know what.
I've changed the a2billing.conf so many time that not even the authors of a2billing would recognize it, so I copied it over once more, and now, I think it's ok, but the phone isn't rining(it could be because I didn't yet set up the dial plan in A2B only in asterisk). So this is what I get at the end:
Quote:
a2billing.php: file:a2billing.php - line:92 - Array
a2billing.php: (
a2billing.php: [agi_request] => a2billing.php
a2billing.php: [agi_channel] => SIP/2490138548-086d63d8
a2billing.php: [agi_language] => si
a2billing.php: [agi_type] => SIP
a2billing.php: [agi_uniqueid] => asterisk-1218712089.37
a2billing.php: [agi_callerid] => 346270722130500
a2billing.php: [agi_calleridname] => Tomaz Lovrec
a2billing.php: [agi_callingpres] => 0
a2billing.php: [agi_callingani2] => 0
a2billing.php: [agi_callington] => 0
a2billing.php: [agi_callingtns] => 0
a2billing.php: [agi_dnid] => 32
a2billing.php: [agi_rdnis] => unknown
a2billing.php: [agi_context] => macro-voice-dial
a2billing.php: [agi_extension] => s
a2billing.php: [agi_priority] => 9
a2billing.php: [agi_enhanced] => 0.0
a2billing.php: [agi_accountcode] => 2490138548
a2billing.php: )
a2billing.php:
a2billing.php: file:Class.A2Billing.php - line:621 - get_agi_request_parameter = 346270722130500 ; SIP/2490138548-086d63d8 ; asterisk-1218712089.37 ; 2490138548 ; s
-- AGI Script a2billing.php completed, returning 0
== Auto fallthrough, channel 'SIP/2490138548-086d63d8' status is 'UNKNOWN'
Added after 2 hours 27 minutes: Scratch that. Something interesting.
I have 3 phone numbers on our asterisk installations.
1 installation is a production installation, and so that I don't mess it up, I've installed another one on another machine(test installation).
I'm connecting these two installations via IAX2 peers and registry:
Quote:
n24-199*CLI> iax2 show peers
Name/Username Host Mask Port Status
plvoip 172.25.0.2 (D) 255.255.255.255 4569 (T) OK (21 ms)
n24-199*CLI> iax2 show registry
Host dnsmgr Username Perceived Refresh State
172.25.0.2:4569 N n24-199 172.24.0.199:4569 20 Registered
So the numbers are:
- 32 (located on production installation, which has only Asterisk BRIstuffed)
- 199 (located on test installation)
- and my number (located on test installation)
Now, when I call number 32, which is on a different asterisk without a2b I get this:
Quote:
a2billing.php: file:Class.A2Billing.php - line:621 - get_agi_request_parameter = 346270722130500 ; SIP/2490138548-0870fac0 ; asterisk-1218714928.66 ; 2490138548 ; s
a2billing.php: file:a2billing.php - line:145 - [NO ANSWER CALL]
a2billing.php: file:Class.A2Billing.php - line:1640 - SELECT credit, tariff, activated, inuse, simultaccess, typepaid, creditlimit, language, removeinterprefix, redial, enableexpire, UNIX_TIMESTAMP(expirationdate), expiredays, nbused, UNIX_TIMESTAMP(firstusedate), UNIX_TIMESTAMP(cc_card.creationdate), cc_card.currency, cc_card.lastname, cc_card.firstname, cc_card.email, cc_card.uipass, cc_card.id_campaign, cc_card.id, useralias FROM cc_card LEFT JOIN cc_tariffgroup ON tariff=cc_tariffgroup.id WHERE username='2490138548'
a2billing.php: file:Class.A2Billing.php - line:1714 - [SET CHANNEL(language) en]
a2billing.php: file:Class.A2Billing.php - line:654 - [CARD STATUS UPDATE : UPDATE cc_card SET inuse=inuse+1 WHERE username='2490138548']
a2billing.php: file:Class.A2Billing.php - line:1400 - [AUTO SetCallerID]
a2billing.php: file:Class.A2Billing.php - line:1406 - [REQUESTED SetCallerID : 346270722130500]
a2billing.php: file:Class.A2Billing.php - line:1417 - [EXEC SetCallerID : 346270722130500]
a2billing.php: file:a2billing.php - line:172 - [CHANNEL STATUS : 4 = Line is ringing]
a2billing.php: file:a2billing.php - line:173 - [CREDIT : 500][CREDIT MIN_CREDIT_2CALL : 0]
a2billing.php: file:Class.A2Billing.php - line:676 - 1 && && 2&& 0
-- <SIP/2490138548-0870fac0> Playing 'prepaid-enter-dest' (language 'en')
The destination to dial should be IAX2/plvoip/32,
but when I try to call number 199 which is on the same asterisk installation as my number, I get this:
Quote:
a2billing.php: file:Class.A2Billing.php - line:621 - get_agi_request_parameter = 346270722130500 ; SIP/2490138548-086d63d8 ; asterisk-1218714916.65 ; 2490138548 ; s
a2billing.php: file:a2billing.php - line:145 - [NO ANSWER CALL]
a2billing.php: file:Class.A2Billing.php - line:1640 - SELECT credit, tariff, activated, inuse, simultaccess, typepaid, creditlimit, language, removeinterprefix, redial, enableexpire, UNIX_TIMESTAMP(expirationdate), expiredays, nbused, UNIX_TIMESTAMP(firstusedate), UNIX_TIMESTAMP(cc_card.creationdate), cc_card.currency, cc_card.lastname, cc_card.firstname, cc_card.email, cc_card.uipass, cc_card.id_campaign, cc_card.id, useralias FROM cc_card LEFT JOIN cc_tariffgroup ON tariff=cc_tariffgroup.id WHERE username='2490138548'
a2billing.php: file:Class.A2Billing.php - line:1714 - [SET CHANNEL(language) en]
a2billing.php: file:Class.A2Billing.php - line:654 - [CARD STATUS UPDATE : UPDATE cc_card SET inuse=inuse+1 WHERE username='2490138548']
a2billing.php: file:Class.A2Billing.php - line:1400 - [AUTO SetCallerID]
a2billing.php: file:Class.A2Billing.php - line:1406 - [REQUESTED SetCallerID : 346270722130500]
a2billing.php: file:Class.A2Billing.php - line:1417 - [EXEC SetCallerID : 346270722130500]
a2billing.php: file:a2billing.php - line:172 - [CHANNEL STATUS : 4 = Line is ringing]
a2billing.php: file:a2billing.php - line:173 - [CREDIT : 500][CREDIT MIN_CREDIT_2CALL : 0]
a2billing.php: file:Class.A2Billing.php - line:676 - 1 && && 3&& 0
a2billing.php: file:Class.A2Billing.php - line:701 - DESTINATION ::> 199
a2billing.php: file:Class.A2Billing.php - line:703 - RULES APPLY ON DESTINATION ::> 199
a2billing.php: file:Class.A2Billing.php - line:739 - ERROR ::> RateEngine didnt succeed to match the dialed number over the ratecard (Please check : id the ratecard is well create ; if the removeInter_Prefix is set according to your prefix in the ratecard ; if you hooked the ratecard to the Call Plan)
a2billing.php: file:Class.A2Billing.php - line:654 - [CARD STATUS UPDATE : UPDATE cc_card SET inuse=inuse-1 WHERE username='2490138548']
-- AGI Script a2billing.php completed, returning 0
So unless I'm blind, when I try to call number 199, the destination goes through just perfectly but then strikes another error. But when I try to call number 32, it asks me to redial the number who I wish to call. These two errors are, at least to me, not even remotely connected, so there must be an error somewhere else, not that the number wouldn't be provided to a2b, am I right?
Now how to fix this? Could this be that I have not yet configured a dial plan in A2B?