getmsgs: 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/share/doc/mh-book/examples/mh/bin/getmsgs - from package: mh-book

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