[asterisk-dev] RFC: DAHDI echo canceller configuration change

Kevin P. Fleming kpfleming at digium.com
Thu Jun 19 07:16:15 CDT 2008


Oron Peled wrote:

> I think the inevitable renaming is a good timing to prepare for the
> future and have the configuration for dahdi in its own subdirectory.
> 
> Example: /etc/dahdi/dahdi.conf
> 
> That would provide a central location for other config files that are
> currently maintained in a linux distribution specific places
> (e.g: /etc/default/zaptel, /etc/sysconfig/zaptel, etc.)
> Also, since dahdi became a pretty big framework on its own, we are
> bound to need more info/control files in the future -- let's not
> scatter them in /etc.

We've had this discussion briefly and hadn't reached a decision, but I
think if we *do* move it to /etc/dahdi, the filename shouldn't be
dahdi.conf, since that is just redundant. It should be something like
'channels.conf' or 'system.conf' or something like that, but I can't
come up with a good suggestion.

> Or maybe:
> 
> default_echocanceler=<name>
> 
> While it is mouthfull, it's easy to parse for everybody (humans,
> dahdi_config, miscellaneous scripts, etc.) and less prone to
> human errors.

If we do that, it will work the same way that the 'defaultlaw' setting
works, which is that it overrides the setting for all channels at the
time it is parsed, even if previous configurations have set channels
already. In other words, the 'default<foo>' settings have to be appear
*before* any channel-specific settings; making dahdi_cfg able to handle
intermingling them would complicate the code too much to be worthwhile.

> Good. The hard part is to decide what to do in case of failure (in
> addition to a message), as dahdi is already loaded at this stage.

> Maybe put the relevant channels in some alarm (now that we have
> per-channel alarms implemented)?

Well, the DAHDI_CHANCONFIG ioctl will fail if the chosen echo canceler
can't be attached to the channel, which will cause dahdi_cfg to abort
and report the failure as well. I hadn't thought about the possibility
of using channel alarms for this purpose; that may be a good solution,
and if we did that, we'd let dahdi_cfg continue to attempt to put the
same (unavailable) echo canceler onto each channel it is configured for
so that all of them will go into alarm, not just the first one.

-- 
Kevin P. Fleming
Director of Software Technologies
Digium, Inc. - "The Genuine Asterisk Experience" (TM)



More information about the asterisk-dev mailing list