Showing results for 
Search instead for 
Did you mean: 

Syntax error when editing/readding voice translation-rules

Good day Gents,


I recently encountered an issue when attempting to add new VOIP phone on the 16.08.01 firmware(4331).


It should be simple enough change translating a 4 chipher assigned number to the full number on our servers, however receiving the following error when editing the translation rules:


The invalid syntax is given at circumfleks character. E.g. :


(cfg-translation-rule)# rule 4 /^<4 chiphers>$/ /<Full number>/

Translating prefixes is ok on a side note:


(cfg-translation-rule)# rule 18 /^47+/ /0147/
(cfg-translation-rule)# rule 19 /^1+/ /011/


Tested on a similar router running the same firmware with no issues. And the weird thing is that copying from the running config yields the same syntax error.


Any ideas?

Maren Mahoney

I see this error when I have generated the ruleset with the command "translation-rule" instead of "voice translation-rule". Check to see if you have that initial command correct. If you are still getting an error after that, let us know and we can take a look.


Thanks for the reply. Input commands are added to the topic and are all starting with 'voice translation-rule'. Tests have been made on an identical setup(firmware, router version and general voice config) however the issue is only present on this one router with same input commands on the similar router without any issues.

How interesting! If it dislikes the voice translation-rule with the cipher but is happy with other voice translation-rules, is it possible there is a licensing issue with the security portion of IOS - isr4400-universalk9 vs. isr4400-universalk9_npe?


Hmm... It appears to be in order. Both images are isr4300-universalk9.16.08.01.SPA.bin for the compared router and the one having this issue. Here is the output of the license details, which also are identical on both, if to any help:

RO1#show license feature
Feature name Enforcement Evaluation Subscription Enabled RightToUse
appxk9 yes yes no yes yes
uck9 yes yes no yes yes
securityk9 yes yes no yes yes
ipbasek9 no no no yes no
FoundationSuiteK9 yes yes no no yes
AdvUCSuiteK9 yes yes no no yes
cme-srst yes yes no yes yes
hseck9 yes no no no no
throughput yes yes no no yes
internal_service yes no no no no


We can easily identify if we are  under the translation-rule or voice translation-rule.


When using translation-rule:-  (config-translate)#rule 

When using Voice translation-rule : (cfg-translation-rule)#

Response Signature

Nithin Eluvathingal
VIP Mentor

Can you post <4 chiphers> value which you tried on (cfg-translation-rule)# rule 4 /^<4 chiphers>$/ /<Full number>/ I can test this on my isr 4321 router.





Response Signature


I am afraid I can't disclose the full number translation. It is basically 'translate this 4 digit IP phone assigned number(the last 4 digits of the full length number) to its full length E164 number.' E.g. 8803.


If what you want is to translate the last 4 digits to the full number I would recommend you to use this rule.


rule 4 /\(<4 last digits>\)$/ /<prefix to get full number>\1/

or this if you have a range of numbers and all you want to do is expand it out to the full number
rule 4 /\(....\)$/ /<prefix to get full number>\1/


If the number is longer than 4 digits there is no need to have both a ^ and a $ as that should indicate that you want to match on that specific 4 number string and that it start and ends with the digits.

Response Signature

Recognize Your Peers
Content for Community-Ad