DND not working

So today, someone’s phone was on DND and they could not take it off…

I added their extension to my pone and neither can I. I can turn it on, but not off.

*78 works.
*79 results in this:

[2019-02-11 15:27:43] WARNING[12951][C-00000002]: pbx.c:2906 pbx_extension_helper: No application 'dbDel' for extension (from-internal, *79, 3)

It is enabled. No idea how long it has been like this as no one usually uses DND on this system.

Working for me. What does a call trace show?
https://wiki.freepbx.org/display/SUP/Providing+Great+Debug#ProvidingGreatDebug-AsteriskLogs

$ grep C-00000002 /var/log/asterisk/full
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [*[email protected]:1] Macro("PJSIP/103-00000001", "user-callerid,") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:1] Set("PJSIP/103-00000001", "TOUCH_MONITOR=1549920463.2") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:2] Set("PJSIP/103-00000001", "AMPUSER=103") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:3] GotoIf("PJSIP/103-00000001", "0?report") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:4] ExecIf("PJSIP/103-00000001", "1?Set(REALCALLERIDNUM=103)") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:5] Set("PJSIP/103-00000001", "AMPUSER=103") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:6] GotoIf("PJSIP/103-00000001", "0?limit") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:7] Set("PJSIP/103-00000001", "AMPUSERCIDNAME=Jared Busch") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:8] ExecIf("PJSIP/103-00000001", "0?Set(__CIDMASQUERADING=TRUE)") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:9] GotoIf("PJSIP/103-00000001", "0?report") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:10] Set("PJSIP/103-00000001", "AMPUSERCID=103") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:11] Set("PJSIP/103-00000001", "__DIAL_OPTIONS=Ttr") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:12] Set("PJSIP/103-00000001", "CALLERID(all)="Jared Busch" <103>") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:13] GotoIf("PJSIP/103-00000001", "0?limit") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:14] ExecIf("PJSIP/103-00000001", "0?Set(GROUP(concurrency_limit)=103)") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:15] ExecIf("PJSIP/103-00000001", "0?Set(CHANNEL(language)=)") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:16] NoOp("PJSIP/103-00000001", "Macro Depth is 1") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:17] GotoIf("PJSIP/103-00000001", "1?report2:macroerror") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx_builtins.c: Goto (macro-user-callerid,s,18)
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:18] GotoIf("PJSIP/103-00000001", "0?continue") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:19] ExecIf("PJSIP/103-00000001", "1?Set(__CALLEE_ACCOUNCODE=)") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:20] Set("PJSIP/103-00000001", "__TTL=64") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:21] GotoIf("PJSIP/103-00000001", "1?continue") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx_builtins.c: Goto (macro-user-callerid,s,37)
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:37] Set("PJSIP/103-00000001", "CALLERID(number)=103") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:38] Set("PJSIP/103-00000001", "CALLERID(name)=Jared Busch") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:39] GotoIf("PJSIP/103-00000001", "0?cnum") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:40] Set("PJSIP/103-00000001", "CDR(cnam)=Jared Busch") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:41] Set("PJSIP/103-00000001", "CDR(cnum)=103") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:42] Set("PJSIP/103-00000001", "CHANNEL(language)=en") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [*[email protected]:2] Set("PJSIP/103-00000001", "CHAN=PJSIP/103") in new stack
[2019-02-11 15:27:43] WARNING[12951][C-00000002] pbx.c: No application 'dbDel' for extension (from-internal, *79, 3)
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Spawn extension (from-internal, *79, 3) exited non-zero on 'PJSIP/103-00000001'
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:1] Macro("PJSIP/103-00000001", "hangupcall") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:1] GotoIf("PJSIP/103-00000001", "1?theend") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx_builtins.c: Goto (macro-hangupcall,s,3)
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:3] ExecIf("PJSIP/103-00000001", "0?Set(CDR(recordingfile)=)") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:4] NoOp("PJSIP/103-00000001", " monior file= ") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:5] AGI("PJSIP/103-00000001", "attendedtransfer-rec-restart.php,,") in new stack
[2019-02-11 15:27:43] VERBOSE[12951][C-00000002] res_agi.c: Launched AGI Script /var/lib/asterisk/agi-bin/attendedtransfer-rec-restart.php
[2019-02-11 15:27:44] VERBOSE[12951][C-00000002] res_agi.c: <PJSIP/103-00000001>AGI Script attendedtransfer-rec-restart.php completed, returning 0
[2019-02-11 15:27:44] VERBOSE[12951][C-00000002] pbx.c: Executing [[email protected]:6] Hangup("PJSIP/103-00000001", "") in new stack
[2019-02-11 15:27:44] VERBOSE[12951][C-00000002] app_macro.c: Spawn extension (macro-hangupcall, s, 6) exited non-zero on 'PJSIP/103-00000001' in macro 'hangupcall'
[2019-02-11 15:27:44] VERBOSE[12951][C-00000002] pbx.c: Spawn extension (from-internal, h, 1) exited non-zero on 'PJSIP/103-00000001'

I can use your script to toggle it off manually.

But I cannot use the feature code like normal.

Did you try to enable *76 and test again? Also try *76 as well.

Do you have custom dialplan in place for *79? What is the output of:

asterisk -x 'dialplan show *[email protected]'
1 Like

I did not intentionally have a custom dial plan.

That’s the key… Looks like something broke with FOP2.

Thanks for helping figure out where the problem was.

[email protected] html]$ sudo asterisk -x 'dialplan show *[email protected]'
[sudo] password for jbusch: 
[ Included context 'app-dnd-off' created by 'pbx_config' ]
  '*79' =>          1. Macro(user-callerid,)                      [extensions_override_fop2.conf:189]
                    2. Set(CHAN=${CUT(CHANNEL,-,1)})              [extensions_override_fop2.conf:191]
                    3. dbDel(fop2state/${CHAN})                   [extensions_override_fop2.conf:192]
                    4. UserEvent(FOP2ASTDB,Family: fop2state,Channel: ${CHAN},Value: ) [extensions_override_fop2.conf:193]
                    5. Set(CONNECTEDLINE(name-charset,i)=utf8)    [extensions_override_fop2.conf:195]
                    6. Set(CONNECTEDLINE(name,i)=Do Not Disturb: OFF) [extensions_override_fop2.conf:196]
                    7. Set(CONNECTEDLINE(num,i)=${AMPUSER})       [extensions_override_fop2.conf:197]
                    8. Answer()                                   [extensions_override_fop2.conf:198]
                    9. Wait(1)                                    [extensions_override_fop2.conf:199]
                    10. Noop(Deleting: DND/${AMPUSER} ${DB_DELETE(DND/${AMPUSER})}) [extensions_override_fop2.conf:200]
                    11. Set(STATE=NOT_INUSE)                      [extensions_override_fop2.conf:201]
                    12. Gosub(app-dnd-off,sstate,1())             [extensions_override_fop2.conf:202]
     [hook_1]       13. Playback(do-not-disturb&de-activated)     [extensions_override_fop2.conf:203]
                    14. Macro(hangupcall,)                        [extensions_override_fop2.conf:204]

-= 1 extension (14 priorities) in 1 context. =-
[[email protected] html]$ 
1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.