Freepbx 14 and Cisco 7940, how can I record calls

Hellow, I have Freepbx 14, asterisk 13,
I read all documentation, but my calls can’t writing.
I can call to any phones, I register phones with pjsip,
But when i write extensions for my pjsip endpoints, phones when i call do not use extensions(Application->Extensions).
I should record calls, but my calls use only Asterisk.
I need any help.

CDR Report
Tue, Jan 1 2008 11:21 PM CHAN_START necto.random3 505 DEFAULT 507 default PJSIP/505-00000004
Tue, Jan 1 2008 11:21 PM CHAN_START DEFAULT s default PJSIP/507-00000005
Tue, Jan 1 2008 11:21 PM ANSWER 507 DEFAULT 507 default AppDial PJSIP/507-00000005
Tue, Jan 1 2008 11:21 PM ANSWER necto.random3 505 505 507 DEFAULT 507 default Dial PJSIP/505-00000004
Tue, Jan 1 2008 11:21 PM BRIDGE_ENTER 507 DEFAULT default AppDial PJSIP/507-00000005
Tue, Jan 1 2008 11:21 PM BRIDGE_ENTER necto.random3 505 505 507 DEFAULT 507 default Dial PJSIP/505-00000004
Tue, Jan 1 2008 11:21 PM BRIDGE_EXIT 507 DEFAULT default AppDial PJSIP/507-00000005
Tue, Jan 1 2008 11:21 PM HANGUP 507 DEFAULT default AppDial PJSIP/507-00000005
Tue, Jan 1 2008 11:21 PM BRIDGE_EXIT necto.random3 505 505 507 DEFAULT 507 default Dial PJSIP/505-00000004
Tue, Jan 1 2008 11:21 PM CHAN_END 507 DEFAULT default AppDial PJSIP/507-00000005
Tue, Jan 1 2008 11:21 PM HANGUP necto.random3 505 505 507 DEFAULT h default PJSIP/505-00000004
Tue, Jan 1 2008 11:21 PM CHAN_END necto.random3 505 505 507 DEFAULT h default PJSIP/505-00000004
Tue, Jan 1 2008 11:21 PM LINKEDID_END necto.random3 505 505 507 DEFAULT h default PJSIP/505-00000004

I add
exten => _XXX,1,Macro(user-callerid,SKIPTTL,)
exten => _XXX,2,Gosub(sub-record-check,s,1(out,${EXTEN},))
exten => _XXX,3,Dial(PJSIP/${EXTEN}

I got

[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:1] Set("PJSIP/505-0000000c", "TOUCH_MONITOR=1199222200.12") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:2] Set("PJSIP/505-0000000c", "AMPUSER=505") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:3] GotoIf("PJSIP/505-0000000c", "0?report") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:4] ExecIf("PJSIP/505-0000000c", "1?Set(REALCALLERIDNUM=505)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:5] Set("PJSIP/505-0000000c", "AMPUSER=") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:6] GotoIf("PJSIP/505-0000000c", "0?limit") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:7] Set("PJSIP/505-0000000c", "AMPUSERCIDNAME=") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:8] ExecIf("PJSIP/505-0000000c", "0?Set(__CIDMASQUERADING=TRUE)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:9] GotoIf("PJSIP/505-0000000c", "1?report") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (macro-user-callerid,s,16)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:16] NoOp("PJSIP/505-0000000c", "Macro Depth is 1") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:17] GotoIf("PJSIP/505-0000000c", "1?report2:macroerror") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (macro-user-callerid,s,18)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:18] GotoIf("PJSIP/505-0000000c", "1?continue") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (macro-user-callerid,s,37)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:37] Set("PJSIP/505-0000000c", "CALLERID(number)=505") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:38] Set("PJSIP/505-0000000c", "CALLERID(name)=necto.random3") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:39] GotoIf("PJSIP/505-0000000c", "0?cnum") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:40] Set("PJSIP/505-0000000c", "CDR(cnam)=necto.random3") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:41] Set("PJSIP/505-0000000c", "CDR(cnum)=505") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-user-callerid:42] Set("PJSIP/505-0000000c", "CHANNEL(language)=en") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [507@default:2] Gosub("PJSIP/505-0000000c", "sub-record-check,s,1(out,507,)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:1] GotoIf("PJSIP/505-0000000c", "0?initialized") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:2] Set("PJSIP/505-0000000c", "__REC_STATUS=INITIALIZED") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:3] Set("PJSIP/505-0000000c", "NOW=1199222200") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:4] Set("PJSIP/505-0000000c", "__DAY=01") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:5] Set("PJSIP/505-0000000c", "__MONTH=01") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:6] Set("PJSIP/505-0000000c", "__YEAR=2008") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:7] Set("PJSIP/505-0000000c", "__TIMESTR=20080101-211640") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:8] Set("PJSIP/505-0000000c", "__FROMEXTEN=505") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:9] Set("PJSIP/505-0000000c", "__MON_FMT=wav") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:10] NoOp("PJSIP/505-0000000c", "Recordings initialized") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:11] ExecIf("PJSIP/505-0000000c", "1?Set(ARG3=dontcare)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:12] Set("PJSIP/505-0000000c", "REC_POLICY_MODE_SAVE=") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:13] ExecIf("PJSIP/505-0000000c", "0?Set(REC_STATUS=NO)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:14] GotoIf("PJSIP/505-0000000c", "3?checkaction") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (sub-record-check,s,17)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [s@sub-record-check:17] GotoIf("PJSIP/505-0000000c", "1?sub-record-check,out,1") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (sub-record-check,out,1)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [out@sub-record-check:1] NoOp("PJSIP/505-0000000c", "Outbound Recording Check from 505 to 507") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [out@sub-record-check:2] Set("PJSIP/505-0000000c", "RECMODE=") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [out@sub-record-check:3] ExecIf("PJSIP/505-0000000c", "1?Goto(routewins)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (sub-record-check,out,7)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [out@sub-record-check:7] Gosub("PJSIP/505-0000000c", "recordcheck,1(dontcare,out,507)") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [recordcheck@sub-record-check:1] NoOp("PJSIP/505-0000000c", "Starting recording check against dontcare") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [recordcheck@sub-record-check:2] Goto("PJSIP/505-0000000c", "dontcare") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (sub-record-check,recordcheck,3)
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [recordcheck@sub-record-check:3] Return("PJSIP/505-0000000c", "") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [out@sub-record-check:8] Return("PJSIP/505-0000000c", "") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] pbx.c: Executing [507@default:3] Dial("PJSIP/505-0000000c", "PJSIP/507") in new stack
[2008-01-01 21:16:40] VERBOSE[7445][C-00000006] app_dial.c: Called PJSIP/507
[2008-01-01 21:16:41] VERBOSE[7445][C-00000006] app_dial.c: PJSIP/507-0000000d is ringing
[2008-01-01 21:16:42] VERBOSE[7445][C-00000006] app_dial.c: PJSIP/507-0000000d answered PJSIP/505-0000000c
[2008-01-01 21:16:42] VERBOSE[7448][C-00000006] bridge_channel.c: Channel PJSIP/507-0000000d joined 'simple_bridge' basic-bridge <0f16be77-2258-4b42-b707-5a7b13f04add>
[2008-01-01 21:16:42] VERBOSE[7445][C-00000006] bridge_channel.c: Channel PJSIP/505-0000000c joined 'simple_bridge' basic-bridge <0f16be77-2258-4b42-b707-5a7b13f04add>
[2008-01-01 21:16:44] VERBOSE[7448][C-00000006] bridge_channel.c: Channel PJSIP/507-0000000d left 'simple_bridge' basic-bridge <0f16be77-2258-4b42-b707-5a7b13f04add>
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] bridge_channel.c: Channel PJSIP/505-0000000c left 'simple_bridge' basic-bridge <0f16be77-2258-4b42-b707-5a7b13f04add>
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Spawn extension (default, 507, 3) exited non-zero on 'PJSIP/505-0000000c'
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Executing [h@default:1] Macro("PJSIP/505-0000000c", "hangupcall,") in new stack
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-hangupcall:1] GotoIf("PJSIP/505-0000000c", "1?theend") in new stack
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx_builtins.c: Goto (macro-hangupcall,s,3)
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-hangupcall:3] ExecIf("PJSIP/505-0000000c", "0?Set(CDR(recordingfile)=)") in new stack
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-hangupcall:4] NoOp("PJSIP/505-0000000c", "PJSIP/507-0000000d monior file= ") in new stack
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-hangupcall:5] AGI("PJSIP/505-0000000c", "attendedtransfer-rec-restart.php,PJSIP/507-0000000d,") in new stack
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] res_agi.c: Launched AGI Script /var/lib/asterisk/agi-bin/attendedtransfer-rec-restart.php
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] res_agi.c: <PJSIP/505-0000000c>AGI Script attendedtransfer-rec-restart.php completed, returning 0
[2008-01-01 21:16:44] VERBOSE[7445][C-00000006] pbx.c: Executing [s@macro-hangupcall:6] Hangup("PJSIP/505-0000000c", "") in new stack

I have a little trouble understanding what you did.

Did you set call recording to “Yes” in the extension settings?


But my calls do not use Extensions calls use pjsip_custom when i do calls

[general] 
tcpenable=yes 
transport=tcp 
context=default 
allowguest=no 
bindport=5060 
bindaddr=0.0.0.0 
srvlookup=no 
tos=0xb8 
[507]
type=endpoint
context=default
disallow=all
allow=alaw
allow=ulaw
allow=g729
force_rport=no
identify_by=username
outbound_auth=auth507
aors=507
[507]
type=aor
qualify_frequency=60
contact=sip:[email protected]
max_contacts=10
[auth507]
auth_type=userpass
password='password'
username='507'
[507]
type=identify
endpoint=507
match=10.5.0.11
[502]
type=endpoint
context=default
disallow=all
allow=alaw
allow=ulaw
allow=g729
force_rport=no
identify_by=username
outbound_auth=auth502
aors=502
[502]
type=aor
qualify_frequency=60
contact=sip:[email protected]
max_contacts=10
[auth502]
auth_type=userpass
password='password'
username='502'
[502]
type=identify
endpoint=502
match=10.5.0.12
[505]
type=endpoint
context=default
disallow=all
allow=alaw
allow=ulaw
allow=g729
force_rport=no
identify_by=username
outbound_auth=auth505
aors=505
[505]
type=aor
qualify_frequency=60
contact=sip:[email protected]
max_contacts=10
[auth505]
auth_type=userpass
password='password'
username='505'
[505]
type=identify
endpoint=505
match=10.5.0.13

I make it, record work

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