OneFreeVoice

April 16, 2008

pre-compiled binaries in your PATH

Filed under: GNU/Linux, MySQL — Tags: , , — Gregory Haase @ 4:29 pm

I prefer to install mySQL using the pre-compiled binaries. Depending on the environment, these usually go in either /opt or /usr/local. When you choose this type of install, chances are you are going to need to ensure that you somehow configure your system so that the mysql binaries end up in your PATH.

If you are using RedHat or CentOS, a good way to do this is to add a custom file inside of the /etc/profile.d/ directory. I create one called “mysql.sh”:

if ! echo ${PATH} | /bin/grep -q /opt/mysql/bin ; then
        PATH=/opt/mysql/bin:${PATH}
fi

This script simply checks you PATH for mysql and adds it if it’s not already there.

If you are using Ubuntu, you can edit /etc/environment:

PATH="/usr/local/bin:/usr/bin:/bin:/opt/mysql/bin"
LANG="en_US.UTF-8"

You can see that I’ve just added “:/opt/mysql/bin” to the end of the PATH line.

There are lots of other ways to do this, and I’m sure some distributions not covered here do it differently. If you know of a different or better way, I look forward to your comments.

January 1, 2007

Digital Photos Organized

Filed under: GNU/Linux, Personal — Gregory Haase @ 11:45 am

Until yesterday, my collection of digital photos was a complete mess. We had pictures archived away in multiple tar files on multiple computers, and duplicates everywhere. It was hard to find a picture, and unless you really knew exactly what you were looking for and where it was, it was impossible. Yesterday, I googled for a good solution and I came upon This informative post about photo organization in linux. It was the perfect solution. (more…)

Theme: Silver is the New Black. Blog at WordPress.com.

Follow

Get every new post delivered to your Inbox.