Configured Trunk between 2 asterisk servers. The settings are simple
Dialpan is written
extensions = {
[“ABsip”] = {
["_XXX"] = function (context, exten, trunk) app.dial (“PJSIP /” … exten … “@ABsip”); end
};
}
when I dial 222, which is registered at 10.20.30.222, I call from 111, which is registered at 10.20.30.111, on both servers I see the following
https://paste.pztrn.name/paste/1581/1601828110 <= A server output is the same, only ip changes
Setting global variable ‘SIPDOMAIN’ to '10 .20.30.222 ’
- Executing [222 @ ABsip: 1] dial (“PJSIP / 404-000007da”, “PJSIP / 222 @ ABsip”)
Setting global variable ‘SIPDOMAIN’ to '10 .20.30.111 ’
- Executing [222 @ ABsip: 1] dial (“PJSIP / ABsip-000007e0”, “PJSIP / 222 @ ABsip”)
- Called PJSIP / 222 @ ABsip
I tried to rewrite the recruitment plan in different ways, but it was unsuccessful, please help.
At the same time, having some kind of magic, a dialpan that works for internal numbers 10.20.30.111 also works at 10.20.30.222, but I want to understand how to send it to the trunk, and not with magic.
Bellow it
extensions = {
[“ABsip”] = {
["_XXX"] = function(context, exten) app.dial(“PJSIP/”… exten); end
};
}