md5sum command in TrueNAS Core jail?

chocobo01

Dabbler
Joined
Feb 2, 2021
Messages
15
Hi! I'm trying to download the md5sum command for the btfs installation in the jail, but when I tried to execute the install script for the btfs installation, it throws a message to me saying that I have to install the md5sum command and rerun that script again
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
md5sum is a Linux thing, they like writing their own stuff because it's so hard to write stuff that is POSIX compliant (if you don't hear the sarcasm, ...)

One version of md5sum, probably the most common, is available in GNU Coreutils.
 

chocobo01

Dabbler
Joined
Feb 2, 2021
Messages
15
ahh ok, but now do I modify the script file to use the gnu coreutil tool instead of md5sum? Because when I searched about it, it seems like if I install it from GNU Coreutils it's gonna be gmd5sum not md5sum?
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
Darned if I know. I just happened to know about the md5sum issue because I ran into it around 20 years ago. If you find a workable md5sum in the form of gmd5sum, you can always try adding a hardlink if they didn't do that:

# cd /usr/local/bin (or wherever)
# ln gmd5sum md5sum
 

chocobo01

Dabbler
Joined
Feb 2, 2021
Messages
15
Will try later! :smile:
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
/sbin/md5 has been in FreeBSD like "forever". If the output format of Linux md5sum is different it should be trivial to write a shell script wrapper.
 

jgreco

Resident Grinch
Joined
May 29, 2011
Messages
18,680
/sbin/md5 has been in FreeBSD like "forever". If the output format of Linux md5sum is different it should be trivial to write a shell script wrapper.

In true Linux fashion, they threw the kitchen sink at md5sum, with 11 command line flags and also long option versions of them. The RSA-sourced md5 code is a UNIX minimalist affair, with only six command line flags, two of which are "useless."

Therefore I would say it is false that it is "trivial to write a shell script wrapper". It may be possible to identify what is needed for the poster's issue and code something up for that specific subset, but generally it is probably easier just to find a buildable version of md5sum somewhere and do that instead.
 

Patrick M. Hausen

Hall of Famer
Joined
Nov 25, 2013
Messages
7,776
It may be possible to identify what is needed for the poster's issue and code something up for that specific subset.
That was my intention.
 
Top