Asterisk Call forwarding needs to ignore individuals on Group Ring IN

So we have a simple asterisk setup with pure SIP/PJSIP trunks and extensions.

When a user who is part of a ringgroup has call forwarding turned on via their handset then all the calls for the entire inbound gets forwarded. What we would like to see is when a call is routed to a ring group that has a member of the group who has setup call forwarding turned on it gets ignored. This way when someone calls in all the extensions get rang and it gets pickedup by someone. If we transfer the call to that person then it gets forwarded but no other case. I hope I am making sense here! :smiley:

What’s a ringgroup? By call forwarding turne don via the handset, I assume you mean the phone is configured to send a 302 redirect. If not, that is not something that is built into Asterisk. Devices, not extensions get rung.

I strongly suspect you are having problems with FreePBX, not Asterisk.

If call forwarding is done with 302, Asterisk will not know about it until it has already called the device. If it is in software, you can test whatever flag it sets, using dialplan code.

Vanilla Asterisk 15.6.2

FreePBX handled this beautifully but Asterisk alone does not and I have been searching for a way to fix this for some time now. Aastra 6757i phones endpoint based redirection.

I keep using the FreePBX terminology but basically an extension linked to a group of extensions that rings when a call is inbound from our SIP Trunk Provider.

You are going to have to show us how you implemented “ringgroups” and controlled forwarding.

FreePBX is layered on top of Astiersk, so can only do things that Asterisk can do.

1 Like

Ring Groups are not a “thing” they are a method in which to call a group of endpoint/devices in a specific manner and way. How you manage that is completely up to you.

Look at the ‘i’ option to Application Dial

https://wiki.asterisk.org/wiki/display/AST/Application_Dial

That wasn’t my original interpretation of the requirement, but, on re-reading, I’ve decided I really don’t understand the requirement, at all.

1 Like

I believe that you have understood my request completely. Here is a copy of my method:

exten => 4900,hint,PJSIP/4900
        same => 1,dial(PJSIP/4901&PJSIP/4902&PJSIP/4903&PJSIP/4904&PJSIP/4905&PJSIP/4912&PJSIP/4917,i)
        same => n,Hangup

So when I have an inbound call it goes to exten 4900 how would I place that “i” flag in here? I think I have either figured it out or I am on the right track with my example above. I don’t want to add something that will disrupt calls when I reload the dialplan so I thought I would place it here first.

For anyone else that may be having this problem this is the answer:

exten => 4900,hint,PJSIP/4900
        same => 1,dial(PJSIP/4901&PJSIP/4902&PJSIP/4903&PJSIP/4904&PJSIP/4905&PJSIP/4912&PJSIP/4917,,i)
        same => n,Hangup

Note that in my first example I had only 1 comma “,” after the list of extensions to be rang. So this worked perfectly once that was fixed.

Thank you @johnkiniston I am super excited to have this up and running!!!

1 Like