[Home]

Summary:ASTERISK-17183: Multiple Parking Lots Being Redirected to the Wrong Parking Lot
Reporter:David Cabrejos (drcabrejos)Labels:
Date Opened:2010-12-29 17:26:31.000-0600Date Closed:2011-08-16 12:31:07
Priority:MajorRegression?
Status:Closed/CompleteComponents:Features/Parking
Versions:1.8.5.0 Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) diff.txt
( 1) diff.txt
( 2) extensions.include
( 3) extensions.include.simple
( 4) features.diff
Description:When creating multiple parking lots, users from parking lot A, B, or C are being parked on parking lot Z (parking lot at the top of 'parkedcalls show').

In my scenario, 3 tenants are created. 2 extensions are created for each tenant.
Cabrejos, thirdlane, and David are the tenants.

features.conf, extensions.include and sip.conf are on Additional Info.


When dialing "700" for parking lot from David, the following is displayed on asterisk:

== Using UDPTL TOS bits 184
== Using UDPTL CoS mark 5
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
-- Executing [700@from-inside-David:1] Macro("SIP/102-David-0000000d", "tl-set-variables2,from-inside-redir-David,David") in new stack
-- Executing [s@macro-tl-set-variables2:1] Set("SIP/102-David-0000000d", "__tenant=David") in new stack
-- Executing [s@macro-tl-set-variables2:2] Set("SIP/102-David-0000000d", "CDR(userfield)=David") in new stack
-- Executing [s@macro-tl-set-variables2:3] Set("SIP/102-David-0000000d", "__FROM_INSIDE=1") in new stack
-- Executing [s@macro-tl-set-variables2:4] Set("SIP/102-David-0000000d", "__MOH=default-David") in new stack
-- Executing [s@macro-tl-set-variables2:5] GotoIf("SIP/102-David-0000000d", "1 ?setmoh") in new stack
-- Goto (macro-tl-set-variables2,s,7)
-- Executing [s@macro-tl-set-variables2:7] Set("SIP/102-David-0000000d", "CHANNEL(musicclass)=default-David") in new stack
[2010-12-23 14:57:42] NOTICE[7770]: chan_sip.c:4034 sip_setoption: Unknown option: 9
-- Executing [s@macro-tl-set-variables2:8] Goto("SIP/102-David-0000000d", "from-inside-redir-David,700,1") in new stack
-- Goto (from-inside-redir-David,700,1)
== Channel 'SIP/102-David-0000000d' jumping out of macro 'tl-set-variables2'
-- Executing [700@from-inside-redir-David:1] Park("SIP/102-David-0000000d", "") in new stack
== Parked SIP/102-David-0000000d on 701 (lot default). Will timeout back to extension [from-inside-redir-David] s, 1 in 180 seconds
-- Added extension '701' priority 1 to parkedcalls
-- Playing 'digits/7.gsm' (language 'en')
-- Playing 'digits/0.gsm' (language 'en')
-- Playing 'digits/1.gsm' (language 'en')
-- Started music on hold, class 'default-David', on SIP/102-David-0000000d
== Spawn extension (from-inside-redir-David, s, 1) exited non-zero on 'Parked/SIP/102-David-0000000d'
-- Executing [h@from-inside-redir-David:1] Hangup("Parked/SIP/102-David-0000000d", "") in new stack
== Spawn extension (from-inside-redir-David, h, 1) exited non-zero on 'Parked/SIP/102-David-0000000d'
[2010-12-23 14:57:57] WARNING[2414]: chan_sip.c:3618 __sip_autodestruct: Autodestruct on dialog 'NGNiMmRiY2M4YWU5NjNiMDYxMTY3NWJmN2YyM2EzNWI.' with owner in place (Method: BYE)


Issuing "parkedcalls show" command:

thirdlane*CLI> parkedcalls show
Num Channel (Context Extension Pri ) Timeout
*** Parking lot: default (7)
701 SIP/102-David-0000000d (from-inside-redir-David s 1 ) 160s
*** Parking lot: parkinglot_Cabrejos (0)
*** Parking lot: parkinglot_thirdlane (0)
*** Parking lot: parkinglot_David (0)
---
1 parked call in total.


If calling extension "701", where call was parked, this output is acquired:

== Using UDPTL TOS bits 184
== Using UDPTL CoS mark 5
== Using SIP RTP TOS bits 184
== Using SIP RTP CoS mark 5
-- Executing [701@from-inside-David:1] Macro("SIP/102-David-0000000e", "tl-set-variables2,from-inside-redir-David,David") in new stack
-- Executing [s@macro-tl-set-variables2:1] Set("SIP/102-David-0000000e", "__tenant=David") in new stack
-- Executing [s@macro-tl-set-variables2:2] Set("SIP/102-David-0000000e", "CDR(userfield)=David") in new stack
-- Executing [s@macro-tl-set-variables2:3] Set("SIP/102-David-0000000e", "__FROM_INSIDE=1") in new stack
-- Executing [s@macro-tl-set-variables2:4] Set("SIP/102-David-0000000e", "__MOH=default-David") in new stack
-- Executing [s@macro-tl-set-variables2:5] GotoIf("SIP/102-David-0000000e", "1 ?setmoh") in new stack
-- Goto (macro-tl-set-variables2,s,7)
-- Executing [s@macro-tl-set-variables2:7] Set("SIP/102-David-0000000e", "CHANNEL(musicclass)=default-David") in new stack
[2010-12-23 15:00:16] NOTICE[8040]: chan_sip.c:4034 sip_setoption: Unknown option: 9
-- Executing [s@macro-tl-set-variables2:8] Goto("SIP/102-David-0000000e", "from-inside-redir-David,701,1") in new stack
-- Goto (from-inside-redir-David,701,1)
== Channel 'SIP/102-David-0000000e' jumping out of macro 'tl-set-variables2'
-- Sent into invalid extension '701' in context 'from-inside-redir-David' on SIP/102-David-0000000e
-- Executing [i@from-inside-redir-David:1] Playback("SIP/102-David-0000000e", "invalid") in new stack
-- Playing 'invalid.gsm' (language 'en')
-- Executing [i@from-inside-redir-David:2] Hangup("SIP/102-David-0000000e", "") in new stack
== Spawn extension (from-inside-redir-David, i, 2) exited non-zero on 'SIP/102-David-0000000e'
-- Executing [h@from-inside-redir-David:1] Hangup("SIP/102-David-0000000e", "") in new stack
== Spawn extension (from-inside-redir-David, h, 1) exited non-zero on 'SIP/102-David-0000000e'

Notice how it parked the call on 'parkedcalls' ("default" parking lot), instead of 'parkedcalls-David' ("parkinglot_David").

Tested functionality on the following versions using a clean config:
1.6.1.20 - Works
1.6.2.13 - Doesn't Work
1.6.2.14 - Works
1.6.2.15 - Works
1.8.0 - Doesn't Work
1.8.1.1 - Doesn't Work
1.8.2-rc1 - Doesn't Work

Have also testing using all lower case letters on the tenants and extensions with the same results.

Let me know if any additional information is required.

Thank you,

David Cabrejos

****** ADDITIONAL INFORMATION ******

EXTENSIONS.INCLUDE

[feature-extensions-thirdlane]

exten => *41,1,Macro(tl-directory,default,from-inside-thirdlane) ; Company directory, dial by name
exten => *51,1,Macro(tl-web-record) ; Voice Prompt recording using web callback
exten => *72,1,Macro(tl-callforward-prompt,CFA) ; Call Forward Always Activation
exten => *73,1,Macro(tl-cancelforward-prompt,CFA) ; Call Forward Always Deactivation
exten => _*73.,1,Macro(tl-cancelforward-dialed,CFA) ; Call Forward Always Deactivation
exten => _*8X,1,Macro(tl-pickupgroup-pickup,2) ; Pickup call in Pickup Group
exten => _*8X.,1,Macro(tl-directed-call-pickup,2) ; Pick up call on direct extension
exten => *90,1,Macro(tl-callforward-prompt,CFB) ; Call Forward Busy Activation
exten => *91,1,Macro(tl-cancelforward-prompt,CFB) ; Call Forward Busy Deactivation
exten => _*91.,1,Macro(tl-cancelforward-dialed,CFB) ; Call Forward Busy Deactivation
exten => *92,1,Macro(tl-callforward-prompt,CFNA) ; Call Forward No Answer Activation
exten => *93,1,Macro(tl-cancelforward-prompt,CFNA) ; Call Forward No Answer Deactivation
exten => _*93.,1,Macro(tl-cancelforward-dialed,CFNA) ; Call Forward No Answer Deactivation
exten => *96,1,Macro(tl-check-callforward) ; Call Forwarding status for caller's phone
exten => _*98!,1,Macro(tl-check-voicemail) ; Check Voice Mail

exten => _*99.,1,Macro(tl-intercom,3) ; Phone intercom

exten => 601,1,Macro(tl-menu,tl-main-menu-open-thirdlane) ; Sample extension to go to a voice menu
exten => 602,1,Macro(tl-music-on-hold) ; Sample extension for testing of default music-on-hold
exten => 603,1,Macro(tl-dialconference-prompted,,) ; Sample extension to prompt for and go to a conference room
exten => 604,1,Macro(tl-set-daynight,12345) ; Sample extension to set Day/Night Mode

[local-extensions-thirdlane]
exten => 701,hint,park:701@parkedcalls-thirdlane ;;=Asterisk-1.6
exten => 702,hint,park:702@parkedcalls-thirdlane ;;=Asterisk-1.6
exten => 703,hint,park:703@parkedcalls-thirdlane ;;=Asterisk-1.6
exten => 704,hint,park:704@parkedcalls-thirdlane ;;=Asterisk-1.6


[agent-extensions-thirdlane]

exten => _X.,1,Set(__RINGGROUP_TIMEOUT=60)
exten => _X.,n,Goto(from-inside-thirdlane,${EXTEN},1)

[from-inside-thirdlane]

exten => _X,1,Macro(tl-set-variables2,from-inside-redir-thirdlane,thirdlane)
exten => _*.,1,Macro(tl-set-variables2,from-inside-redir-thirdlane,thirdlane)
exten => _#.,1,Macro(tl-set-variables2,from-inside-redir-thirdlane,thirdlane)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-redir-thirdlane,thirdlane)
exten => _X.,1,Macro(tl-set-variables2,from-inside-redir-thirdlane,thirdlane)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-redir-thirdlane,thirdlane)

[from-inside-restricted-thirdlane]
exten => _X,1,Macro(tl-set-variables2,from-inside-restricted-redir-thirdlane,thirdlane)
exten => _*.,1,Macro(tl-set-variables2,from-inside-restricted-redir-thirdlane,thirdlane)
exten => _#.,1,Macro(tl-set-variables2,from-inside-restricted-redir-thirdlane,)thirdlane
exten => _%23.,1,Macro(tl-set-variables2,from-inside-restricted-redir-thirdlane,thirdlane)
exten => _X.,1,Macro(tl-set-variables2,from-inside-restricted-redir-thirdlane,thirdlane)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-restricted-redir-thirdlane,thirdlane)

[from-inside-internal-thirdlane]
exten => _X,1,Macro(tl-set-variables2,from-inside-internal-redir-thirdlane,thirdlane)
exten => _*.,1,Macro(tl-set-variables2,from-inside-internal-redir-thirdlane,thirdlane)
exten => _#.,1,Macro(tl-set-variables2,from-inside-internal-redir-thirdlane,thirdlane)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-internal-redir-thirdlane,thirdlane)
exten => _X.,1,Macro(tl-set-variables2,from-inside-internal-redir-thirdlane,thirdlane)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-internal-redir-thirdlane,thirdlane)

[from-inside-redir-thirdlane]
include => local-extensions-thirdlane
include => feature-extensions-thirdlane
include => outgoing-thirdlane
include => parkedcalls-thirdlane  ;;=Asterisk-1.6
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,2,Hangup

[from-inside-redir-restricted-thirdlane]
include => local-extensions-thirdlane
include => feature-extensions-thirdlane
include => outgoing-unrestricted-thirdlane
include => parkedcalls-thirdlane ;;=Asterisk-1.6

exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,2,Hangup

[from-inside-redir-internal-thirdlane]
include => local-extensions-thirdlane
include => feature-extensions-thirdlane
include => outgoing-emergency-thirdlane
include => parkedcalls-thirdlane ;;=Asterisk-1.6

exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,2,Hangup




[local-extensions-David]
exten => 701,hint,park:701@parkedcalls-David
exten => 702,hint,park:702@parkedcalls-David
exten => 703,hint,park:703@parkedcalls-David
exten => 704,hint,park:704@parkedcalls-David

exten => 101,1,Macro(tl-userexten,SIP/101-David,101@default-David,)
exten => 101,hint,SIP/101-David
exten => 102,1,Macro(tl-userexten,SIP/102-David,102@default-David)
exten => 102,hint,SIP/102-David
[agent-extensions-David]

exten => _X.,1,Set(__RINGGROUP_TIMEOUT=60)
exten => _X.,n,Goto(from-inside-David,${EXTEN},1)

[feature-extensions-David]

exten => *41,1,Macro(tl-directory,default,from-inside-David) ; Company directory, dial by name
exten => *51,1,Macro(tl-web-record) ; Voice Prompt recording using web callback
exten => *72,1,Macro(tl-callforward-prompt,CFA) ; Call Forward Always Activation
exten => *73,1,Macro(tl-cancelforward-prompt,CFA) ; Call Forward Always Deactivation
exten => _*73.,1,Macro(tl-cancelforward-dialed,CFA) ; Call Forward Always Deactivation
exten => _*8X,1,Macro(tl-pickupgroup-pickup,2) ; Pickup call in Pickup Group
exten => _*8X.,1,Macro(tl-directed-call-pickup,2) ; Pick up call on direct extension
exten => *90,1,Macro(tl-callforward-prompt,CFB) ; Call Forward Busy Activation
exten => *91,1,Macro(tl-cancelforward-prompt,CFB) ; Call Forward Busy Deactivation
exten => _*91.,1,Macro(tl-cancelforward-dialed,CFB) ; Call Forward Busy Deactivation
exten => *92,1,Macro(tl-callforward-prompt,CFNA) ; Call Forward No Answer Activation
exten => *93,1,Macro(tl-cancelforward-prompt,CFNA) ; Call Forward No Answer Deactivation
exten => _*93.,1,Macro(tl-cancelforward-dialed,CFNA) ; Call Forward No Answer Deactivation
exten => *96,1,Macro(tl-check-callforward) ; Call Forwarding status for caller's phone
exten => _*98!,1,Macro(tl-check-voicemail) ; Check Voice Mail

exten => _*99.,1,Macro(tl-intercom,3) ; Phone intercom

exten => 601,1,Macro(tl-menu,tl-main-menu-open-David) ; Sample extension to go to a voice menu
exten => 602,1,Macro(tl-music-on-hold) ; Sample extension for testing of default music-on-hold
exten => 603,1,Macro(tl-dialconference-prompted,,) ; Sample extension to prompt for and go to a conference room
exten => 604,1,Macro(tl-set-daynight,12345) ; Sample extension to set Day/Night Mode


[from-inside-David]
exten => _X,1,Macro(tl-set-variables2,from-inside-redir-David,David)
exten => _*.,1,Macro(tl-set-variables2,from-inside-redir-David,David)
exten => _#.,1,Macro(tl-set-variables2,from-inside-redir-David,David)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-redir-David,David)
exten => _X.,1,Macro(tl-set-variables2,from-inside-redir-David,David)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-redir-David,David)

[from-inside-redir-David]
include => local-extensions-David
include => feature-extensions-David
include => outgoing-emergency-David
include => outgoing-unrestricted-David
include => outgoing-David
include => parkedcalls-David
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,n,Hangup

[from-inside-restricted-David]
exten => _X,1,Macro(tl-set-variables2,from-inside-restricted-redir-David,David)
exten => _*.,1,Macro(tl-set-variables2,from-inside-restricted-redir-David,David)
exten => _#.,1,Macro(tl-set-variables2,from-inside-restricted-redir-David,David)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-restricted-redir-David,David)
exten => _X.,1,Macro(tl-set-variables2,from-inside-restricted-redir-David,David)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-restricted-redir-David,David)

[from-inside-restricted-redir-David]
include => local-extensions-David
include => feature-extensions-David
include => outgoing-emergency-David
include => outgoing-unrestricted-David
include => parkedcalls-David
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,n,Hangup

[from-inside-internal-David]
exten => _X,1,Macro(tl-set-variables2,from-inside-internal-redir-David,David)
exten => _*.,1,Macro(tl-set-variables2,from-inside-internal-redir-David,David)
exten => _#.,1,Macro(tl-set-variables2,from-inside-internal-redir-David,David)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-internal-redir-David,David)
exten => _X.,1,Macro(tl-set-variables2,from-inside-internal-redir-David,David)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-internal-redir-David,David)

[from-inside-internal-redir-David]
include => local-extensions-David
include => feature-extensions-David
include => outgoing-emergency-David
include => parkedcalls-David
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,n,Hangup


[local-extensions-Cabrejos]
exten => 701,hint,park:701@parkedcalls-Cabrejos
exten => 702,hint,park:702@parkedcalls-Cabrejos
exten => 703,hint,park:703@parkedcalls-Cabrejos
exten => 704,hint,park:704@parkedcalls-Cabrejos

exten => 101,1,Macro(tl-userexten,SIP/101-Cabrejos,101@default-Cabrejos)
exten => 101,hint,SIP/101-Cabrejos
exten => 102,1,Macro(tl-userexten,SIP/102-Cabrejos,102@default-Cabrejos)
exten => 102,hint,SIP/102-Cabrejos
[agent-extensions-Cabrejos]

exten => _X.,1,Set(__RINGGROUP_TIMEOUT=60)
exten => _X.,n,Goto(from-inside-Cabrejos,${EXTEN},1)

[feature-extensions-Cabrejos]

exten => *41,1,Macro(tl-directory,default,from-inside-Cabrejos) ; Company directory, dial by name
exten => *51,1,Macro(tl-web-record) ; Voice Prompt recording using web callback
exten => *72,1,Macro(tl-callforward-prompt,CFA) ; Call Forward Always Activation
exten => *73,1,Macro(tl-cancelforward-prompt,CFA) ; Call Forward Always Deactivation
exten => _*73.,1,Macro(tl-cancelforward-dialed,CFA) ; Call Forward Always Deactivation
exten => _*8X,1,Macro(tl-pickupgroup-pickup,2) ; Pickup call in Pickup Group
exten => _*8X.,1,Macro(tl-directed-call-pickup,2) ; Pick up call on direct extension
exten => *90,1,Macro(tl-callforward-prompt,CFB) ; Call Forward Busy Activation
exten => *91,1,Macro(tl-cancelforward-prompt,CFB) ; Call Forward Busy Deactivation
exten => _*91.,1,Macro(tl-cancelforward-dialed,CFB) ; Call Forward Busy Deactivation
exten => *92,1,Macro(tl-callforward-prompt,CFNA) ; Call Forward No Answer Activation
exten => *93,1,Macro(tl-cancelforward-prompt,CFNA) ; Call Forward No Answer Deactivation
exten => _*93.,1,Macro(tl-cancelforward-dialed,CFNA) ; Call Forward No Answer Deactivation
exten => *96,1,Macro(tl-check-callforward) ; Call Forwarding status for caller's phone
exten => _*98!,1,Macro(tl-check-voicemail) ; Check Voice Mail

exten => _*99.,1,Macro(tl-intercom,3) ; Phone intercom

exten => 601,1,Macro(tl-menu,tl-main-menu-open-Cabrejos) ; Sample extension to go to a voice menu
exten => 602,1,Macro(tl-music-on-hold) ; Sample extension for testing of default music-on-hold
exten => 603,1,Macro(tl-dialconference-prompted,,) ; Sample extension to prompt for and go to a conference room
exten => 604,1,Macro(tl-set-daynight,12345) ; Sample extension to set Day/Night Mode


[from-inside-Cabrejos]
exten => _X,1,Macro(tl-set-variables2,from-inside-redir-Cabrejos,Cabrejos)
exten => _*.,1,Macro(tl-set-variables2,from-inside-redir-Cabrejos,Cabrejos)
exten => _#.,1,Macro(tl-set-variables2,from-inside-redir-Cabrejos,Cabrejos)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-redir-Cabrejos,Cabrejos)
exten => _X.,1,Macro(tl-set-variables2,from-inside-redir-Cabrejos,Cabrejos)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-redir-Cabrejos,Cabrejos)

[from-inside-redir-Cabrejos]
include => local-extensions-Cabrejos
include => feature-extensions-Cabrejos
include => outgoing-emergency-Cabrejos
include => outgoing-unrestricted-Cabrejos
include => outgoing-Cabrejos
include => parkedcalls-Cabrejos
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,n,Hangup

[from-inside-restricted-Cabrejos]
exten => _X,1,Macro(tl-set-variables2,from-inside-restricted-redir-Cabrejos,Cabrejos)
exten => _*.,1,Macro(tl-set-variables2,from-inside-restricted-redir-Cabrejos,Cabrejos)
exten => _#.,1,Macro(tl-set-variables2,from-inside-restricted-redir-Cabrejos,Cabrejos)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-restricted-redir-Cabrejos,Cabrejos)
exten => _X.,1,Macro(tl-set-variables2,from-inside-restricted-redir-Cabrejos,Cabrejos)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-restricted-redir-Cabrejos,Cabrejos)

[from-inside-restricted-redir-Cabrejos]
include => local-extensions-Cabrejos
include => feature-extensions-Cabrejos
include => outgoing-emergency-Cabrejos
include => outgoing-unrestricted-Cabrejos
include => parkedcalls-Cabrejos
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,n,Hangup

[from-inside-internal-Cabrejos]
exten => _X,1,Macro(tl-set-variables2,from-inside-internal-redir-Cabrejos,Cabrejos)
exten => _*.,1,Macro(tl-set-variables2,from-inside-internal-redir-Cabrejos,Cabrejos)
exten => _#.,1,Macro(tl-set-variables2,from-inside-internal-redir-Cabrejos,Cabrejos)
exten => _%23.,1,Macro(tl-set-variables2,from-inside-internal-redir-Cabrejos,Cabrejos)
exten => _X.,1,Macro(tl-set-variables2,from-inside-internal-redir-Cabrejos,Cabrejos)
exten => _+X.,1,Macro(tl-set-variables2,from-inside-internal-redir-Cabrejos,Cabrejos)

[from-inside-internal-redir-Cabrejos]
include => local-extensions-Cabrejos
include => feature-extensions-Cabrejos
include => outgoing-emergency-Cabrejos
include => parkedcalls-Cabrejos
exten => t,1,Hangup
exten => h,1,Hangup
exten => i,1,Playback(invalid)
exten => i,n,Hangup


FEATURES.CONF

[general]
parkext => 700 ; What extension to dial to park
parkpos => 701-704 ; What extensions to park calls on. These needs to be
; numeric, as Asterisk starts from the start position
; and increments with one for the next parked call.
context => parkedcalls ; Which context parked calls are in
parkingtime => 180 ; Number of seconds a call can be parked for
; (default is 45 seconds)
transferdigittimeout => 3 ; Number of seconds to wait between digits when transfering a call
courtesytone = beep ; Sound file to play to the parked caller
; when someone dials a parked call
xfersound = beep ; to indicate an attended transfer is complete
xferfailsound = beeperr ; to indicate a failed transfer
;adsipark = yes ; if you want ADSI parking announcements
;findslot => next ; Continue to the 'next' free parking space.
; Defaults to 'first' available
pickupexten = ** ; Configure the pickup extension.  Default is *8
featuredigittimeout = 1000 ; Max time (ms) between digits for
; feature activation.  Default is 500

[featuremap]
blindxfer => ## ; Blind transfer
atxfer => #* ; Attended transfer
disconnect => #0 ; Disconnect
automon => ASTERISK-5 ; One Touch Record

[applicationmap]
; Note that the DYNAMIC_FEATURES channel variable must be set to use the features
; defined here.  The value of DYNAMIC_FEATURES should be the names of the features
; to allow the channel to use separated by '#'.  For example:
;    Set(DYNAMIC_FEATURES=myfeature1#myfeature2#myfeature3)
;
;testfeature => ASTERISK-5,callee,Playback,tt-monkeys ;Play tt-monkeys to
;callee if ASTERISK-5 was pressed

[parkinglot_thirdlane] ;;=Asterisk-1.6
context => parkedcalls-thirdlane ;;=Asterisk-1.6
parkingtime => 180 ;;=Asterisk-1.6
parkext => 700 ;;=Asterisk-1.6
parkpos => 701-704 ;;=Asterisk-1.6
findslot => next ;;=Asterisk-1.6
[parkinglot_David]
context => parkedcalls-David
parkingtime => 180
parkext => 700
parkpos => 701-704
findslot => next
[parkinglot_Cabrejos]
context => parkedcalls-Cabrejos
parkingtime => 180
parkext => 700
parkpos => 701-704
findslot => next


SIP.CONF

[general]
bindport=5060          
bindaddr=0.0.0.0  
disallow=all
allow=ulaw
allow=alaw
allowguest=no
trustrpid=yes
sendrpid=yes
callerid=unknown
context=from-outside            ; Default context for incoming calls
mohinterpret=default
useragent=Thirdlane
allowsubscribe=yes
notifyhold=yes
notifyringing=yes
callcounter=yes ;;=Asterisk-1.6
;;limitonpeer=yes ;;=Asterisk-1.4
videosupport=yes
t38pt_udptl=yes
tos_sip=cs3
tos_audio=ef
tos_video=af41
tos_text=af41 ;;=Asterisk-1.6

cos_sip=3 ;;=Asterisk-1.6
cos_audio=5 ;;=Asterisk-1.6
cos_video=4 ;;=Asterisk-1.6
cos_text=3 ;;=Asterisk-1.6

[101-David]
qualify=yes
nat=yes
pickupgroup=2
callerid=David 1 Cabrejos <101>
context=from-inside-David
canreinvite=no
vmexten=101
parkinglot=parkinglot_David
secret=xxxxxx
username=101-David
host=dynamic
subscribecontext=local-extensions-David
callgroup=2
dtmfmode=rfc2833
type=friend
mailbox=101@default-David
disallow=all
allow=ulaw
allow=alaw
allow=gsm

[102-David]
qualify=yes
pickupgroup=2
callerid=David 2 Cabrejos <102>
context=from-inside-David
call-limit=
vmexten=102
parkinglot=parkinglot_David
secret=xxxxxx
;=description=David 2 Cabrejos
host=dynamic
username=102-David
subscribecontext=local-extensions-David
callgroup=2
dtmfmode=rfc2833
type=friend
mailbox=102@default-David
disallow=all
allow=ulaw
allow=alaw
allow=gsm

[101-Cabrejos]
qualify=yes
pickupgroup=3
callerid=Lili 1 Cabrejos <101>
context=from-inside-Cabrejos
call-limit=
vmexten=101
parkinglot=parkinglot_Cabrejos
secret=xxxxxx
;=description=Lili 1 Cabrejos
host=dynamic
username=101-Cabrejos
subscribecontext=local-extensions-Cabrejos
callgroup=3
dtmfmode=rfc2833
type=friend
mailbox=101@default-Cabrejos
disallow=all
allow=ulaw
allow=alaw
allow=gsm

[102-Cabrejos]
qualify=yes
pickupgroup=3
callerid=Lili 2 Cabrejos <102>
context=from-inside-Cabrejos
call-limit=
vmexten=102
parkinglot=parkinglot_Cabrejos
secret=xxxxxx
;=description=Lili 2 Cabrejos
host=dynamic
username=102-Cabrejos
subscribecontext=local-extensions-Cabrejos
callgroup=3
dtmfmode=rfc2833
type=friend
mailbox=102@default-Cabrejos
disallow=all
allow=ulaw
allow=alaw
allow=gsm
Comments:By: Leif Madsen (lmadsen) 2011-01-04 16:22:44.000-0600

Your dialplan is huge. Is there any chance you could submit a simple dialplan that shows this behaviour for testing purposes?

By: David Cabrejos (drcabrejos) 2011-01-04 17:28:36.000-0600

Please see attached file "extensions.include" with a smaller dialplan.

By: Chris Owen (owenc67202) 2011-01-04 18:49:03.000-0600

We could also make a VM or remote logon available all configured if that helps any.

By: Leif Madsen (lmadsen) 2011-01-19 10:06:31.000-0600

This dialplan attached is still far too complicated to be followed. Please simplify.

By: Leif Madsen (lmadsen) 2011-02-07 14:19:55.000-0600

No response from reporter. Please reopen when you can provide the required information. Thanks!

By: David Cabrejos (drcabrejos) 2011-02-07 15:50:17.000-0600

Forgot to attach before a more simplified dial plan.
This is as simple as it can get.
Check attached file extensions.include.simple

By: David Cabrejos (drcabrejos) 2011-02-07 15:52:05.000-0600

Access can be given to the machine if needed for easier troubleshooting.

By: David Cabrejos (drcabrejos) 2011-02-21 11:17:49.000-0600

Any news on this issue yet?

I've already tested versions 1.8.1.x, 1.8.2.x and 1.8.3.x (including 1.8.3-RC3) as of today, and still having problems with multiple parking lots.
Version 1.6.2.x seems to be working great on the latest versions.

By: Erik Smith (eeman) 2011-06-02 20:07:37

any update on this? this is a huge problem for several customers and now that 1.6.2 and 1.4 are EOL I think there should at least be a working patch floating around or something.

By: moshe Teitelbaum (moshe) 2011-06-03 01:28:14

This is a hugh problem for me just moved to 1.8.4.1 and this is causing me quite some trouble

As eeman said " 1.6.2 and 1.4 are EOL I think there should at least be a working patch"

By: moshe Teitelbaum (moshe) 2011-06-03 15:47:30

not be rood but this is a real killer the multi parking in 1.6 is great feature and now you are ending the life of parked calls?

By: ppower (ppower) 2011-06-03 16:19:37

What I have found in the code for 1.8.2.3 call parking is that when a call is parked, it is tracked by parked slot number only, NOT by parking lot name. So, if lot A used 701-705 and lot B used 706-710 then you could use the different lots.

The other alternative is to change the parking lot code to care more about lot names than slot numbers.

By: moshe Teitelbaum (moshe) 2011-06-05 18:10:18.157-0500

ppower i have tried that  i have set up as followes


features.conf
[parkinglot_test0]
context => parkedcalls-test0
parkingtime => 180
parkext => 700
parkpos => 701-704
findslot => next

[parkinglot_test1]          
context => parkedcalls-test1
parkingtime => 180
parkext => 705    
parkpos => 706-709
findslot => next      

[parkinglot_test2]
context => parkedcalls-test2
parkingtime => 180
parkext => 710  
parkpos => 711-714
findslot => next

[parkinglot_test3]
context => parkedcalls-test3
parkingtime => 180
parkext => 715  
parkpos => 716-719
findslot => next


[parkinglot_test4]
context => parkedcalls-test4
parkingtime => 180
parkext => 720  
parkpos => 721-724
findslot => next


[root@mte1a ~]# asterisk -rx "features show"
Builtin Feature           Default Current
---------------           ------- -------
Pickup                    *8      **    
Blind Transfer            #       #1    
Attended Transfer                 #2    
One Touch Monitor                 #9    
Disconnect Call           *       #0    
Park Call                                
One Touch MixMonitor                    

Dynamic Feature           Default Current
---------------           ------- -------
(none)

Feature Groups:
---------------
(none)

Call parking (Parking lot: parkinglot_test0)
------------
Parking extension     :      700
Parking context       :      parkedcalls-test0
Parked call extensions:      701-704
Parkingtime           :      180000
MusicOnHold class     :      


Call parking (Parking lot: parkinglot_test1)
------------
Parking extension     :      705
Parking context       :      parkedcalls-test1
Parked call extensions:      706-709
Parkingtime           :      180000
MusicOnHold class     :      


Call parking (Parking lot: parkinglot_test2)
------------
Parking extension     :      710
Parking context       :      parkedcalls-test2
Parked call extensions:      711-714
Parkingtime           :      180000
MusicOnHold class     :      


Call parking (Parking lot: parkinglot_test3)
------------
Parking extension     :      715
Parking context       :      parkedcalls-test3
Parked call extensions:      716-719
Parkingtime           :      180000
MusicOnHold class     :      


Call parking (Parking lot: parkinglot_test4)
------------
Parking extension     :      720
Parking context       :      parkedcalls-test4
Parked call extensions:      721-724
Parkingtime           :      180000
MusicOnHold class     :      





however when i call from extension that in sip.conf under parkkinglot is specified to use
parkinglot=parkinglot_test1


when dialing 705 it plays invalid with cli output

   -- Executing [705@from-inside-test1:1] Macro("SIP/200-test1-0000ada0", "tl-set-variables2,from-inside-redir-test1,test1") in new stack
   -- Executing [s@macro-tl-set-variables2:1] Set("SIP/200-test1-0000ada0", "__tenant=test1") in new stack
   -- Executing [s@macro-tl-set-variables2:2] Set("SIP/200-test1-0000ada0", "CDR(userfield)=test1") in new stack
   -- Executing [s@macro-tl-set-variables2:3] Set("SIP/200-test1-0000ada0", "__FROM_INSIDE=1") in new stack
   -- Executing [s@macro-tl-set-variables2:4] Set("SIP/200-test1-0000ada0", "__MOH=yiddish-test1") in new stack
   -- Executing [s@macro-tl-set-variables2:5] GotoIf("SIP/200-test1-0000ada0", "1 ?setmoh") in new stack
 == Extension Changed 200[local-extensions-test1] new state InUse for Notify User 205-test1
   -- Goto (macro-tl-set-variables2,s,7)
 == Extension Changed 200[local-extensions-test1] new state InUse for Notify User 208-test1
   -- Executing [s@macro-tl-set-variables2:7] Set("SIP/200-test1-0000ada0", "CHANNEL(musicclass)=default-test1") in new stack
 == Extension Changed 200[local-extensions-test1] new state InUse for Notify User 300-test1
   -- Executing [s@macro-tl-set-variables2:8] Goto("SIP/200-test1-0000ada0", "from-inside-redir-test1,705,1") in new stack
   -- Goto (from-inside-redir-test1,705,1)
 == Channel 'SIP/200-test1-0000ada0' jumping out of macro 'tl-set-variables2'
   -- Sent into invalid extension '705' in context 'from-inside-redir-test1' on SIP/200-test1-0000ada0
   -- Executing [i@from-inside-redir-test1:1] Playback("SIP/200-test1-0000ada0", "invalid") in new stack
   -- <SIP/200-test1-0000ada0> Playing 'invalid.g729' (language 'en')


when dialing 700 it goes to the wrong lot the cli output  

   -- Executing [700@from-inside-test1:1] Macro("SIP/200-test1-0000ae0f", "tl-set-variables2,from-inside-redir-test1,test1") in new stack
   -- Executing [s@macro-tl-set-variables2:1] Set("SIP/200-test1-0000ae0f", "__tenant=test1") in new stack
   -- Executing [s@macro-tl-set-variables2:2] Set("SIP/200-test1-0000ae0f", "CDR(userfield)=test1") in new stack
 == Extension Changed 200[local-extensions-test1] new state InUse for Notify User 205-test1
   -- Executing [s@macro-tl-set-variables2:3] Set("SIP/200-test1-0000ae0f", "__FROM_INSIDE=1") in new stack
 == Extension Changed 200[local-extensions-test1] new state InUse for Notify User 208-test1
 == Extension Changed 200[local-extensions-test1] new state InUse for Notify User 300-test1
   -- Executing [s@macro-tl-set-variables2:4] Set("SIP/200-test1-0000ae0f", "__MOH=default-test1") in new stack
   -- Executing [s@macro-tl-set-variables2:5] GotoIf("SIP/200-test1-0000ae0f", "1 ?setmoh") in new stack
   -- Goto (macro-tl-set-variables2,s,7)
   -- Executing [s@macro-tl-set-variables2:7] Set("SIP/200-test1-0000ae0f", "CHANNEL(musicclass)=default-test1") in new stack
   -- Executing [s@macro-tl-set-variables2:8] Goto("SIP/200-test1-0000ae0f", "from-inside-redir-test1,700,1") in new stack
   -- Goto (from-inside-redir-test1,700,1)
 == Channel 'SIP/200-test1-0000ae0f' jumping out of macro 'tl-set-variables2'
   -- Executing [700@from-inside-redir-test1:1] Park("SIP/200-test1-0000ae0f", "") in new stack
 == Parked SIP/200-test1-0000ae0f on 701 (lot parkinglot_test0). Will timeout back to extension [from-inside-redir-test1] s, 1 in 180 seconds
   -- Added extension '701' priority 1 to parkedcalls-test0
   -- <SIP/200-test1-0000ae0f> Playing 'digits/7.g729' (language 'en')
   -- <SIP/200-test1-0000ae0f> Playing 'digits/0.g729' (language 'en')
   -- <SIP/200-test1-0000ae0f> Playing 'digits/1.g729' (language 'en')
   -- Started music on hold, class 'default-test1', on SIP/200-test1-0000ae0f


so in short this isnt working for me any advice



By: ppower (ppower) 2011-06-07 08:29:15.994-0500

moshe-

did you: include => parkedcalls-test1
in your dial plan before dialing 705

another way:
exten => 700,1,Set(CHANNEL(parkinglot)=parkinglot_test1)
exten => 700,n,Park()
but the include will still be needed to unpark

I will try to do more for this issue later...


By: moshe Teitelbaum (moshe) 2011-06-07 09:02:40.304-0500

yes i did include => parkedcalls-test1 and so on

By: ppower (ppower) 2011-06-07 09:44:47.857-0500

Your CLI output says that dialing 700 did park to lot parkedcalls-test0 which is the context you specified for that lot. So, it looks to me like 700 worked and 705 did not.


By: moshe Teitelbaum (moshe) 2011-06-07 09:59:47.403-0500

that is correct the is going further even when i specify in sip.conf for the specific extension parkinglot=parkinglot_test1 and i change in
features.conf

[parkinglot_test1]
context => parkedcalls-test1
parkingtime => 180
parkext => 700
parkpos => 701-704
findslot => next

Im getting the same results it goes to 700 of parkingltot_test0, as david is saying it always goes to the first lot of core show features no meter what context or lot you specify and it was working fine in 1.6.2.18

By: ppower (ppower) 2011-06-07 10:24:00.486-0500

Agreed. It is possible to lay out parking slots as i described above and have things work. I did it and did not like it. I changed up features.c to pay more attention to parking lot names.
Now i do this:
exten => 700,1,Set(CHANNEL(parkinglot)=parkinglot_test1)
exten => 700,n,Park()
and to unpark:
exten => 701,1,Set(CHANNEL(parkinglot)=parkinglot_test1)
exten => 701,n,ParkedCall(701)
exten => 702,1,Set(CHANNEL(parkinglot)=parkinglot_test1)
exten => 702,n,ParkedCall(702)
includes not required (or wanted, by me)

i will upload a diff to demonstrate what is have done. i should have a license signed with digium. people can do whatever they wish with this code.


By: Erik Smith (eeman) 2011-06-17 08:22:19.829-0500

ppower where is this diff?  this jira seems so clunky compared to mantis. I cant find anything and the search sucks by comparison.

By: Erik Smith (eeman) 2011-06-17 08:26:24.598-0500

why does jira say 'affects versoin: none' thats bullshit.. ALL of the ENTIRE 1.8 branch is affected by this. Why does it list asterisk-addons as 1.4.2? multi-tenant parking did not even exist in 1.4

By: ppower (ppower) 2011-06-17 08:30:41.745-0500

jira tells me that diff.txt is attached.  if you have problems finding it I could send it to you directly.

By: Erik Smith (eeman) 2011-06-17 08:40:09.355-0500

weird,i can see it now.

anyway that you can make it a unified diff? I want to try and put the code into 1.8.4.2 manually and test

By: ppower (ppower) 2011-06-17 09:38:25.778-0500

See how this works. uploaded features.diff

By: Erik Smith (eeman) 2011-06-19 22:32:49.666-0500

its still not working, its parking it in the first lot in the list instead of the correct one. As you can see the correct lot was supposed to be parkinglot_8776401550 but instead it went into parkinglot_5144185735

{code}
 -- Executing [700@from-inside-redir-8776401550:1] Park("SIP/MTE1-0000000e", "") in new stack
 == Spawn extension (macro-tl-dialout-base, dial-SIP, 7) exited non-zero on 'SIP/200-8776401550-0000000d' in macro 'tl-dialout-base'
 == Spawn extension (macro-tl-dialout-1-trunk, s, 3) exited non-zero on 'SIP/200-8776401550-0000000d' in macro 'tl-dialout-1-trunk'
 == Spawn extension (from-inside-redir-8776401550, 16465233864, 1) exited non-zero on 'SIP/200-8776401550-0000000d'
   -- Executing [h@from-inside-redir-8776401550:1] Hangup("SIP/200-8776401550-0000000d", "") in new stack
 == Spawn extension (from-inside-redir-8776401550, h, 1) exited non-zero on 'SIP/200-8776401550-0000000d'
 == MixMonitor close filestream
 == End MixMonitor Recording SIP/200-8776401550-0000000d
 == Extension Changed 200[local-extensions-8776401550] new state Idle for Notify User 208-8776401550
   -- PCPIII park_call_exec - log: parkinglot_5144185735, exten: 700
 == Parked SIP/MTE1-0000000e on 701 (lot parkinglot_5144185735). Will timeout back to extension [from-inside-redir-8776401550] s, 1 in 180 seconds
   -- Added extension '701' priority 1 to parkedcalls-5144185735
   -- <SIP/MTE1-0000000e> Playing 'digits/7.ulaw' (language 'en')
   -- <SIP/MTE1-0000000e> Playing 'digits/0.ulaw' (language 'en')
   -- <SIP/MTE1-0000000e> Playing 'digits/1.ulaw' (language 'en')
   -- Remote UNIX connection
   -- Remote UNIX connection disconnected
{code}

By: ppower (ppower) 2011-06-20 09:53:46.909-0500

I do not mind if we take this off line (ppower at integratelecom dot com).
I need to see the features.conf and extensions.conf

By: David Cabrejos (drcabrejos) 2011-07-12 11:27:41.474-0500

I've just installed and tested version 1.8.5.0, released yesterday, which was supposed to be a target version to solve this issue.

Unfortunately the multiple parking lot feature is still broken on all 1.8.x versions. Calls are still being parked in the top parking lot.
Already tried modifying features.c, however things still didn't work for me.

Any updates on a fix or which version to expect a working release?

By: Erik Smith (eeman) 2011-07-12 11:37:37.811-0500

AFAIK digium has done absolutely nothing to look into the issue. The patch the ppower uploaded will atleast get it working manually via dialplan Park() but getting to the right context via include => parked-calls-tenant  fails outright. I suspect that the channel variable defined in sip.conf parkinglot=parkinglot_tenant is simply getting lost or discarded as the only discernible difference is that using the dialplan Park is preceded by yet another Set command to re-assign the channel variable. Several thirdlane MTE customers have contracted me to write a custom script and patch their asterisk for them.

By: Richard Mudgett (rmudgett) 2011-08-15 12:50:22.384-0500

There are currently a bunch of issues reported against call parking.  These issues
are listed with a brief description in the patch I have up on reviewboard[1] to
resolve them and other parking issues I found.  A team branch[2] from the v1.8 branch
is also available to checkout until the patch is merged into the v1.8 and newer
branches.

The Asterisk Development Team would like some testers to check out the patch and to
report on this thread your findings.  We would like to compile some real world test
scenarios for a wiki page to prevent call parking from getting this badly broken in
the future.

Thank you

Richard

[1] https://reviewboard.asterisk.org/r/1358/

[2] http://svn.asterisk.org/svn/asterisk/team/rmudgett/parking

By: David Cabrejos (drcabrejos) 2011-08-16 10:57:44.309-0500

Richard,

I just started testing the parking patch on version 1.8.x, and so far, it's been able to park in the correct parking lot now!

I've tested multiple parking lots on versions 1.8.5.0 and 1.8.6.0-rc1 with the newest patch.

Will still do testing in real world scenarios and see if anything else is broken with regards to parking.

As of now, this is a great improvement since this feature was broken for a long time.

Thank you,

David Cabrejos

By: Richard Mudgett (rmudgett) 2011-08-16 12:31:07.077-0500

Fix committed see subversion tab.