Facing issue while configuring MySql with apache airflow in Hadoop - mysql

I was trying to install and configure apache airflow on dev Hadoop cluster of a three nodes with below configurations/version:
Operating System: Red Hat Enterprise Linux Server 7.7
python 3.7.3
anaconda 2
spark 2.45
a)sudo yum install gcc gcc-c++ -y
b)sudo yum install libffi-devel mariadb-devel cyrus-sasl-devel -y
c)pip install 'apache-airflow[all]'
d)airflow initdb -- airflow.cfgfile was created with SQLlite
Then I followed below set of commands to configure it with mysql
a) rpm -Uvh https://repo.mysql.com/mysql80-community-release-el7-3.noarch.rpm
b) sed -i 's/enabled=1/enabled=0/' /etc/yum.repos.d/mysql-community.repo
c) yum --enablerepo=mysql80-community install mysql-community-server
d) systemctl start mysqld.service
Done below things at mysql
a) CREATE DATABASE airflow CHARACTER SET utf8 COLLATE utf8_unicode_ci;
b) create user 'airflow'#'localhost' identified by 'Airflow123';
c) grant all privileges on * . * to 'airflow'#'localhost';
here are some details from my airflow.cfg file
broker_url = sqla+mysql://airflow:airflow#localhost:3306/airflow
result_backend = db+mysql://airflow:airflow#localhost:3306/airflow
sql_alchemy_conn = mysql://airflow:Airflow123#localhost:3306/airflow
executor = CeleryExecutor
I am getting below error while running airflow initdb commands
ImportError: /home/xyz/anaconda2/envs/python3.7.2/lib/python3.7/site-packages/_mysql.cpython-37m-x86_64-linux-gnu.so: symbol mysql_real_escape_string_quote,
version libmysqlclient_18 not defined in file libmysqlclient.so.18 with link time reference
have set up the .bashrc file as:
export AIRFLOW_HOME=~/airflow
here's my directory created:
[xyz#innolx5984 airflow]$ pwd
/home/xyz/airflow
When I look for this file "libmysqlclient" I have found these many instances.
[xyz#innolx5984 airflow]$ find /home/xyz/ -name "*libmysqlclient*"
/home/xyz/anaconda2/pkgs/mysql-connector-c-6.1.11-h597af5e_1/lib/libmysqlclient.so
/home/xyz/anaconda2/pkgs/mysql-connector-c-6.1.11-h597af5e_1/lib/libmysqlclient.a
/home/xyz/anaconda2/pkgs/mysql-connector-c-6.1.11-h597af5e_1/lib/libmysqlclient.so.18
/home/xyz/anaconda2/pkgs/mysql-connector-c-6.1.11-h597af5e_1/lib/libmysqlclient.so.18.4.0
/home/xyz/anaconda2/lib/libmysqlclient.a
/home/xyz/anaconda2/lib/libmysqlclient.so
/home/xyz/anaconda2/lib/libmysqlclient.so.18
/home/xyz/anaconda2/lib/libmysqlclient.so.18.4.0
Just adding few more details in case it helps.
[xyz#innolx5984 airflow]$ mysql_config
Usage: /home/xyz/an
aconda2/bin/mysql_config [OPTIONS]
Options:
--cflags [-I/home/xyz/anaconda2/include ]
--cxxflags [-I/home/xyz/anaconda2/include ]
--include [-I/home/xyz/anaconda2/include]
--libs [-L/home/xyz/anaconda2/lib -lmysqlclient ]
--libs_r [-L/home/xyz/anaconda2/lib -lmysqlclient ]
--plugindir [/home/xyz`/anaconda2/lib/plugin]
--socket [/tmp/mysql.sock]
--port [0]
--version [6.1.11]
--variable=VAR VAR is one of:
pkgincludedir [/home/xyz/anaconda2/include]
pkglibdir [/home/xyz/anaconda2/lib]
plugindir [/home/xyz/anaconda2/lib/plugin]
Looking for some help and suggestion to resolve this
issue. I am not too sure whether heading into right direction.

Follow these steps to install Apache Airflow with MySQL using Anaconda3
1) Install Pre-requisites
yum install gcc gcc-c++ -y
yum install libffi-devel mariadb-devel cyrus-sasl-devel -y
dnf install redhat-rpm-config
2) Install Anaconda3 (comes with Python 3.7.6)
yum install libXcomposite libXcursor libXi libXtst libXrandr alsa-lib mesa-libEGL libXdamage mesa-libGL libXScrnSaver
wget https://repo.anaconda.com/archive/Anaconda3-2020.02-Linux-x86_64.sh
chmod +x Anaconda3-2020.02-Linux-x86_64.sh
./Anaconda3-2020.02-Linux-x86_64.sh
Make sure you do conda initialize when prompted during installation.
This will make sure the correct version of python and pip are used in the subsequent steps.
3) Install Apache Airflow
pip install apache-airflow[mysql,celery]
You can add other subpackages as required. I have included only the ones required for Airflow to use MySQL database as backend.
4) Initialize Airflow
export AIRFLOW_HOME=~/airflow
airflow initdb
From here, I have mimicked the steps you have followed to configure MySQL Server
5) Install MySQL Server
rpm -Uvh https://repo.mysql.com/mysql80-community-release-el7-3.noarch.rpm
sed -i 's/enabled=1/enabled=0/' /etc/yum.repos.d/mysql-community.repo
yum --enablerepo=mysql80-community install mysql-server
systemctl start mysqld.service
6) Login to MySQL and configure database for Airflow
mysql> CREATE DATABASE airflow CHARACTER SET utf8 COLLATE utf8_unicode_ci;
mysql> CREATE user 'airflow'#'localhost' identified by 'Airflow123';
mysql> GRANT ALL privileges on *.* to 'airflow'#'localhost';
7) Update Airflow configuration file (~/airflow/airflow.cfg)
sql_alchemy_conn = mysql://airflow:Airflow123#localhost:3306/airflow
executor = CeleryExecutor
8) Initialize Airflow
airflow initdb

Related

When Ubuntu 18.04 deploys zabbix4.0, the database type is PostgreSQL instead of MySQL. How can I set this to support MySQL?

In Ubuntu 18.04 server, I use binary file to install zabbix4.0 according to the official website document of zabbix4.0, and I use MySQL 5.7.30 database. After installation, when I configure the front end of zabbix4.0,In the database configuration page, I only see one option of PostgreSQL, not mysql, as shown in the following figure:
In my server, I have installed MySQL version 5.7.30, and imported the data of ZABBIX 4.0 into the ZABBIX database, without any PostgreSQL installed
Excuse me, how can I make zabbix4.0 support MySQL 5.7.30 that I have installed? Thank you!
I installed zabbix4.0 according to the official documents:
https://www.zabbix.com/documentation/4.0/zh/manual/installation/install_from_packages/debian_ubuntu
This is my installation method:
# install zabbix
cd ~/download
wget https://repo.zabbix.com/zabbix/4.0/ubuntu/pool/main/z/zabbix-
release/zabbix-release_ 4.0-2+bionic_ all.deb
sudo dpkg -i zabbix-release_ 4.0-2+bionic_ all.deb
sudo apt-get update
#install Server/proxy/
sudo apt-get install -y zabbix-server-mysql
sudo apt-get install -y zabbix-frontend-php
With Ubuntu, you got two type of databases when donwloading Zabbix, PostgreSql and MySql. You need to re-download (I mean installation and configuration) Zabbix choosing MySql as database.
The following link could help Zabbix (Ubuntu) with MySql as database
The current version of the package is 4.0-3, so instead, you must do this :
Install repository
# wget https://repo.zabbix.com/zabbix/4.0/ubuntu/pool/main/z/zabbix-release/zabbix-release_4.0-3+bionic_all.deb
# sudo dpkg -i zabbix-release_4.0-3+bionic_all.deb
# sudo apt update
Install server, frontend, agent
# sudo apt install zabbix-server-mysql zabbix-frontend-php zabbix-agent

Installation Requirements for mysql with DBIish on rakudo-star docker image

I was creating an own docker image based on the latest rakudo-star docker image. I wanted to use DBIish to connect to a mysql database. Unfortunately I am not able to get the DBDish::mysql to work.
I've installed default-libmysqlclient-dev as you can see in
# find / -name 'libmysqlclient*.so'
/usr/lib/x86_64-linux-gnu/libmysqlclient_r.so
/usr/lib/x86_64-linux-gnu/libmysqlclient.so
The error i am facing is:
# perl6 -Ilib -e 'use DBDish::mysql; DBDish::mysql.connect()'
Cannot locate native library 'mysqlclient': mysqlclient: cannot open shared object file: No such file or directory
in method setup at /usr/share/perl6/sources/24DD121B5B4774C04A7084827BFAD92199756E03 (NativeCall) line 289
in method CALL-ME at /usr/share/perl6/sources/24DD121B5B4774C04A7084827BFAD92199756E03 (NativeCall) line 539
in method connect at /root/DBIish/lib/DBDish/mysql.pm6 (DBDish::mysql) line 12
in block <unit> at -e line 1
Short answer: you need the package libmysqlclient20 (I added the documentation request to a similar DBIish issue). Debian 9 (stable at the moment) uses and older version than Ubuntu 18.04 (stable at the moment) and Debian Unstable. It also refers to mariadb instead of mysql. Pick libmariadbclient18 on images based on Debian Stable and create a link with the mysql name (see below).
On Debian Testing/Unstable and recent derivatives:
$ sudo apt-get install libmysqlclient20
$ dpkg -L libmysqlclient20
/.
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/libmysqlclient.so.20.3.9
/usr/share
/usr/share/doc
/usr/share/doc/libmysqlclient20
/usr/share/doc/libmysqlclient20/NEWS.Debian.gz
/usr/share/doc/libmysqlclient20/changelog.Debian.gz
/usr/share/doc/libmysqlclient20/copyright
/usr/lib/x86_64-linux-gnu/libmysqlclient.so.20
On Debian 9 and derivatives:
$ dpkg -L libmariadbclient18
/.
/usr
/usr/lib
/usr/lib/x86_64-linux-gnu
/usr/lib/x86_64-linux-gnu/libmariadbclient.so.18.0.0
/usr/lib/x86_64-linux-gnu/mariadb18
/usr/lib/x86_64-linux-gnu/mariadb18/plugin
/usr/lib/x86_64-linux-gnu/mariadb18/plugin/client_ed25519.so
/usr/lib/x86_64-linux-gnu/mariadb18/plugin/dialog.so
/usr/lib/x86_64-linux-gnu/mariadb18/plugin/mysql_clear_password.so
/usr/share
/usr/share/doc
/usr/share/doc/libmariadbclient18
/usr/share/doc/libmariadbclient18/changelog.Debian.gz
/usr/share/doc/libmariadbclient18/copyright
/usr/lib/x86_64-linux-gnu/libmariadbclient.so.18
Create the link:
$ sudo ln -s /usr/lib/x86_64-linux-gnu/libmariadbclient.so.18 /usr/lib/x86_64-linux-gnu/libmysqlclient.so.18
In order to illustrate this, I created an Ubuntu 18.04 container for the occasion*:
docker run -ti --rm --entrypoint=bash rakudo/ubuntu-amd64-18.04
And the abbreviated commands and output:
# apt-get install -y libmysqlclient20 build-essential
# zef install DBIish
# perl6 -e 'use DBDish::mysql; DBDish::mysql.connect()'
Cannot look up attributes in a DBDish::mysql type object
[...]
The error is because I didn't pass the correct parameters for connect as I didn't have a db running. The important thing is that no .so file is missing.
*: I uploaded it to the Docker Hub, a normal run will put you right in the REPL:
$ docker run -ti --rm rakudo/ubuntu-amd64-18.04
To exit type 'exit' or '^D'
>
(I didn't use the Star image when debugging, but it does not matter because this is a more generic problem.)

An error occured when creating an image using Dockerfile

I created a Dockerfile to create an image to run web based application. When I running that file and it tries to collect mysqlclient==1.3.7 ,following error is occured.
"mysql_config raise EnvironmentError("%s not found" %(mysql_config.path,))
EnvironmentError: mysql_config not found
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-build-ME9Fq7/mysqlclient/
You are using pip version 8.1.1, however version 9.0.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command. "
This is Dockerfile
############################################################
# Dockerfile to build Python WSGI Application Containers
# Based on Ubuntu
############################################################
# Set the base image to Ubuntu
FROM ubuntu:latest
# File Author / Maintainer
MAINTAINER Brian
# Add the application resources URL
#RUN echo "deb http://archive.ubuntu.com/ubuntu/ $(lsb_release -sc) main universe" >> /etc/apt/sources.list
# Update the sources list
RUN apt-get update -y;
# Install basic applications
RUN apt-get install -y tar git curl nano wget dialog net-tools build-essential
# Install Python and Basic Python Tools
RUN apt-get install -y python python3-dev python-distribute python-pip libssl-dev
# Copy the application folder inside the container
ADD /WebApp /WebApp
#RUN pip install mysql
# Get pip to download and install requirements:
RUN pip install -r /WebApp/requirements.txt
# Expose ports
EXPOSE 80
# Set the default directory where CMD will execute
WORKDIR /WebApp
# Set the default command to execute
# when creating a new container
# i.e. using CherryPy to serve the application
CMD ./start.sh
How can I solve this problem?
I believe that you are trying to install the mysql driver for Python, but you don't have MySQL installed. Try to install MySQL before installing mysql driver:
RUN apt-get install mysql-server
Hope it helps!

mysqli extension is missing debian

i m try to install mysql-sever on debian (WD mycloud live)
i have tried everything i found on google but no success
/etc/php5/conf.d/mysqli.ini Dont exists
for install i used apt-get -f mysql-server mysql-client mysql-common
so far i have
mysql running
PHP Version 5.4.11-1
Linux WDMyCloud 3.2.26 #1 SMP Fri Dec 27 13:50:41 PST 2013 armv7l
Additional .ini files parsed
/etc/php5/apache2/conf.d/10-pdo.ini,
/etc/php5/apache2/conf.d/20-apc.ini,
/etc/php5/apache2/conf.d/20-curl.ini,
/etc/php5/apache2/conf.d/20-pdo_sqlite.ini,
/etc/php5/apache2/conf.d/20-sqlite3.ini,
/etc/php5/apache2/conf.d/include_path.ini
mysql -- version -> mysql ver 14.14 distrib 5.5.35, for debian-linux-gnu (armv71) using readline 6.2
i installed webmin there i can see my mysql-server information, i have there
Path to mysqlshow command - /usr/bin/mysqlshow
Path to mysqladmin command - /usr/bin/mysqladmin
Path to mysql command - /usr/bin/mysql
Path to mysqldump command - /usr/bin/mysqldump
Path to mysqlimport command - /usr/bin/mysqlimport
MySQL configuration file - /etc/mysql/my.cnf
Mysql Unix socket - /var/run/mysqld/mysqld.sock
Database files directory - /var/lib/mysql
sudo apt-get install php5-mysql
Will install package containing both old one and the new one, so afterwards all you need to do is to add
extension=mysqli.so
in your php.ini, restart apache and it should work.
Source:
https://stackoverflow.com/a/10835420/3566788
I encountered above issue while configuring 'phpmyadmin' for php5.7 and mysql#5 combination that was required for one of my old raspberry pi projects.
In my case when I tried the
sudo apt-get install php5-mysql
I got error -
E: Package 'php5-mysqli' has no installation candidate
The error also mentioned about the replacement packages,
Package php5-mysqli is not available, but is referred to by another
package. This may mean that the package is missing, has been
obsoleted, or is only available from another source However the
following packages replace it: php5-mysqlnd php5-mysql
I executed following and it worked for me.
sudo apt install php5-mysqlnd
Hope it helps.

Update MySQL version from 5.1 to 5.5 in CentOS 6.2

I tried to update MySQL from 5.1 to 5.5 in CentOS 6.2. The following is the process I did:
1. rpm -Uvh http://repo.webtatic.com/yum/centos/5/latest.rpm
2. yum install libmysqlclient15 --enablerepo=webtatic
3. yum remove mysql mysql-*
4. yum install mysql55 mysql55-server --enablerepo=webtatic
When I tried the 4th step, I got the following output:
[root#d2005 /]# yum install mysql55 mysql55-server --enablerepo=webtatic
Failed to set locale, defaulting to C
Loaded plugins: fastestmirror, presto
Loading mirror speeds from cached hostfile
* base: yum.singlehop.com
* extras: centos.mirrors.tds.net
* updates: pubmirrors.reflected.net
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package mysql55.x86_64 0:5.5.10-1.w5 will be installed
--> Processing Dependency: mysql55-libs = 5.5.10-1.w5 for package: mysql55-5.5.10-1.w5.x86_64
---> Package mysql55-server.x86_64 0:5.5.10-1.w5 will be installed
--> Processing Dependency: perl-DBD-MySQL for package: mysql55-server-5.5.10-1.w5.x86_64
--> Running transaction check
---> Package mysql55-libs.x86_64 0:5.5.10-1.w5 will be installed
---> Package perl-DBD-MySQL.x86_64 0:4.013-3.el6 will be installed
--> Processing Dependency: libmysqlclient.so.16(libmysqlclient_16)(64bit) for package: perl-DBD-MySQL-4.013-3.el6.x86_64
--> Processing Dependency: libmysqlclient.so.16()(64bit) for package: perl-DBD-MySQL-4.013-3.el6.x86_64
--> Running transaction check
---> Package mysql-libs.x86_64 0:5.1.61-1.el6_2.1 will be installed
--> Processing Conflict: mysql55-libs-5.5.10-1.w5.x86_64 conflicts mysql-libs < 5.5.10
--> Finished Dependency Resolution
Error: mysql55-libs conflicts with mysql-libs
You could try using --skip-broken to work around the problem
You could try running: rpm -Va --nofiles --nodigest
How to fix it?
To list Old MySql
yum list installed | grep -i mysql
To remove Old MySql
yum remove mysql mysql-*
Remi Dependency on CentOS 6 and Red Hat (RHEL) 6
rpm -Uvh http://dl.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
Install MySQL server
yum --enablerepo=remi,remi-test install mysql mysql-server
To list New MySql
yum list installed | grep -i mysql
start MySql server
/etc/init.d/mysqld start ## use restart after update
OR
service mysqld start ## use restart after update
chkconfig --levels 235 mysqld on
Last
mysql_upgrade -u root -p
Now my MySql version is 5.5.32
Ref:
http://www.webtatic.com/packages/mysql55/
http://www.if-not-true-then-false.com/2010/install-mysql-on-fedora-centos-red-hat-rhel/
Hope it help some one
NOTE:
Adding comments from #pim (in comments)
Just wanted to add that after the upgrade, my crontab was removed as well. Had to reinstall with "yum install vixie-cron" (CentOS 6)
I used the following commands to add a new YUM repo and make the update:
Download the Remi repo
cd /etc/yum.repos.d
wget http://rpms.famillecollet.com/enterprise/remi.repo
Install/Update the mysql version
yum --enablerepo=remi install mysql-server
OR
yum --enablerepo=remi update mysql-server
You appear to have been using the wrong Webtatic Yum repository version than the one for your version of CentOS. See http://www.webtatic.com/projects/yum-repository/ for details
e.g.
rpm -Uvh http://mirror.webtatic.com/yum/el6/latest.rpm
You can use a yum plugin made by the IUS community to switch mysql-libs with mysql55w-libs. (the following assuming you still use Webtatic)
yum install mysql yum-plugin-replace
yum replace mysql --replace-with mysql55w
That should allow you to replace mysql with mysql55w-libs, whilst maintaining the older libmysqlclient for any dependencies.
If you see other packages than mysql being removed, then be careful, as they might be needed, but using this method, I've found to be reliable whenever I've used it.
I'm posting this solution as Remi's repository is not always the ideal solution. This method is more complex, but would never cause you to accidentally update your entire web stack by using repositories that use package names matching base distribution packages.
2015/08/19 - For those of you working on older (but still decent) hardware with a matching OS (typically 32 bit machines).
-- This will upgrade to mysql 5.6 community not 5.5 --
This worked for me after some research and mixing/matching/testing the answers found on various page of the internet (mainly from this page and http://dev.mysql.com/doc/refman/5.6/en/linux-installation-yum-repo.html).
My OS shipped with mysql 5.1, I wanted to have 5.6.
My system
[root#host]# cat /etc/*release
CentOS release 6.7 (Final)
[root#host]# uname -a
Linux host 2.6.32-573.3.1.el6.i686 #1 SMP Thu Aug 13 19:58:36 UTC 2015 i686 i686 i386 GNU/Linux
[root#host]# arch
i686
This is installed on a 2006 mac pro 1.1 (CPUs upgraded to 3.0GHz Intel Xeon X5365 Quad-Core).
Commands I ran
This was done almost immediately after a fresh install of the OS and system update via yum
list mysql currently installed
yum list installed | grep -i mysql
remove installed msql
yum remove mysql mysql-*
list mysql currently installed
yum list installed | grep -i mysql
Download rpm containing mysql 5.6
wget http://dev.mysql.com/get/mysql-community-release-el6-5.noarch.rpm
Install mysql
rpm -Uvh mysql-community-release-el6-5.noarch.rpm
yum install mysql mysql-server
list mysql currently installed
yum list installed | grep -i mysql
ensure mysql starts on reboot
chkconfig --list mysqld
sudo chkconfig mysqld on
chkconfig --list mysqld
Start mysql
service mysqld start
service mysqld status
Result
[root#host]# yum list installed | grep -i mysql
compat-mysql51.i686 5.1.54-1.el6.remi #remi
mysql-community-client.i686
5.6.26-2.el6 #mysql56-community
mysql-community-common.i686
5.6.26-2.el6 #mysql56-community
mysql-community-libs.i686
5.6.26-2.el6 #mysql56-community
mysql-community-release.noarch
mysql-community-server.i686
5.6.26-2.el6 #mysql56-community
perl-DBD-MySQL.i686 4.013-3.el6 #base
[root#host]# mysql --version
mysql Ver 14.14 Distrib 5.6.26, for Linux (i686) using EditLine wrapper
mysql config (I did not touch this yet but the info seems legit)
Some interesting basic but efficient performance tuning for mysql:
https://www.digitalocean.com/community/tutorials/how-to-install-mysql-5-6-from-official-yum-repositories
Good luck!
Edit
I had some issues creating users and granting permissions, this how it was fixed.
Error
ERROR 1054 (42S22) at line 1: Unknown column 'plugin' in 'mysql.user'
Fix
Logged on the server as root
Connected to mysql with a simple mysql
Checked the outcome of this statement: SELECT COUNT(1) column_count FROM information_schema.columns WHERE table_schema='mysql' AND table_name='user'; The result was 39, 43 is expected for mysql 5.6
Issued this statement to update the root password: update mysql.user set Password=PASSWORD('root') where User='root';
(Logged off mysql with exit)
Restarted mysql with: service mysqld restart
Ran: mysql_upgrade -uroot -proot --force
Reconnected to mysql with mysql -uroot -proot
Checked the outcome of this statement: SELECT COUNT(1) column_count FROM information_schema.columns WHERE table_schema='mysql' AND table_name='user'; The result was 43 as expected for mysql 5.6. I was then able to create my users and grant permissions as needed.
Above replies didn't work for me (got this error - error: /var/tmp/rpm-tmp.tyukGy: not an rpm package).
I followed these steps -
## Remove existing/old MySQL ##
yum remove mysql mysql-*
rm -rf /var/lib/mysql
rm -rf /var/log/mysql*
## Install Remi Repository on RHEL/CentOS 6.7-6.0 ##
rpm -Uvh http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-7.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm
## Install Remi Repository on RHEL/CentOS 5.4-5.0 ##
rpm -Uvh http://dl.fedoraproject.org/pub/epel/5/i386/epel-release-5-4.noarch.rpm
rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-5.rpm
yum --enablerepo=remi list mysql mysql-server
yum --enablerepo=remi install mysql mysql-server
Taken from - http://www.tecmint.com/install-mysql-on-rhel-centos-6-5-fedora-17-12/
By doing above, i uninstalled MySQL 5.0.* and replaced it with this -
[root#localhost]# /usr/bin/mysqladmin -u root -p version
/usr/bin/mysqladmin Ver 8.42 Distrib 5.5.28, for Linux on x86_64
Copyright (c) 2000, 2012, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Server version 5.5.28
Protocol version 10
Connection Localhost via UNIX socket
UNIX socket /var/lib/mysql/mysql.sock
Uptime: 32 sec
Threads: 1 Questions: 3 Slow queries: 0 Opens: 33 Flush tables: 1 Open tables: 26 Queries per second avg: 0.093
[root#localhost]#
My CentOS version -
[root#localhost]# cat /etc/redhat-release
CentOS release 6.3 (Final)
[root#localhost]# uname -a
Linux localhost.localdomain 2.6.32-279.14.1.el6.x86_64 #1 SMP Tue Nov 6 23:43:09 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux
Use CentOS-Release-SCL is better and easy.
The Software Collections ( SCL ) Repository
# yum install centos-release-SCL
# yum install mysql55-mysql-server
Done.
This blog post helped me upgrade from MySQL 5.5.15 to 5.5.28. That upgrade also had the problem with mysql-libs clashing with mysql55-libs.
wget -P /etc/yum.repos.d http://rpms.famillecollet.com/enterprise/remi.repo
yum --enablerepo=remi -y install mysql-server
OR
yum --enablerepo=remi -y update mysql-server