I have found the md5sum command very useful in many cases. It generates a checksum that can be checked to verify whether a file has been downloaded correctly. I have been using it this way in Linux:
$ md5sum *.zip > .md5
The above command will check all the zip files in the current directory and generate individual checksum for each file. Some times you just want to append one more entry into that .md5 file:
$ md5sum <new_file>.zip | tee -a .md5
The checksums will be stored in the file .md5. To verify the integrity of the files, just run
$ md5sum -c .md5
It will produce a list of files with the status (hopefully OK). A simple Python program for this: