Checking which extension have forwarding enabled.

Discussion in 'General' started by jimikid2002, Jun 19, 2010.

  1. jimikid2002

    Joined:
    Jun 24, 2009
    Messages:
    18
    Likes Received:
    0
    Hello,

    Few days back I shown to users how to setup call forward on their extensions. Now, many of them set it up to forward their calls to their cell phones and never turned it off. Few of them telling they disables/canceled the feature but still getting calls on their cell phone. Most of the trunk lines are remain busy due to this forwarding frenzy. I want to see/check which extension are having forwarding enabled. How and where to check???

    Please help


    Regards
    Jimi
     
  2. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    From a bash like thingy, console,ssh or the asterisk command line thing:

    rasterisk -x 'database show'|grep -r "^/CF"
     
  3. jimikid2002

    Joined:
    Jun 24, 2009
    Messages:
    18
    Likes Received:
    0
    Thank you sir. You are a life saver.......... How to disable forwarding (I am getting greedy!).... from server, without pressing keys on 21/22 extensions?


    Regards
    Jimi
     
  4. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    rasterisk -x 'database del CFU 456' for example
     
  5. jimikid2002

    Joined:
    Jun 24, 2009
    Messages:
    18
    Likes Received:
    0
    Thanks Dicko, I found it and have done it. For anyone who may come to this thread for help following is the process


    asterisk -rvvvv
    database del CFU "extension number"


    This will disable forwarding for the given extension.


    Sir, please correct me if I am wrong.
     
  6. dicko

    Joined:
    Oct 24, 2008
    Messages:
    4,099
    Likes Received:
    0
    That will work, it is essentially the same solution I suggested, but it's a slow plodding way, and doesn't take care of CFB and CF (always) ;)

    an automated "turn them all off" might be a oneliner:-

    rasterisk -x 'database show'|grep -r "^/CF"|cut -d ":" -f1|awk -F/ '{print "rasterisk -x \" database del " $2 " " $3 "\"" }' > sh.tmp;sh sh.tmp;rm sh.tmp

    add another grep <extension> pipe before the > redirection for just one extension.

    modify ingredients to suit, maybe turn it into a shell script or cron job, but I'm glad you are fixed now.

    dicko
     

Share This Page