I am working with a Redhat distribution. Mysql is installed with the binary in the following path:
/root/opt/rh/mysql55/root/usr/bin/mysql
Furthermore, the environmental variable PATH echos:
echo $PATH
/root/opt/rh/mysql55/root/usr/bin/mysql:/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin:/root/opt/rh/mysql55/root/usr/bin/mysql
The server has been restarted but if I type
mysql
into bash it returns the following:
# mysql -u root
-bash: mysql: command not found
Please advise
EDIT
Altered PATH EV to
/root/opt/rh/mysql55/root/usr/bin
using
export mysql /opt/rh/mysql55/root/usr/bin
export PATH ${mysql}:${PATH}
Still get command not found
After rebooting the server, echo $PATH is now:
/usr/lib64/qt-3.3/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/root/bin
So, the path to mysql is gone.