How can block a number on a particular extension?
I assume you mean you want to block calls for a particular number (or set of numbers) to a particular extension on your CUCM 7.0 network. This can be done, but it cannot be done within CUCM. CUCM does not offer any ability to filter calls based on Calling Number. However, you can filter these calls on your voice gateway as they come into your voice network, assuming you are using an H.323 gateway. This is a very good reason to use H.323 as the protocol for PSTN gateways, as MGCP does not allow you to do this.
Here's the procedure:
Step 1: Create a translation rule.
From global config mode on the voice gateway, create a voice translation rule with the following syntax.
voice translation-rule 100 ------> You can use any number you want, instead of 100.
rule 1 reject /XXXXXXXXXX/ -------> Replace XXXXXXXXXX with the calling number you want to block. Don't change the 1 on this line.
rule 2 reject /XXXXXXXXXX/ -------> You can also specify other numbers if there is more than 1 number to reject.
Step 2: Create a translation-profile
From global config mode on the voice gateway, create a voice translation profile with the following syntax
voice translation-profile BLOCK-CALLS ------->You can use whatever name you like
translate calling 100 ----------> This has to match the number you used in the voice transaltion-rule command.
Step 3:Apply the translation profile
Create a dial-peer unique to the called number you want to protect and apply the translation profile.
dial-peer voice 3000 voip
translation-profile outgoing BLOCK-CALLS ----> This has to match the tranlation profile
destination-pattern XXXX ----> whatever the extension is
session target ipv4:
Then copy any other dial-peer commands you might use here.
It is important to note that even though the call is coming in from the PSTN to the CUCM, in this dial-peer the calls is considered an outgoing call because from the router's point of view, the call came in from the PSTN and is going out to the CallManager.
If you want to apply this block to all extensions, you could just apply the translation pattern as incoming on the voice-port of the PSTN interface.
Hope this helps,
If you mean PSTN -> IP Phone, this has been asked PLENTY of times before, PLEASE SEARCH for answers before posting.
Call Blocking Configuration Examples
You need H323, no way to do this with MGCP.
If this helps, please rate