Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Basically, I want to do the same thing that Google Voice does. I forward my calls to a DID number that rings my Asterisk server via IAX2, which, if it detects the call has been forwarded, sends it to voicemail. Otherwise, if the call hasn't been forwarded (and somebody has dialed the DID number), it dials my phone number and tries to reach me.

tl;dr: how do I detect that a call has been forwarded to my asterisk box?

share|improve this question

I don't believe you can detect if a call has been forwarded. I don't believe Google Voice can do this either.

share|improve this answer
I'm fairly sure that it does -- whenever I forward the call to Google Voice, it doesn't attempt to ring my phone because it knows that it's unavailable, whereas if I call my Google Voice number the phone rings. – jibcage Mar 21 '12 at 3:51

I was looking for this also. You want "RDNIS"

Just look at that to determine what numbers were involved.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.