dak180 / FreeNAS-Report

SMART & ZPool Status Report for FreeNAS/TrueNAS
GNU General Public License v3.0
38 stars 8 forks source link

md5sum is missing, please install #23

Closed TnTBass closed 1 year ago

TnTBass commented 1 year ago

Running the script generates an output/error:

md5sum is missing, please install

However, /sbin/md5 is in FreeBSD. Can that be used instead? Would be easier to use this script if no extra installs are required.

https://www.truenas.com/community/threads/md5sum-command-in-truenas-core-jail.90905/

TnTBass commented 1 year ago

Replaced the lines with md5sum and sha256 sum with md5 and sha256 - made it through to actually seeing a report now.

However:

cp: /root/backup/20230516125852_TrueNAS-12.0-U8-4db0d935e6.tar.gz: No such file or directory
/root/FreeNAS-Report/report.sh: line 1287: _WD-WMC1F1908317[lastTestHours]: invalid variable name

I suspect that's the reason why I'm not seeing all 6 of my drives in the report. Maybe the age of the drives?

Your Report

The original FreeNAS-Report you forked from would output as this (which is why I started down this journey of using your fork):

Original FreeNAS-Report

dak180 commented 1 year ago

What is the output of uname -mrs?

Also, can you run the script with -d and attach the resulting dump file after commenting out the _WD-WMC1F1908317[lastTestHours] line in your config file. Also please paste the serial number of the drive in question as it appears in smartctl output.

TnTBass commented 1 year ago
# uname -mrs
FreeBSD 12.2-RELEASE-p12 amd64

I didn't have a _WD-WMC1F1908317[lastTestHours] in my config file.

Serial number is: WD-WMC1F1908317

# ./report.sh -d -c /root/FreeNAS-Report/report.cfg
./report.sh: line 1287: _WD-WMC1F1908317[lastTestHours]: invalid variable name

Unfortunately I don't see any dump file.

TnTBass commented 1 year ago

I pulled your latest version, it doesn't complain about md5sum.

Still same errors on the variables though.

dak180 commented 1 year ago

@TnTBass please try the latest version.

TnTBass commented 1 year ago

Looks great now!

Only thing I noticed was the config backup location isn't created automatically, so I get an error that the file wasn't found. I created the directory set in the config and now it works great!

Thank you!