I think that with the plethora of files required for CME to work the router's flash becomes a little crowded an could use a little housekeeping. I poked around a little and i found a surprisingly simple example to cleanup the router's flash.
The tftp-server command allows you to define an alias for the files that it serves to the IP phone. Saw this in several Cisco.com examples regarding phone backgrounds and localization files. It is used by default by CME but it's hidden under the hood. Do a show telephony-service tftp-bindings and you'll see lots of files that use the same technique.
#sh telephony-service tftp-bindings
tftp-server system:/its/united_states/7960-tones.xml alias United_States/7960-tones.xml
tftp-server system:/its/SEPDEFAULT.cnf alias SEPDefault.cnf
...
How is this helpful to us? Instead of changing the name of a file we change the location of the file, so a request for tftp://X.X.X.X/RingList.xml actualy reads the file Ringtones/RingList.xml which is in the Ringtones directory not a file in the root of the filesystem.
DISCLAIMER1: This configuration is probably not supported by Cisco TAC so bare that in mind if you use it.
DISCLAIMER2: The CME GUI files are not compatible with this solution so follow the Cisco.com instructions when installing them.
Here's the configuration for several files. You must create aliases for all the files that you want to move from the root of the filesystems to a directory.
(config)#tftp-server flash:Ringtones/RingList.xml alias RingList.xml
(config)#tftp-server flash:Ringtones/DistinctiveRingList.xml alias DistinctiveRingList.xml
(config)#tftp-server flash:Ringtones/Analog1.raw alias Analog1.raw
(config)#tftp-server flash:Ringtones/Analog2.raw alias Analog2.raw
...
Same goes for the phone firmware, place them in a Loads directory:
(config)#tftp-server flash:Loads/P00308000500.bin alias P00308000500.bin
(config)#tftp-server flash:Loads/P00308000500.bin alias P00308000500.bin
In the end we have a cleaner flash with directories:
#dir flash:
Directory of flash:/
1 drw- 0 May 26 2009 22:40:20 +02:00 Loads
4 -rw- 496521 Mar 29 2004 11:40:48 +02:00 music-on-hold.au
5 drw- 0 May 26 2009 22:40:40 +02:00 Ringtones
39 drw- 0 May 26 2009 22:43:42 +02:00 Desktops
...
To check that all works well, here's the debug of a 7940 registering to CUCME:
#debug tftp event
...
*Jun 7 21:21:07.727: TFTP: Looking for RINGLIST.XML
*Jun 7 21:21:07.727: TFTP: Opened flash:Ringtones/RingList.xml, fd 8, size 2823 for process 227
*Jun 7 21:21:07.815: TFTP: Finished flash:Ringtones/RingList.xml, time 00:00:00 for process 227
*Jun 7 21:21:07.847: TFTP: Looking for DISTINCTIVERINGLIST.XML
*Jun 7 21:21:07.847: TFTP: Opened flash:Ringtones/DistinctiveRingList.xml, fd 7, size 2823 for process 225
*Jun 7 21:21:07.867: TFTP: Finished flash:Ringtones/DistinctiveRingList.xml, time 00:00:00 for process 225
...
Hope you enjoy it...