rspec: 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/rspec - from package: rubygem-rspec-core
/usr/lib/ruby/gems/1.8/gems/rspec-core-2.6.4/bin/rspec - from package: rubygem-rspec-core

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

On Debian possible default full paths are:

/usr/bin/rspec - from package: ruby-rspec-core

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