Monday, September 30, 2013

Upgrades are prohibited during License Grace Period, find and delete licexpiry.txt file - v2

See http://webmaxtor.blogspot.com/2013/07/upgrades-are-prohibited-during-license.html for original post and background information.

Given you are prompted with the "Upgrades are prohibited during Licensing Grace Period" error message during a Cisco CUCM upgrade attempt, here's an unsupported method to perform a procedure Cisco TAC might use.


It is essentially a way to get access to the CUCM file system, then find and delete the licexpiry.txt file.

Boot your CUCM server off of a CentOS version 5 disk. I am using the i386 disk 1 from CentOS version 5.9.  You can find the CentOS mirrors here: http://www.centos.org/modules/tinycontent/index.php?id=30


Type "linux rescue", or, as shown below, after you pressed F5 when prompted for Rescue.


Choose your language, your keyboard and skip the networking, as it's not really necessary.




Press Continue when prompted to find your linux environment.


If you are prompted to pick a partition containing your linux installation, you can pick sda1.


If successful, the CUCM linux system will be mounted under /mnt/sysimage.


At that point, you should be able to change to the CUCM file system, find and delete the licexpiry.txt file.

The commands are:

To change to the CUCM file system location:
chroot /mnt/sysimage 

To find the file called licexpiry.txt:
find / -iname licexpiry.txt

To change to the location of the found file:
cd /usr/local/platform/conf
If the CUCM server being upgraded exists on a different partition, you might see partB in the path returned by the find command.  In that case, add partB, or whatever, to the cd command:
cd /partB/usr/local/platform/conf

to remove the file
rm licexpiry.txt

It should look something like this (here I mistakenly tried to use del instead of rm):


If you run into the partB scenario, it might look like this (here I mistakenly first typed the path without the partB reference):


After both rm commands above, I ran the find command again to verify the licexpiry.txt file is gone.

Type "exit" a couple times and your server should reboot after automatically after exiting the CentOS shell.

Happy unsupported upgrades!

Monday, September 09, 2013

Cisco VG224 CPTONE usage and send custom tones to FXS port

See some official documentation here:
http://www.cisco.com/en/US/docs/ios/12_3t/voice/command/reference/vrht_t1_ps5207_TSD_Products_Command_Reference_Chapter.html#wp1645172

Customer had requirements of a third party fax server, served by analog ports on a VG224, to send custom tones to the devices on the FXS side.  The devices in this case were analog Dialogic board ports of some sort.

My first instinct was to create a new voice class and apply it to the voice ports like so:

voice class custom-cptone MyFax
dualtone busy
frequency 425
cadence 250 250
dualtone reorder
frequency 425
cadence 320 320

voice-port 1/1/0
 supervisory custom-cptone MyFax

This not only won't work, it's not what it's for.

You need to use the "test voice tones" command.  The fact that the command is test seems counter-intuitive, but it works.

First, do a "test voice tones show" to display the default defined values. The C1 values are below:

MyVG224#test voice tone C1 show
Code: C1   Country: Custom1
DTMF freq.(Hz) Row / col:  697,  770,  852,  941 / 1209, 1336, 1477, 1633
Pulse dial: normal, Percent make: 40%, DTMF low Amp. = 65446,  high Amp. = 65467,   Pcm: u-Law
     Tone      NF   FOF  FOS  AOF_FXS AOF_FXO AOF_EM AOS_FXS AOS_FXO AOS_EM  ONTF  OFTF  ONTS  OFTS  ONTT  OFTT  ONT4  OFT4
BUSY           2   480   620    -170    -170    -240    -170    -170    -240   500   500     0     0     0     0     0     0
RING_BACK      2   440   480    -160    -160    -190    -160    -160    -190  2000  4000     0     0     0     0     0     0
CONGESTION     2   480   620    -170    -170    -190    -170    -170    -240   250   250     0     0     0     0     0     0
NUM_UNOBTAINAB 2   480   620    -170    -170    -190    -170    -170    -240   250   250     0     0     0     0     0     0
DIALTONE       2   350   440    -165    -165    -185    -165    -165    -185 65535     0     0     0     0     0     0     0
DIAL_TONE2     2   350   440    -165    -165    -185    -165    -165    -185 65535     0     0     0     0     0     0     0
OUT_OF_SERVICE 1   950     0    -150    -150    -185      0      0      0   330   330     0     0     0     0     0     0
ADDR_ACK       1   600     0    -240    -240    -240      0      0      0   125   125   125 65535     0     0     0     0
DISCONNECT     1   600     0    -150    -150    -185      0      0      0   330   330   330 65535     0     0     0     0
OFFHOOK_NOTICE 2  1400  2040    -240    -240    -240    -240    -240    -240   100   100     0     0     0     0     0     0
OFFHOOK_ALERT  4  1400  2040    -150    -150    -185    -150    -150    -185   100   100     0     0     0     0     0     0

If, for example you want to modify what dial tone sounds like when an FXS port goes off-hook, you would execute:

test voice tone C1 DIALTONE       2   340   440    -165    -165    -185    -165    -165    -185 65535     0     0     0     0     0     0     0

In this case, I am changing the first frequency in a dual tone frequency from the default 350 to 340.

You then simply apply the new settings to the voice port via 

voice-port 2/0
 cptone C1

You can verify the changes / new settings by simply running "test voice tone C1 show" again, and your modifications should have replaced the defaults.

This change DOES NOT show in the running-configuration and WILL NOT survive a gateway reboot.

The make them "permanent" you need to add commands to reapply the changes when a syslog "restarted" event is raised.  For example, to make my change above get reapplied after a reboot, you must add the following to your running config:

event manager applet Tone-application
 event syslog pattern "%SYS-5-RESTART: System restarted"
 action 1.0 cli command "enable"
 action 1.1 cli command "test voice tone C1 DIALTONE       2   340   440    -165    -165    -185    -165    -165    -185 65535     0     0     0     0     0     0     0"

Note here that you can make changes to any number of tones like BUSY, RING_BACK, etc. by adding additional lines to the config and incrementing the action 1.X command.  For example, changing both DIALTONE and BUSY on a restart, you would enter the following.

event manager applet Tone-application
 event syslog pattern "%SYS-5-RESTART: System restarted"
 action 1.0 cli command "enable"
 action 1.1 cli command "test voice tone C1 DIALTONE       2   340   440    -165    -165    -185    -165    -165    -185 65535     0     0     0     0     0     0     0"
 action 1.2 cli command "test voice tone C1 BUSY           2   500     0    -170    -170    -240    -170    -170    -240   550   550     0     0     0     0     0     0"

If you want to get crazy, try changing the DIALTONE and RING_BACK tones to something high like 1000 and / or changing the on / off times to something short like 100 so you're confident, just by ear, the changes are effective.