09-22-2021 11:59 PM - edited 09-23-2021 12:08 AM
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?
09-23-2021 05:02 AM
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.
Maren
09-23-2021 05:38 AM
09-23-2021 10:10 AM - edited 09-23-2021 10:11 AM
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?
Maren
09-23-2021 10:31 PM - edited 09-23-2021 10:33 PM
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
Åsmund
09-23-2021 11:50 PM
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)#
09-23-2021 11:41 PM
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.
09-24-2021 01:01 AM
09-24-2021 03:11 AM - edited 09-24-2021 05:21 AM
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.
11-05-2021 05:11 AM
Hello Roger,
Thank you for your input. Decided to drop the 'start with and end with' operands as a workaround.
Do you however have any ideas as to why the operands aren't accepted as valid syntax?
Working with several systems and as mentioned initially, is that our preferred logic as there is the off-chance of another number string matching when dropping those operands.
Its valid on the exact same software/firmware on a different router. Its an interesting case to say the least.
Cheers!
11-05-2021 09:17 AM
Sorry but English is not my first language. I don't understand what you mean by this.
@asmund.bjerkeborve wrote:
Do you however have any ideas as to why the operands aren't accepted as valid syntax?
Would you mind to elaborate in simpler terms?
11-09-2021 05:16 AM - edited 11-09-2021 05:36 AM
No worries.
The symbols ^ and $ should signify the start of the string and the end followed by a NULL, respectively, if understood correctly.
Do you know why these are invalid syntax eventhough its working on similar routers and even in the running config itself?
11-09-2021 06:10 AM
Without seeing the rule itself, it is difficult to know why the issue exists. You should be able to post the voice translation rule as-written if you change some portion of the number to a dummy number. Such as, in the US, changing the NPA to 999 and the NXX to 555.
Maren
Discover and save your favorite ideas. Come back to expert answers, step-by-step guides, recent topics, and more.
New here? Get started with these tips. How to use Community New member guide