query.pyo: 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/lib/python2.6/site-packages/viewvc/bin/mod_python/query.pyo - from package: viewvc

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