yppasswd: 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/yppasswd - from package: yp-tools

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

On Debian possible default full paths are:

/usr/bin/yppasswd - from package: nis

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