[asterisk-dev] Distributed device states behavior when device names overlap between servers

Dimitris Kazakos nemphys at gmail.com
Sun Jan 29 14:26:00 CST 2012


The point is that I *do* want the state of the DAHDI channel to be
published (in the test, it is a FXS extension), but it should be somehow:
1) distinguished from the devices with the same name (eg. DAHDI/4) on each
of the other servers
2) be monitored nevertheless by hints on the other servers, since this is
the initial purpose of the test.

What I am thinking as a quick (but not optimal solution) is to have the
jabber module publish only the custom device states and create a custom
state for each extension that follows the stage changes of the "normal"
devices.

This will definitely solve my problem, but will spoil the purpose of device
state sharing between servers.

Maybe there should be a more sophisticated way of posting states using
pubsub than just device name/device state that could accomplish both goals.

Any ideas?

PS. As for the comment on the documentation, I didn't mean to be rude.
There is are just too many results if you google "asterisk distributed
device states" but they all point to the same few paragraphs with the same
example that involves a custom device state and not real devices.

On Sun, Jan 29, 2012 at 8:02 PM, Russell Bryant
<russell at russellbryant.net>wrote:

> On Sun, Jan 29, 2012 at 6:05 AM, Dimitris Kazakos <nemphys at gmail.com>
> wrote:
> > Either I missed something important, or there is a design flaw in the
> > distributed device states functionality:
> >
> > After struggling for a while, I managed to get 2 asterisk servers
> > (inter-connected using an IAX trunk) connected to an Openfire XMPP server
> > with the intention to share extension states between them (for blf
> usage).
> > I first tried the Custom device suggested to be used as a test in the
> > documentation (which is quite poor, btw) and all worked fine; the state
> was
> > properly shared between the servers.
>
> Now that you set it up, feel free to help with the documentation.
>
> > The problem starts when the state sharing started for actual devices.
> > After a little digging in the Openfire database/XMPP message logs
>  trying to
> > see what was actually published, I realized that there are 2 things
> > published with each state change: device name and state (along with the
> > server eID) - good so far.
> > The problem is that both servers have DAHDI fxs/fxo cards and therefore
> both
> > servers have DAHDI/X devices. For those devices, the state is normally
> > published using XMPP pubsub, but since the device names are the same in
> both
> > servers (though the actual devices are different), when eg. device
> DAHDI/5
> > on server 1 was in a call, the device state of DAHDI/5 on server 2 (using
> > show hints) would change to "in-use".
> > This of course is a deal breaker, as there are many devices that have the
> > same name (custom DND, meetme, etc, actually all except sip/iax
> > extensions/trunks).
> >
> > Am I missing something, or this issue has not been addressed yet?
>
> You're right.  It's just that you're the first person that has found
> this to be a problem.  I think most people are just using the states
> of SIP devices.  Adding some options to limit what states get
> published wouldn't be very hard.
>
> --
> Russell Bryant
>
> --
> _____________________________________________________________________
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>
> asterisk-dev mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-dev/attachments/20120129/992d496b/attachment.htm>


More information about the asterisk-dev mailing list