Posts tagged Percona
MySQL – Percona – Release Notes – Identifying Changes Between Versions
0I run Percona MySQL on all my CentOS servers by way of the Percona MySQL RPM. So every time I run `yum update` Percona MySQL also gets updated. Unfortunately, when yum reports back with the packages that will be updated, and Percona MySQL is among the list, all I see is a version number. Rather than blindly accepting the package upgrade, I would also like to see the change log, so I had to do some searching but found the 5.1, and 5.5 release notes. Posting links so others can easily access the release notes every time a new release makes it way through a yum update.
Linux – CentOS – 6 – Installing Percona MySQL
0If you are looking to install Percona MySQL on a CentOS 6 server, you will need to install the ‘Percona-Server-shared-compat.x86_64′ package, if you don’t, you will end up with errors when installing the ‘Percona-Server-server-55.x86_64′ package.
MySQL – Percona – PID File Could not be Found
2If you ever come across a “MySQL (Percona Server) PID file could not be found” message when trying to restart, or stop your MySQL server there is an easy fix. Simply check the current running processes and get the PID of the MySQL process, then echo it into the pid file.
Example:
$ -> ps -auxfw | ack mysql mysql 26519 0.1 23.2 755928 101344 pts/1 Sl 05:51 0:00 \_ /usr/sbin/mysqld --basedir=/usr --datadir=/var/lib/mysql --plugin-dir=/usr/lib64/mysql/plugin --user=mysql --log-error=/var/log/mysql/error.log --pid-file=/var/lib/mysql/myhost.pid --socket=/var/lib/mysql/mysql.sock --port=3306 $ -> echo 26519 > /var/lib/mysql/myhost.pid $ -> /etc/init.d/mysql stop /etc/init.d/mysql stopShutting down MySQL (Percona Server).... [ OK ]
Now you should be able to start your MySQL server like normal.
MySQL – Percona – Setting Character Sets and Collations to UTF8
0This morning I was reinstalling Percona-Server-server (v5.5.13) via Yum on my CentOS box and decided to dig into the my.cnf file a bit and make sure I had everything setup correctly. Lo and behold, I did not. I noticed that a few of my charset and collation settings were using latin1 when they should have been using UTF8.
Being a DBA newb, I tried to set server variables like ‘character_set_database’ only to see the following error messages: “110726 20:24:04 [ERROR] /usr/sbin/mysqld: unknown variable ‘character_set_database=utf8′”. I read the docs on mysql.com @ http://dev.mysql.com/doc/refman/5.5/en/server-system-variables.html#sysvar_character_set_database and couldn’t see what the problem was. It was listed as a ‘Global’ option, however if you scroll up to “Table 5.2″ you will notice that character_set_database cmd-line option is blank, which I assume means it cannot be set via the my.cnf file. I believe this setting can be set during ‘CREATE DATABASE’ commands, but I didn’t want to have to do this every time I created a database.
So I did some toying around and found the ‘character_set_server’ and ‘collation_server’ settings will actually control the children settings (database, table, etc). So all you have to do to ensure consistent utf8 for your mysql server is to add the following to your my.cnf file:
character_set_server = utf8 collation_server = utf8_general_ci
Be sure to restart the daemon, then you can issue the following commands:
# Show me collation settings mpurcell@dev1 ~ $ -> mysql -e "show variables" -u mpurcell -p | fgrep -i collat Enter password: collation_connection utf8_general_ci collation_database utf8_general_ci collation_server utf8_general_ci # Show me charset settings mpurcell@dev1 ~ $ -> mysql -e "show variables" -u mpurcell -p | fgrep -i char Enter password: character_set_client utf8 character_set_connection utf8 character_set_database utf8 character_set_filesystem binary character_set_results utf8 character_set_server utf8 character_set_system utf8 character_sets_dir /usr/share/mysql/charsets/
Now your mysql server is setup to store and collate in UTF8.