primitive-restart: 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/lib64/piglit/bin/primitive-restart - from package: piglit

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