How to compare binary files after copying?

When you are copying oracle files (datafiles, archivelogs, controlfiles, etc) or any binary file one can compare if the files are the same as original file using cksum or sum command.

Example, if the files weren’t the same the values returned would be different, note in this example the database was shutdown
$ cp -p control02.ctl control02.ctl.bkp
$ cksum control02.ctl control02.ctl.bkp
3436546601 9388032 control02.ctl
3436546601 9388032 control02.ctl.bkp

$ sum control02.ctl control02.ctl.bkp
32903 9168 control02.ctl
32903 9168 control02.ctl.bkp