[asterisk-dev] AST_MODULE_LOAD_FAILURE vs AST_MODULE_LOAD_DECLINE

Richard Mudgett rmudgett at digium.com
Wed Apr 5 16:23:58 CDT 2017


On Wed, Apr 5, 2017 at 3:43 PM, George Joseph <gjoseph at digium.com> wrote:

> Over the years I've been frustrated at times where Asterisk fails to start
> for absolutely no (apparent) reason.  No error message, no trap, nothing.
> It just ends.  Every case of this I've tracked down has been the result of
> a module returning AST_MODULE_LOAD_FAILURE when it encounters a problem
> but not bothering to print an error first.   If you don't know
> already, AST_MODULE_LOAD_FAILURE tells asterisk to *stop loading and exit*.
> What the module should have done was actually print an error and
> return AST_MODULE_LOAD_DECLINE which just tells asterisk that the module
> couldn't load.
>
> So now I'm doing an audit of module return codes to see which call FAILURE
> vs DECLINE and found the modules below all call FAILURE.
>
> The big question is...  Exactly which modules are so critical to asterisk
> that asterisk should exit if the module couldn't load?  Surely not all 103
> modules listed below.  If we can agree on the ones that really *should*
> call FAILURE, I'll update those with error messages, then change the rest
> to DECLINE and add error messages as needed.
>
> Reply with the list intact.  Don't add, remove, split or re-order the
> lines.  Just stick an "F " before the modules you think should remain
> failure.
>
> Modules returning FAILURE:
>
> ./addons/app_mysql.c
> ./addons/cdr_mysql.c
> ./addons/chan_mobile.c
> ./apps/app_adsiprog.c
> ./apps/app_agent_pool.c
> ./apps/app_alarmreceiver.c
> ./apps/app_amd.c
> ./apps/app_authenticate.c
> ./apps/app_cdr.c
> ./apps/app_confbridge.c
> ./apps/app_festival.c
> ./apps/app_followme.c
> ./apps/app_forkcdr.c
> ./apps/app_meetme.c
> ./apps/app_queue.c
> ./apps/app_skel.c
> ./apps/app_voicemail.c
> ./cdr/cdr_custom.c
> ./cel/cel_custom.c
> ./cel/cel_odbc.c
> ./channels/chan_alsa.c
> ./channels/chan_console.c
> ./channels/chan_dahdi.c
> ./channels/chan_iax2.c
> ./channels/chan_mgcp.c
> ./channels/chan_misdn.c
> ./channels/chan_motif.c
> ./channels/chan_nbs.c
> ./channels/chan_oss.c
> ./channels/chan_phone.c
> ./channels/chan_pjsip.c
> ./channels/chan_sip.c
> ./channels/chan_skinny.c
> ./channels/chan_unistim.c
> ./channels/chan_vpb.cc
> ./codecs/codec_a_mu.c
> ./codecs/codec_adpcm.c
> ./codecs/codec_alaw.c
> ./codecs/codec_g722.c
> ./codecs/codec_g726.c
> ./codecs/codec_gsm.c
> ./codecs/codec_ilbc.c
> ./codecs/codec_lpc10.c
> ./codecs/codec_resample.c
> ./codecs/codec_ulaw.c
> ./formats/format_g723.c
> ./formats/format_g726.c
> ./formats/format_g729.c
> ./formats/format_gsm.c
> ./formats/format_h263.c
> ./formats/format_h264.c
> ./formats/format_ilbc.c
> ./formats/format_jpeg.c
> ./formats/format_ogg_vorbis.c
> ./formats/format_pcm.c
> ./formats/format_sln.c
> ./formats/format_vox.c
> ./formats/format_wav.c
> ./formats/format_wav_gsm.c
> ./funcs/func_cdr.c
> F ./main/loader.c
> ./pbx/pbx_dundi.c
> F ./pbx/pbx_loopback.c
> F ./pbx/pbx_realtime.c
> F ./pbx/pbx_spool.c
> ./res/res_pjsip/config_transport.c
> ./res/res_ari.c
> ./res/res_ari_events.c
> ./res/res_ari_model.c
> ./res/res_calendar.c
> ./res/res_chan_stats.c
> ./res/res_clialiases.c
> ./res/res_config_ldap.c
> ./res/res_config_sqlite.c
> ./res/res_config_sqlite3.c
> ./res/res_curl.c
> ./res/res_endpoint_stats.c
> ./res/res_fax.c
> ./res/res_hep_rtcp.c
> ./res/res_http_websocket.c
> ./res/res_musiconhold.c
> ./res/res_odbc.c
> ./res/res_phoneprov.c
> ./res/res_pjsip_nat.c
> ./res/res_pjsip_one_touch_record_info.c
> ./res/res_pjsip_outbound_publish.c
> ./res/res_pjsip_outbound_registration.c
> ./res/res_pjsip_sdp_rtp.c
> ./res/res_pjsip_send_to_voicemail.c
> ./res/res_pjsip_t38.c
> ./res/res_smdi.c
> ./res/res_snmp.c
> ./res/res_stasis.c
> ./res/res_stasis_device_state.c
> ./res/res_stasis_playback.c
> ./res/res_stasis_recording.c
> ./res/res_stasis_test.c
> ./res/res_statsd.c
> ./res/res_timing_kqueue.c
> ./res/res_xmpp.c
> ./res/res_pjsip_pubsub.c
> ./tests/test_bucket.c
> ./tests/test_channel_feature_hooks.c
>
> --
> George Joseph
> Digium, Inc. | Software Developer
> 445 Jan Davis Drive NW - Huntsville, AL 35806 - US
> Check us out at: www.digium.com & www.asterisk.org
>
>
> --
> _____________________________________________________________________
> -- 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/20170405/8960b73f/attachment-0001.html>


More information about the asterisk-dev mailing list