Asterisk fails the call

Hello. Such a problem: When calling an extension, it writes “dial_exec_full: Dial-up takes format (technology / resource)” and drops the call. This is with the value of exten => _XXX, 1, Dial (SIP / $ {EXTEN}), but with the value of exten => 102.1, Dial (SIP / 102) the call passes normally. What could be wrong? Ubuntu 18 LTS, Asterisk 16 LTS

if exten => _XXX,1,Dial(SIP/${EXTEN})

[Mar  1 03:38:48] NOTICE[10011]: app_queue.c:9096 reload_queue_rules: queuerules.conf has not changed since it was last loaded. Not taking any action.
 Reloading unistim.conf...
  == Using SIP RTP CoS mark 5
       > 0x7f9f90031d40 -- Strict RTP learning after remote address set to: 192.168.51.88:11808
    -- Executing [102@call-out:1] Dial("SIP/100-0000000d", "SIP/") in new stack
[Mar  1 03:38:52] WARNING[10021][C-0000000f]: app_dial.c:2449 dial_exec_full: Dial argument takes format (technology/resource)
  == Spawn extension (call-out, 102, 1) exited non-zero on 'SIP/100-0000000d'
if exten => 102,1,Dial(SIP/102)

Using SIP RTP CoS mark 5
       > 0x7f9f90031d40 -- Strict RTP learning after remote address set to: 192.168.51.88:11812
    -- Executing [102@call-out:1] Dial("SIP/100-0000000f", "SIP/102") in new stack
  == Using SIP RTP CoS mark 5
    -- Called SIP/102
    -- SIP/102-00000010 is ringing
  == Spawn extension (call-out, 102, 1) exited non-zero on 'SIP/100-0000000f'
sip.conf

[general]
srvlookup=yes 
externaddr=192.168.51.77:5060
defaultexpiry=360
allowguest=no
language=ru
bindaddr=0.0.0.0
disallow=all
allow=alaw
allow=ulaw
allow=g729
allow=g723
allow=g722
allowoverlap=no
tcpenable=no
limitonpeers=yes

[authentication]
[numbers](!)
type=friend
context=call-out
secret=123
host=dynamic
nat=no
qualify=yes
canreinvite=no
callgroup=1
pickupgroup=1
call-limit=1
dtmfmode=auto
disallow=all
allow=alaw
allow=ulaw
allow=g729
allow=g723
allow=g722

[100](numbers)
callerid=»nomber 100<100>
[101](numbers)
callerid=»nomber 101<101>
[102](numbers)
callerid=»nomber 102<102>
extensions.conf

[general]
static=yes
writeprotect=no
[globals]
[default]

[call-out]
exten => _XXX,1,Dial(SIP/${EXTEN})

It is behaving as though ${EXTEN} was undefined. I’d check for strange characterss.

may you run an Noop(${EXTEN}) before the dial() app ?

= Using SIP RTP CoS mark 5
> 0x7f750c05fdf0 – Strict RTP learning after remote address set to: 192.168.51.88:12228
– Executing [101@call-out:1] NoOp(“SIP/100-00000004”, “SIP/”) in new stack
– Auto fallthrough, channel ‘SIP/100-00000004’ status is ‘UNKNOWN’

Apart from a hardware failure in the processor or memory, the only explanation I have is that you have spelt EXTEN incorrectly.

it shouldn’t that SIP/ portion If you ran Noop( ${EXTEN})

I think they just replaced Dial with Noop, rather than adding a Noop to debug the “variable” value.

(Note that EXTEN is really a built-in function, even though it is described as and has the syntax of a variable. You cannot actually set it, it actually reads the internal value of the extension, form the channel That’s why only getting the name wrong or a machine fault would cause it not to be expanded to the same value as that before the @ in the logs.)