cpanspec: 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/cpanspec - from package: cpanspec

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