Davy Obdam wrote:
Hi people,
I have compiled mysql-4.0.17. Its installed in /usr/local/mysql. I would
like to add /usr/local/mysql/bin to my path for all users, including
root. I have looked it up on google, but believe that i need to edit my
/etc/profile file. Could someone tell me what to edit?
Best regards,
Davy Obdam
info@xxxxxxxxxxxxx
Go into /etc/profile.d
For csh-style users, create a file mysql.csh that looks like:
if ( "${path}" !~ */usr/local/mysql/bin* ) then
set path = ( $path /usr/local/mysql/bin )
endif
For sh-style users, create mysql.sh containing:
if ! echo ${PATH} | grep -q /usr/local/mysql/bin ; then
PATH=${PATH}:/usr/local/mysql/bin
fi
I do something similar for the Sun Java JRE.