[asterisk-ss7] Asterisk with one signalling link but 2 opc
Kaloyan Kovachev
kkovachev at varna.net
Sun Mar 27 07:11:21 CDT 2016
Hi,
On 2016-03-26 15:37, Mehdi Shirazi wrote:
> Hi
> Thank you for reply.
> for simulating a real PSTN network scenario I still need to have 2
> point code in asterisk and one signaling link for them.
Your real PSTN network scenario most likely requires an STP to split the
messages to two end points ... once again Asterisk with libss7 is a
Signalling End Point (SEP) and it has no routing functionality as STP
> In existing libss7 ,if we have 2 signaling links on 2 linksets with 2
> opc for Asterisk there is no problem.
> I looked at source of libss7 I saw in mtp3.c:( with my limited
> programming knowledge)
> if (ss7->pc != rl.dpc) {
> ss7_error(ss7, "Received message destined for point code 0x%x, but we
> are 0x%x. Dropping\n", rl.dpc, ss7->pc);
A signalling link is a point-to-point connection between two SS7 point
codes and every node has it's own (one and only) point code. If the
received message is not for it's own point code and the node has no
routing functionality - it should be dropped (which the code above
does). The only way to have two point codes is to have an Alias Point
Code for a clustered node, but again it requires routing and clustering
capabilities which Asterisk and libss7 does not have yet.
> ....
> switch (userpart) {
> case SIG_ISUP:
> if (link->adj_sp->state == MTP3_UP) {
> return isup_receive(ss7, link, &rl, sif + rlsize, siflen - rlsize);
>
> so it seems for every linkset there is a "struct ss7", and if we can
> query existing list of "struct ss7"s(linksets) and find
> matching ss7->pc with received MSU point code, we can put correct
> address of "struct ss7" in "isup_receive()" function
> and send the call to it's appropriate linkset.
> according to my grep libss7 allocate new "struct ss7" with
> *ss7_new(int switchtype) function but I cannot find where
> libss7 call this function and where is list of allocated "struct ss7"=
> linksets
> Do you agree with me and could you please help me ?
The ss7 code is split between libss7 and Asterisk (chan_dahdi and
sig_ss7) - that's where ss7_new() is called, when a new linkset is
created. What you suggest is the same as to define another linkset with
the same sigchan, which is not possible.
Instead of checking ss7->pc we should scan a list of routes attached to
the linkset and to add routing functionality, which is not so simple and
will require quite a lot of code changes.
>
> Regards
> M.Shirazi
>
>
>
> --------------------------------------------
> On Mon, 3/21/16, Kaloyan Kovachev <kkovachev at varna.net> wrote:
>
> Subject: Re: [asterisk-ss7] Asterisk with one signalling link but 2 opc
> To: "Mehdi Shirazi" <mahdi_shirazi at yahoo.com>,
> asterisk-ss7 at lists.digium.com
> Date: Monday, March 21, 2016, 8:11 AM
>
> Hi,
> Asterisk (with libss7) is a signaling end-point, so you
> can't have two
> point-codes - you need an STP (which Asterisk is not)
> between the two
> boxes in order to separate the two signaling channels.
> However you do not need two point-codes for this setup, but
> simply to
> define two groups of channels ... from the example in my
> previous email,
> change the linkset definitions to:
>
> linkset=1
> networkindicator=national
> group=1
> context=From_Span1
> pointcode=1
> defaultdpc=2
> adjpointcode=2
> cicbeginswith=1
> channel => 1-15
> group=2
> context=From_Span2
> cicbeginswith=17
> channel => 17-31
> sigchan=16
>
> #include ss7.timers
>
> linkset=2
> networkindicator=national
> group=3
> context=From_Span3
> pointcode=2
> defaultdpc=1
> adjpointcode=1
> cicbeginswith=1
> channel => 32-46
> group=4
> context=From_Span4
> cicbeginswith=17
> channel => 48-62
> sigchan=47
>
> #include ss7.timers
>
>
> Now you have 4 groups on the same 2 linksets, which is equal
> of having
> two separate linksets on the same signalling link.
>
>
> On 2016-03-21 07:40, Mehdi Shirazi wrote:
> > Hi
> > I connected 2 asterisk server with libss7 together to
> simulate real
> > scenario.
> > There is one signaling link between .
> > Asterisk one has one opc11 but Asterisk two have two
> opc2_1 and opc2_2.
> > There is 2 spans between , and I want to first spans
> use opc2_1 and
> > second span use opc2_2.
> > For setting Asterisk one there is no problem , in same
> linkset I can
> > add new defaultdpc=3
> > and new channels and new CICs. but in second server how
> I can add CICs
> > ,here I should separate
> > add CICs based on pointcode (opc2_1 and opc2_2) but it
> seems one link
> > set just accept one point code.
> >
> > If I want to add linkset with new pointcode(opc) with
> same signaling
> > channel it is not possible.
> >
> > how I can have one signaling link but multiple
> originate point code in
> > different channel groups ?
> >
> > Regards
> > M.Shirazi
More information about the asterisk-ss7
mailing list