Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Community Member

downlaod moh file that has dashes in the filename

Hi,

I'm trying to download a moh file from my CM6.1 via ftp.  So I ssh to the pub, run "file get activelog mohprep/file-name.wav"

However when I execure the command and fill in the FTP details, it give me "Invalid command, a dash character must be preceded by an alphanumeric character".

How do I manage to get this file off the server if has dashes in the filename.

Thanks,

Neil

7 REPLIES
Cisco Employee

Re: downlaod moh file that has dashes in the filename

You can use a wildcard instead since the command line won't accept certan characters.  Use "file get activelog mohprep/*" to get all files on the system or make the it more specific with file*.

Community Member

Re: downlaod moh file that has dashes in the filename

thanks Joemar2,

I tried it and it downloads everything except for the files with the dashes.

Strange!!

It's not a big deal, it would be nice if I could get them but it's not the end of the world.

Thanks,
Neil

Cisco Employee

Re: downlaod moh file that has dashes in the filename

Hi Neil,

What version of CUCM are you having this issue with? I tried with 6.1.3.1000-16 and it worked fine. There are a few defects related to cli using dashes

Cheers,

Kristof

Community Member

Re: downlaod moh file that has dashes in the filename

I was wrong in my OP, it's actually 6.1.3.3190-1

Maybe it's a bug then??

Cisco Employee

Re: downlaod moh file that has dashes in the filename

I tried on 6.1.3.1000-16 and it works fine, if you would have a lower version I would have suspected a bug. Could you provide the complete output of the below two commands up until the point where it fails

file list activelog /mohprep date detail

file get activelog /mohprep/

Community Member

Re: downlaod moh file that has dashes in the filename

admin:file list activelog /mohprep date detail
17 Jun,2004 20:12:31    2,702,728  SampleAudioSource.alaw.wav
17 Jun,2004 20:12:36      332,600  SampleAudioSource.g729.wav
17 Jun,2004 20:12:39    2,702,728  SampleAudioSource.ulaw.wav
17 Jun,2004 20:12:58   10,810,774  SampleAudioSource.wb.wav
07 Dec,2005 08:52:17          606  SampleAudioSource.xml
03 Oct,2008 11:49:22    1,621,728  070208_ONHOLD_EDIT_.alaw.wav
03 Oct,2008 11:49:22      202,760  070208_ONHOLD_EDIT_.g729.wav
03 Oct,2008 11:49:22    1,621,728  070208_ONHOLD_EDIT_.ulaw.wav
03 Oct,2008 11:49:22    6,486,772  070208_ONHOLD_EDIT_.wb.wav
03 Oct,2008 11:50:15          656  070208_ONHOLD_EDIT_.xml
13 Aug,2009 15:19:57    1,385,578  on hold - aug 09.alaw.wav
13 Aug,2009 15:19:57      173,240  on hold - aug 09.g729.wav
13 Aug,2009 15:19:57    1,385,578  on hold - aug 09.ulaw.wav
13 Aug,2009 15:19:57    5,542,178  on hold - aug 09.wb.wav
13 Aug,2009 15:21:34          641  on hold - aug 09.xml
14 Aug,2009 11:46:30    1,385,580  on hold - aug 09x.alaw.wav
14 Aug,2009 11:46:30      173,240  on hold - aug 09x.g729.wav
14 Aug,2009 11:46:30    1,385,580  on hold - aug 09x.ulaw.wav
14 Aug,2009 11:46:30    5,542,184  on hold - aug 09x.wb.wav
14 Aug,2009 11:47:20          646  on hold - aug 09x.xml
06 May,2010 10:07:07       37,662  neil.alaw.wav
06 May,2010 10:07:07        4,750  neil.g729.wav
06 May,2010 10:07:07       37,662  neil.ulaw.wav
06 May,2010 10:07:07      150,510  neil.wb.wav
06 May,2010 10:07:08          538  neil.xml
26 Aug,2010 16:23:27    1,463,460  26 Aug - Phone_.com_.ulaw.wav
26 Aug,2010 16:23:27    5,853,702  26 Aug - Phone_.com_.wb.wav
26 Aug,2010 16:23:27      182,970  26 Aug - Phone_.com_.g729.wav
26 Aug,2010 16:23:27    1,463,460  26 Aug - Phone_.com_.alaw.wav
26 Aug,2010 16:24:16        3,724  CiscoMOHSourceReport.xml
26 Aug,2010 16:24:16          661  26 Aug - Phone_.com_.xml
dir count = 0, file count = 31
admin:

The file I'm trying to retrieve is "26 Aug - Phone_.com_.ulaw.wav".  When I use the wildcard the process does complete sucessfully but all that's FTP'd down is the folder structure, not the actual file itself.

When I used "file get activelog /mohprep/*" it copied all the files except the ones with the dashes and spaces.  Actually, now that I look at it, I wonder is because of the spaces??

Cisco Employee

Re: downlaod moh file that has dashes in the filename

The space is indeed the problem (only a dash works fine), and a space in combination with a dash gives even a different error:

admin:file list activelog /mohprep/SampleAudioSource-test.ulaw.wav
SampleAudioSource-test.ulaw.wav
dir count = 0, file count = 1
admin:file get activelog /mohprep/SampleAudioSource-test.ulaw.wav
Please wait while the system is gathering files info ...done.
Sub-directories were not traversed.
Number of files affected: 1
Total size in Bytes: 2702728
Total size in Kbytes: 2639.3828
Would you like to proceed [y/n]? n
Files transfer cancelled.


admin:file get activelog /mohprep/SampleAudioSource -test.ulaw.wav
Invalid command, a dash character must be preceded by an alphanumeric character

admin:file get activelog /mohprep/SampleAudioSource test.ulaw.wav
Missing file-spec or invalid command option specified.
Valid options: [reltime|abstime][match][compress]
admin:

The issue with the space seems to match defect CSCsr43052: http://tools.cisco.com/Support/BugToolKit/search/getBugDetails.do?method=fetchBugDetails&bugId=CSCsr43052

But that should be fixed in the version you are running and in the version I am testing with.

971
Views
0
Helpful
7
Replies
CreatePlease to create content