Asterisk / Freepbx assistance

ijacobs3

Expert Member
Joined
Oct 15, 2009
Messages
2,055
#1
Morning all

quick question for the guru's

im busy toying with freepbx using sip trunks for inbound and outbound calls, but i seem to be having a issue with adding multiple sip trunks, the moment i activate the second sip trunk i cannot receive calls at all,

[2019-01-18 09:58:27] NOTICE[2656] chan_sip.c: Peer 'Number b' is now Reachable. (24ms / 2000ms)
[2019-01-18 09:59:01] WARNING[2656][C-00000028] chan_sip.c: username mismatch, have <Number a>, digest has <Number b>

i've tried googling, but im not getting any solid answers, both channels are set up identically
 

gfmalan

Expert Member
Joined
Nov 11, 2013
Messages
2,308
#5
Good Day,

Herewith a working config (I changed the IP, User and Pass), I have another 2 trunks on this PBX, and all 4 works.

Trunk 1
dtmfmode=rfc2833
canreinvite=no
nat=no
insecure=very
secret=d7fab11111
host=41.1.2.3
type=peer
qualify=yes
username=SIP020-001
disallow=all
allow=g729:60
setvar=T38GATEWAY=no
context=from-trunk

Trunk 2
dtmfmode=rfc2833
canreinvite=no
nat=no
insecure=very
secret=2WDGN111111
host=41.1.2.3
type=peer
qualify=yes
username=SIP001-001
disallow=all
allow=g729:60
setvar=T38GATEWAY=no
context=from-trunk

I have 4 interfaces on the PBX, eth2 is connected to the router, and my default gateway on the PBX is the router, I did add static routes for management over VPN and for the phones to connect on eth0.

No funnies really.
 

gfmalan

Expert Member
Joined
Nov 11, 2013
Messages
2,308
#6
I think I see the problem, are you really trying to add 2 FreshPhone numbers as trunks?

That wouldn't work, as they don't provide SIP trunks. I'm a reseller of Euphoria and ECN and you can't do what I think you are trying to-do. Maybe you will be lucky with a make shift plan, but what FreshPhone give you is an extension on a PBX, so you aren't connecting to a SIP server, but to a PBX as Extension.

If you need 2 test SIP accounts, then I can help for you to play.

If you want to use FreshPhone as "lines" then get yourself a ATA from Linksys or Grandstream, connect the VoIP side to the 2 extensions, and then use a BRI ISDN card to link the ATA and PBX, or if you have a 4 port FXO card, install that in PBX and get a 2 port FXS ATA.

Or skip everything, signup for a Hosted PBX and we maintain the PBX and you enjoy all the great features with no risk.
 

ijacobs3

Expert Member
Joined
Oct 15, 2009
Messages
2,055
#7
I think I see the problem, are you really trying to add 2 FreshPhone numbers as trunks?

That wouldn't work, as they don't provide SIP trunks. I'm a reseller of Euphoria and ECN and you can't do what I think you are trying to-do. Maybe you will be lucky with a make shift plan, but what FreshPhone give you is an extension on a PBX, so you aren't connecting to a SIP server, but to a PBX as Extension.

If you need 2 test SIP accounts, then I can help for you to play.

If you want to use FreshPhone as "lines" then get yourself a ATA from Linksys or Grandstream, connect the VoIP side to the 2 extensions, and then use a BRI ISDN card to link the ATA and PBX, or if you have a 4 port FXO card install that in PBX and get a 2 port FXS ATA.

Or skip everything, signup for a Hosted PBX and we maintain the PBX and you enjoy all the great features with no risk.
Okay, makes sense , I have the one “line” setup as a sip trunk, and incoming / outgoing works fine in that 1, but as soon as I add a second it all goes pear shaped

I’ve gotten in contact with bcx who can convert our lines to sip channels , at this point , due to reasons ( long story) I’ve had to setup our own internal box,
 

AsteriskUser

Active Member
Joined
Mar 9, 2017
Messages
44
#8
Morning all

quick question for the guru's

I'm busy toying with freepbx using sip trunks for inbound and outbound calls, but I seem to be having an issue with adding multiple sip trunks, the moment I activate the second sip trunk I cannot receive calls at all,

[2019-01-18 09:58:27] NOTICE[2656] chan_sip.c: Peer 'Number b' is now Reachable. (24ms / 2000ms)
[2019-01-18 09:59:01] WARNING[2656][C-00000028] chan_sip.c: username mismatch, have <Number a>, digest has <Number b>

I've tried googling, but I'm not getting any solid answers, both channels are set up identically

I don't see why this isn't possible, I can't speak for freepbx, but you should be able to do this in vanilla asterisk. Also with regards to the PBX extensions vs trunks, either should work as long as you have an active registration. I would try using normal asterisk or contact freepbx (may have to pay for support) regarding this. I don't know what they do in the dial plan but in extentions.conf on asterisk you should be able to handle all the routing of these calls.
 

ijacobs3

Expert Member
Joined
Oct 15, 2009
Messages
2,055
#9
I don't see why this isn't possible, I can't speak for freepbx, but you should be able to do this in vanilla asterisk. Also with regards to the PBX extensions vs trunks, either should work as long as you have an active registration. I would try using normal asterisk or contact freepbx (may have to pay for support) regarding this. I don't know what they do in the dial plan but in extentions.conf on asterisk you should be able to handle all the routing of these calls.

i have come right, thanks :)

@gfmalan came to the rescue :)
 
Top