Adding mysql to my path
Bevan C. Bennett
bevan at fulcrummicro.com
Tue Jan 6 20:34:07 UTC 2004
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 at davyobdam.com
>
>
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.
More information about the fedora-list
mailing list