PDA

View Full Version : md5 Problems


pmonk
2005-02-21, 09:10 AM
When I generate an md5 checksum using either mkw, audiophilia or md5summer I get this when I try to very


C:\Documents and Settings\xxxxxxx\My Documents\My Music\Led Zeppelin 1972.0
2.19 Adelaide>for %f in (*.md5) do c:\windows\system32\md5sum.exe --check %f

C:\Documents and Settings\xxxxxxx\My Documents\My Music\Led Zeppelin 1972.0
2.19 Adelaide>c:\windows\system32\md5sum.exe --check Led Zeppelin 1972.02.19 Ade
laide.md5
c:\windows\system32\md5sum.exe: only one argument may be specified when using --
check
Try `c:\windows\system32\md5sum.exe --help' for more information.

C:\Documents and Settings\xxxxxx\My Documents\My Music\Led Zeppelin 1972.0
2.19 Adelaide>pause
Press any key to continue .



What am I doing wrong when I generate the md5sum????

The verification command works because I used it to verify other files and it works fine.

uhclem
2005-02-21, 09:32 AM
The problem is you have spaces in your md5 files names. The command line is totally braindead when it comes to spaces and other special characters such as & , > < etc.

put quotes around the %f like this:

for %f in (*.md5) do c:\windows\system32\md5sum.exe --check "%f"

Furthermore, this command-line 'verifies' an md5 checksum, it doesn't 'generate' one.

If you want to get fancy, put it all into a batch file using code like this:

@echo off
%~d1 & cd "%~s1"
for %%F in (*.md5) do md5sum --check "%%F"
pause

Save it in a text file but with a .bat extension. Then just drag and drop the folder containing your audio files and md5s straight onto the batch file.

Note that you must use double % in a batch file 'for' command, but not on the command line. You also can leave out the path to your md5sum.exe program (as well as the .exe) since it appears to be in your system path.

pmonk
2005-02-21, 10:25 AM
Thanks - missed the obvious and got it to work.!