icinga2-diagnostics icon indicating copy to clipboard operation
icinga2-diagnostics copied to clipboard

Avoid "find /..." without excludes

Open hpreusse opened this issue 5 years ago • 0 comments

Anywhere in the code the diag script calls find like this

for i in $(find / -name php.ini 2>/dev/null)

Doing find /.... without any excludes is IMHO a bad idea, as we have a huge NFS share. Consider to use locate(1) in this situation and fall back to find(1) only if there is no locate(1) or it does not return results.

hpreusse avatar Dec 21 '20 21:12 hpreusse