The command sha256sum
correctly calculates checksum indicated in .sha256 file:
user@myHostname:~/Desktop/RT_N16/Merlin_JohnsFork$ sha256sum RT-N16_3.0.0.4_374.43_2-39L3j9527.trx
545927719c46e359a0db6bf9dcb348f99c0f3d8786725780cb182994c61b19be RT-N16_3.0.0.4_374.43_2-39L3j9527.trx
All files are in the same directory. I did NOT create the Contents of a .sha256 file:
user@myHostname:~/Desktop/RT_N16/Merlin_JohnsFork$ cat sha256sum.sha256
545927719c46e359a0db6bf9dcb348f99c0f3d8786725780cb182994c61b19be RT-N16_3.0.0.4_374.43_2-39L3j9527.trx
The sha256sum
command reads the .sha256 file and returns an error:
user@myHostname:~/Desktop/RT_N16/Merlin_JohnsFork$ sha256sum -c sha256sum.sha256
sha256sum: 'RT-N16_3.0.0.4_374.43_2-39L3j9527.trx'$'\r': No such file or directory
: FAILED open or read_2-39L3j9527.trx
sha256sum: WARNING: 1 listed file could not be read
QUESTIONS
Is the above syntax incorrect or is there a problem with the .sha256 file?
Is the command trying to open a filename=
_2-39L3j9527.trx
?
545927719c46e359a0db6bf9dcb348f99c0f3d8786725780cb182994c61b19be /home/user/RT-N16_3.0.0.4_374.43_2-39L3j9527.trx
– Abhishek Nair Aug 03 '19 at 05:20sha256sum.sha256
? It seems there is a formatting problem'RT-N16_3.0.0.4_374.43_2-39L3j9527.trx'$'\r':
vs.RT-N16_3.0.0.4_374.43_2-39L3j9527.trx
. Try to edit or recreate the file with an editor on your Ubuntu system. – Thomas Aug 03 '19 at 08:39dos2unix
command corrected the .sha256 file for UNIX – gatorback Aug 03 '19 at 14:17