I got a request from one of my clients to setup a mysql server with the latest version. I decided to install mysql using source , because i always love compilation 🙂
As usual I downloaded the latest source and fired the command ” ./configure ” with options . But the result was not good 🙁
=>> Download the latest MySql source
wget http://dev.mysql.com/get/Downloads/MySQL-5.5/mysql-5.5.15.tar.gz/from/http://mysql.oss.eznetsols.org/=>> Configure ( Old Story )
1) tar -zxf mysql-5.5.15.tar.gz
2) cd mysql-5.5.15
3) ./configure
./configure: command not found
( After some goggling , i found ” In MySQL 5.5 onwards , CMake is used as the build framework on all platforms. ” )
=>> Download and install cmake
$ wget http://www.cmake.org/files/v2.8/cmake-2.8.5.tar.gz
$ tar zxvf cmake-2.8.5.tar.gz
$ cd cmake-2.8.5
$ yum install gcc-c++
$ ./configure
$ make
$ make install
=>> Configure ( New Story )
$ cd mysql-5.5.15
$ Configure using cmake
cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql5 -DMYSQL_TCP_PORT=3306 -DMYSQL_UNIX_ADDR=/tmp/mysql.sock
— Could NOT find Curses (missing: CURSES_LIBRARY CURSES_INCLUDE_PATH)
CMake Error at cmake/readline.cmake:83 (MESSAGE):
Curses library not found. Please install appropriate package,
$ yum install ncurses-devel
$ rm -f CMakeCache.txt ( Equivalent to ” make clean ” )
$ Again run the cmake command after fixing the curses error.
cmake . -DCMAKE_INSTALL_PREFIX=/usr/local/mysql5 -DMYSQL_TCP_PORT=3306 -DMYSQL_UNIX_ADDR=/tmp/mysql.sock
more cmake configuration options here : cmake options
$ make
$ make install
=>> Post installation Steps
$ cp support-files/my-medium.cnf /etc/my.cnf
$ cp support-files/mysql.server /etc/init.d/mysql
$ chown -R mysql:mysql .
$ ./scripts/mysql_install_db – -user=mysql – -datadir=/var/lib/mysql
$ /etc/init.d/mysql restart
$ ./bin/mysqladmin -u root password ‘new-password’
$ ./bin/mysql_secure_installation
Thats its you installed mysql 5.5 successfully. You can configure / optimize the mysql using the my.cnf file .
=>> Test the insatalation
$ mysql -u root -p
> create table new ;
Hope that this will be helpful for someone worrying with ” ./configure command not found ” in mysql latest version.
How to reset mysql root password : click here 🙂
Recent Comments