sqlgrey-logstats: command not found

Have You tried accessing the binary with the full path?

Maybe Your $PATH variable doesn't contain the default paths? echo $PATH should give something like:

[root@server ~]# echo $PATH
/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin

If it's empty, You may set the PATH variable with this command

export PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin"

On Debian possible default full paths are:

/usr/bin/sqlgrey-logstats - from package: sqlgrey

You may install the required package with command apt-get install {package}
Error in other languages:
sqlgrey-logstats: bevel nie gevind nie
sqlgrey-logstats: comandă negăsită
sqlgrey-logstats: comando não encontrado
sqlgrey-logstats: commande introuvable
sqlgrey-logstats: command not found
sqlgrey-logstats: käsku ei ole
sqlgrey-logstats: không tìm thấy lệnh
sqlgrey-logstats: komanda nerasta
sqlgrey-logstats: Kommando nicht gefunden.
sqlgrey-logstats: kommandot finns inte
sqlgrey-logstats: komut yok
sqlgrey-logstats: nie znaleziono polecenia
sqlgrey-logstats: níor aimsíodh an t-ordú
sqlgrey-logstats: no se encontró la orden
sqlgrey-logstats: no s'ha trobat l'ordre
sqlgrey-logstats: opdracht niet gevonden
sqlgrey-logstats: parancs nem található
sqlgrey-logstats: perintah tidak ditemukan
sqlgrey-logstats: príkaz nenájdený
sqlgrey-logstats: příkaz nenalezen
sqlgrey-logstats: команда не найдена
sqlgrey-logstats: командата не е открита
sqlgrey-logstats: 命令找不到
sqlgrey-logstats: コマンドが見つかりません