tai36
September 5, 2023, 7:28am
1
Hi there, I want to test inbound and outbound call follow on ASTPP .
Inbound: ISP → ASTPP → Sip device in ASTPP or Call center
Example: Call to 02xxxxxx → DIDs → Sip device of Customer (111)
Outbound: Sip device in ASTPP → ISP
Example: 111 dial 02xxxxx or 842xxxxx
But any way I trying to call in or call out, I will get error No route to destination.
Please help me fix it :(((
tai36
September 5, 2023, 10:40am
2
This picture is taken by sngrep.
I try call 02xxxxx by my phone number is 09xxx but i get error NO_ROUTE_DESTINATION. I have configured DIDs to push to customer’s sip device, customer, and allow ip provider
KNERD
September 5, 2023, 2:05pm
3
How about posting the freeswitch logs also?
1 Like
sman123
September 5, 2023, 3:39pm
4
The answer will be in your freeswitch log. You can also watch it in real time from the fs_cli
console. It probably cannot find a matching a rate to the number you are dialing.
1 Like
Hi Tai36, I notice that the number you dialed is 11 digits long and the display number is 10 digits. Is this correct? Are you is Aus.?
1 Like
tai36
September 6, 2023, 2:33am
6
send 313 bytes to udp/[210.211.108.3]:5060 at 09:31:22.888024:
SIP/2.0 100 Trying
Via: SIP/2.0/UDP 210.211.108.3;branch=z9hG4bKfVX6Saqyu~fHa;rport=5060
From: “0964348489” sip:0964348489@125.235.38.182 ;tag=8HQQ7gHa6ecKg
To: sip:02862856569@210.211.108.3:5060
Call-ID: 94df6ac3-c6ff-123c-b6b8-941882812ba8
CSeq: 72429792 INVITE
User-Agent: ASTPP
Content-Length: 0
2023-09-06 09:31:22.876516 99.03% [INFO] mod_dialplan_xml.c:639 Processing 0964348489 <0964348489>->02862856569 in context default
2023-09-06 09:31:22.896517 99.03% [ERR] mod_lua.cpp:202 cannot open /usr/share/freeswitch/scripts/astpp/astpp.lua: No such file or directory
2023-09-06 09:31:22.896517 99.03% [ERR] mod_lua.cpp:269 LUA script parse/execute error!
2023-09-06 09:31:22.896517 99.03% [WARNING] mod_dialplan_xml.c:669 Context default not found
2023-09-06 09:31:22.896517 99.03% [INFO] switch_core_state_machine.c:306 No Route, Aborting
2023-09-06 09:31:22.896517 99.03% [NOTICE] switch_core_state_machine.c:307 Hangup sofia/default/0964348489@125.235.38.182 [CS_ROUTING] [NO_ROUTE_DESTINATION]
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:640 (sofia/default/0964348489@125.235.38.182) State ROUTING going to sleep
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:581 (sofia/default/0964348489@125.235.38.182) Running State Change CS_HANGUP (Cur 1 Tot 14399)
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:844 (sofia/default/0964348489@125.235.38.182) Callstate Change RINGING → HANGUP
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:846 (sofia/default/0964348489@125.235.38.182) State HANGUP
2023-09-06 09:31:22.896517 99.03% [DEBUG] mod_sofia.c:469 Channel sofia/default/0964348489@125.235.38.182 hanging up, cause: NO_ROUTE_DESTINATION
2023-09-06 09:31:22.896517 99.03% [DEBUG] mod_sofia.c:614 Responding to INVITE with: 404
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:59 sofia/default/0964348489@125.235.38.182 Standard HANGUP, cause: NO_ROUTE_DESTINATION
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:846 (sofia/default/0964348489@125.235.38.182) State HANGUP going to sleep
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:616 (sofia/default/0964348489@125.235.38.182) State Change CS_HANGUP → CS_REPORTING
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:581 (sofia/default/0964348489@125.235.38.182) Running State Change CS_REPORTING (Cur 1 Tot 14399)
send 736 bytes to udp/[210.211.108.3]:5060 at 09:31:22.900678:
SIP/2.0 404 Not Found
Via: SIP/2.0/UDP 210.211.108.3;branch=z9hG4bKfVX6Saqyu~fHa;rport=5060
Max-Forwards: 69
From: “0964348489” sip:0964348489@125.235.38.182 ;tag=8HQQ7gHa6ecKg
To: sip:02862856569@210.211.108.3:5060 ;tag=30tS83ZmUvZKK
Call-ID: 94df6ac3-c6ff-123c-b6b8-941882812ba8
CSeq: 72429792 INVITE
User-Agent: ASTPP
Accept: application/sdp
Allow: INVITE, ACK, BYE, CANCEL, OPTIONS, MESSAGE, INFO, UPDATE, REGISTER, REFER, NOTIFY, PUBLISH, SUBSCRIBE
Supported: path, replaces
Allow-Events: talk, hold, conference, presence, as-feature-event, dialog, line-seize, call-info, sla, include-session-description, presence.winfo, message-summary, refer
Reason: Q.850;cause=3;text=“NO_ROUTE_DESTINATION”
Content-Length: 0
2023-09-06 09:31:22.896517 99.03% [DEBUG] switch_core_state_machine.c:932 (sofia/default/0964348489@125.235.38.182) State REPORTING
recv 333 bytes from udp/[210.211.108.3]:5060 at 09:31:22.901076:
ACK sip:02862856569@210.211.108.10:5060 SIP/2.0
Via: SIP/2.0/UDP 210.211.108.3;branch=z9hG4bKfVX6Saqyu~fHa;rport
From: “0964348489” sip:0964348489@125.235.38.182 ;tag=8HQQ7gHa6ecKg
To: sip:02862856569@210.211.108.3:5060 ;tag=30tS83ZmUvZKK
Call-ID: 94df6ac3-c6ff-123c-b6b8-941882812ba8
CSeq: 72429792 ACK
Content-Length: 0
2023-09-06 09:31:22.896517 99.03% [INFO] mod_json_cdr.c:272 Process [01d2ac18-42a3-427e-8ded-70668df8f804.cdr.json]
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:168 sofia/default/0964348489@125.235.38.182 Standard REPORTING, cause: NO_ROUTE_DESTINATION
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:932 (sofia/default/0964348489@125.235.38.182) State REPORTING going to sleep
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:607 (sofia/default/0964348489@125.235.38.182) State Change CS_REPORTING → CS_DESTROY
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_session.c:1744 Session 14399 (sofia/default/0964348489@125.235.38.182) Locked, Waiting on external entities
2023-09-06 09:31:22.936534 99.03% [NOTICE] switch_core_session.c:1762 Session 14399 (sofia/default/0964348489@125.235.38.182) Ended
2023-09-06 09:31:22.936534 99.03% [NOTICE] switch_core_session.c:1766 Close Channel sofia/default/0964348489@125.235.38.182 [CS_DESTROY]
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:735 (sofia/default/0964348489@125.235.38.182) Running State Change CS_DESTROY (Cur 0 Tot 14399)
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:745 (sofia/default/0964348489@125.235.38.182) State DESTROY
2023-09-06 09:31:22.936534 99.03% [DEBUG] mod_sofia.c:380 sofia/default/0964348489@125.235.38.182 SOFIA DESTROY
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:175 sofia/default/0964348489@125.235.38.182 Standard DESTROY
2023-09-06 09:31:22.936534 99.03% [DEBUG] switch_core_state_machine.c:745 (sofia/default/0964348489@125.235.38.182) State DESTROY going to sleep
recv 311 bytes from udp/[210.211.108.3]:5060 at 09:31:25.785846:
tai36
September 6, 2023, 2:37am
7
The log of freeswitch has been updated below
tai36
September 6, 2023, 2:40am
8
Hi neilsheppard, both numbers are syntactically correct, 10 digits is the phone number and 11 digits is the landline phone number and I come from Vietnam. Can you help me check this issue?
devangn
September 6, 2023, 7:36am
9
@tai36 , it seems you don’t have ASTPP DB profile loaded, share output of ‘sofia status’ from fs_cli, other thing is check the response of commaond ‘mod_exists mod_lua’ in fs_cli
tai36
September 6, 2023, 8:49am
11
Here is my fs_cli response
sman123
September 7, 2023, 5:46pm
12
You still have not posted freeswitch log data. The info you posted is SIP debug info. That will not show the problem so you should disable that. You want fs_cli
data which shows ASTPP db access where it tries to match rates to phone numbers as you are making calls. 99% of the time that is the problem and you will see a message in there saying it can’t find a match. This is assuming you have the basics set up correctly such as your SIP trunk.
tai36
September 11, 2023, 3:20am
13
Oh, How can I display this information you need to check? Please give me step by step to help me show it.
tai36
September 11, 2023, 3:28am
14
Hi Knerd, I get same issue with you after I fix error : “cannot open /usr/share/freeswitch/scripts/astpp/astpp.lua: No such file or directory” by cp file to /usr/share/freeswitch/scripts/astpp. Besides reinstalling from scratch, is there any way to fix this error directly so I can continue using it? My ASTPP is version 6.
tai36
September 11, 2023, 3:34am
15
@devangn Please give me solution for this case.
It seems ODBC is not installed or not configured properly. Look at /etc/odbc.ini.
tai36
September 11, 2023, 6:15am
17
I tested according to your instructions and this is the result I got
sman123
September 11, 2023, 3:24pm
19
Looks like maybe you have not installed the ODBC connector package.
apt install mysql-connector-odbc
.
Test odbc driver
odbcinst -s -q
Test odbc connection
isql -v astpp astppuser ${USER_PASSWORD}
quit
Same issue here. I tried to follow all the suggestions and seems that I have my odbc package running and connecting Astpp just fine. Still “Context default not found, No Route, Aborting” error.
SIP gateway and Trunk provider connects perfectly. I just can’t place a call.
2023-10-hhhhh 23:20:46.326412 94.40% [INFO] switch_cpp.cpp:1465 [ASTPP] Product ID : 1
2023-10-hhhhh 23:20:46.326412 94.40% [INFO] switch_cpp.cpp:1465 [ASTPP] Package Type : 1 Call Direction : outbound [0:inbound,1:outbound,2:both]
2023-10-hhhhh 23:20:46.326412 94.40% [DEBUG] switch_cpp.cpp:1465 [ASTPP] [GET_COUNTER_INFO] Query :SELECT used_seconds FROM counters WHERE accountid = 2 AND package_id = 1 AND status=1 LIMIT 1
2023-10-hhhhh 23:20:46.326412 94.40% [INFO] switch_cpp.cpp:1465 [ASTPP] Remaining minutes : 1500
2023-10-hhhhh 23:20:46.326412 94.40% [ERR] mod_lua.cpp:202 /usr/share/freeswitch/scripts/astpp/lib/astpp.functions.lua:510: attempt to compare nil with number
stack traceback:
/usr/share/freeswitch/scripts/astpp/lib/astpp.functions.lua:510: in function 'package_calculation'
...hare/freeswitch/scripts/astpp/scripts/astpp.dialplan.lua:193: in main chunk
[C]: in function 'dofile'
/usr/share/freeswitch/scripts/astpp/astpp.lua:85: in main chunk
2023-10-hhhhh 23:20:46.326412 94.40% [ERR] mod_lua.cpp:269 LUA script parse/execute error!
2023-10-hhhhh 23:20:46.326412 94.40% [WARNING] mod_dialplan_xml.c:669 **Context default not found**
2023-10-hhhhh 23:20:46.326412 94.40% [INFO] switch_core_state_machine.c:306 **No Route, Aborting**
2023-10-hhhhh 23:20:46.326412 94.40% [NOTICE] switch_core_state_machine.c:307 Hangup sofia/default/100123@myserver1 [CS_ROUTING] **[NO_ROUTE_DESTINATION**]
2023-10-hhhhh 23:20:46.326412 94.40% [DEBUG] switch_core_state_machine.c:640 (sofia/default/100123@myserver1) State ROUTING going to sleep
I just fixed by removing the astpp database and re-imported it (I followed this individual steps from:
under the part “Configure MySQL” only)