mailstat: 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 CentOS possible default full paths are:

/usr/bin/mailstat - from package: procmail

You may install the required package with command yum install {package}

On Debian possible default full paths are:

/usr/bin/mailstat - from package: procmail

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