Upgrade to Percona Server on a WHM/Cpanel Server or VPS [Deleted]

Slavik

XenForo moderator
Staff member
Slavik submitted a new resource:

Upgrade to Percona Server on a WHM/Cpanel Server or VPS - Supercharge your XenForo Board by installing Percona Server on WHM/Cpanel

The following steps are normally safe to run, however should still be undertaken by experienced server admins, I am not responsible for any possible data loss caused as a result of following these steps.

This guide will show you how to remove the standard MySQL from a WHM/Cpanel server or VPS and replace it with Percona MySQL Server.

Percona is a high performance MySQL server with many advanced features focused on InnoDB performance (of which XenForo relies heavily).


Stop MySQL...

Read more about this resource...
 
This looks brilliant - a very clear and concise guide to something I was wondering about how to achieve. How are updates handled once you do this? Does cPanel update Percona as part of the usual yum update procedures?
 
This looks brilliant - a very clear and concise guide to something I was wondering about how to achieve. How are updates handled once you do this? Does cPanel update Percona as part of the usual yum update procedures?


Yes
 
Set the Yum update parameters to ignore PHP again.(the following is a manual step not an SSH command)

Code:
Open /etc/yum.conf and re-add php that you removed earlier
I assume you mean "Set the Yum update parameters to use PHP again"?
 
So what would be the pros and cons to doing this versus just sticking to mysql?? I'm kinda confused on what this does.
 
So what would be the pros and cons to doing this versus just sticking to mysql?? I'm kinda confused on what this does.

Pretty much this: Percona is a high performance MySQL server with many advanced features focused on InnoDB performance (of which XenForo relies heavily).

It also comes with a variety of other cool tools for backups and diagnostics.
 
@Slavik,

Just wondering dude. If I do all these, will whm hook into the percona server? So if I create a database via cpanel, will it create it in percona?

Thanks.
 
Hi @Slavik

Sorry for bumpind this up, since it become a real option for me, some questions; is the tutorial still up to date? Will for instance restart & stop MySQL when I use WHM start & stop services?

Thanks.
 
Should be.

There is this line inside my yum.conf

exclude=bind-chroot courier* dovecot* exim* filesystem httpd* mod_ssl* mydns* mysql* nsd* php* proftpd* pure-ftpd* ruby* spamassassin* squirrelmail*

Should I remove php* from there?

Also When I run this: yum --disablerepo=php

I'm getting this error: Error getting repository data for php, repository not found
 
Getting also an error when I try to run mysql_upgrade

Looking for 'mysql' as: mysql
FATAL ERROR: Can't execute 'mysql'
 
There is this line inside my yum.conf

exclude=bind-chroot courier* dovecot* exim* filesystem httpd* mod_ssl* mydns* mysql* nsd* php* proftpd* pure-ftpd* ruby* spamassassin* squirrelmail*

Should I remove php* from there?

Yes, so your yum.conf file should be:

Code:
exclude=bind-chroot courier* dovecot* exim* filesystem httpd* mod_ssl* mydns* mysql* nsd* proftpd* pure-ftpd* ruby* spamassassin* squirrelmail*

You'll add php* back in later on when you are done

Also When I run this: yum --disablerepo=php

I'm getting this error: Error getting repository data for php, repository not found
Why are you running that? Just copy and paste the commands Slavik has put in the guide.
 
Getting also an error when I try to run mysql_upgrade

Looking for 'mysql' as: mysql
FATAL ERROR: Can't execute 'mysql'
Given you are having issues with the PHP part, have you actually upgraded to Percona, and started MySQL before trying to run that command?
 
Given you are having issues with the PHP part, have you actually upgraded to Percona, and started MySQL before trying to run that command?
PHP:
yum install Percona-Server-client-55 Percona-Server-server-55 Percona-Server-devel-55
base                                                     | 3.7 kB     00:00
extras                                                   | 3.4 kB     00:00
percona                                                  |  951 B     00:00
percona/primary                                          |  51 kB     00:00
percona                                                                 166/166
updates                                                  | 3.4 kB     00:00
Setting up Install Process
Resolving Dependencies
--> Running transaction check
---> Package Percona-Server-client-55.x86_64 0:5.5.35-rel33.0.611.rhel6 will be installed
--> Processing Dependency: Percona-Server-shared-55 for package: Percona-Server-client-55-5.5.35-rel33.0.611.rhel6.x86_64
---> Package Percona-Server-devel-55.x86_64 0:5.5.35-rel33.0.611.rhel6 will be installed
---> Package Percona-Server-server-55.x86_64 0:5.5.35-rel33.0.611.rhel6 will be installed
--> Running transaction check
---> Package Percona-Server-shared-55.x86_64 0:5.5.35-rel33.0.611.rhel6 will be installed
--> Finished Dependency Resolution

Dependencies Resolved

================================================================================
Package                    Arch     Version                    Repository
                                                                           Size
================================================================================
Installing:
Percona-Server-client-55   x86_64   5.5.35-rel33.0.611.rhel6   percona   6.2 M
Percona-Server-devel-55    x86_64   5.5.35-rel33.0.611.rhel6   percona   2.8 M
Percona-Server-server-55   x86_64   5.5.35-rel33.0.611.rhel6   percona    15 M
Installing for dependencies:
Percona-Server-shared-55   x86_64   5.5.35-rel33.0.611.rhel6   percona   644 k

Transaction Summary
================================================================================
Install       4 Package(s)

Total download size: 25 M
Installed size: 104 M
Is this ok [y/N]: y
Downloading Packages:
(1/4): Percona-Server-client-55-5.5.35-rel33.0.611.rhel6 | 6.2 MB     00:09
(2/4): Percona-Server-devel-55-5.5.35-rel33.0.611.rhel6. | 2.8 MB     00:05
(3/4): Percona-Server-server-55-5.5.35-rel33.0.611.rhel6 |  15 MB     00:26
(4/4): Percona-Server-shared-55-5.5.35-rel33.0.611.rhel6 | 644 kB     00:01
--------------------------------------------------------------------------------
Total                                           574 kB/s |  25 MB     00:44
warning: rpmts_HdrFromFdno: Header V4 DSA/SHA1 Signature, key ID cd2efd2a: NOKEY
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-percona
Importing GPG key 0xCD2EFD2A:
Userid : Percona MySQL Development Team <mysql-dev@percona.com>
Package: percona-release-0.0-1.x86_64 (installed)
From   : /etc/pki/rpm-gpg/RPM-GPG-KEY-percona
Is this ok [y/N]: y
Running rpm_check_debug
Running Transaction Test
Transaction Test Succeeded
Running Transaction
  Installing : Percona-Server-shared-55-5.5.35-rel33.0.611.rhel6.x86_64     1/4
  Installing : Percona-Server-client-55-5.5.35-rel33.0.611.rhel6.x86_64     2/4
  Installing : Percona-Server-server-55-5.5.35-rel33.0.611.rhel6.x86_64     3/4
Percona Server is distributed with several useful UDF (User Defined Function) from Maatkit.
Run the following commands to create these functions:
mysql -e "CREATE FUNCTION fnv1a_64 RETURNS INTEGER SONAME 'libfnv1a_udf.so'"
mysql -e "CREATE FUNCTION fnv_64 RETURNS INTEGER SONAME 'libfnv_udf.so'"
mysql -e "CREATE FUNCTION murmur_hash RETURNS INTEGER SONAME 'libmurmur_udf.so'"
See http://code.google.com/p/maatkit/source/browse/trunk/udf for more details
  Installing : Percona-Server-devel-55-5.5.35-rel33.0.611.rhel6.x86_64      4/4
  Verifying  : Percona-Server-server-55-5.5.35-rel33.0.611.rhel6.x86_64     1/4
  Verifying  : Percona-Server-shared-55-5.5.35-rel33.0.611.rhel6.x86_64     2/4
  Verifying  : Percona-Server-client-55-5.5.35-rel33.0.611.rhel6.x86_64     3/4
  Verifying  : Percona-Server-devel-55-5.5.35-rel33.0.611.rhel6.x86_64      4/4

Installed:
  Percona-Server-client-55.x86_64 0:5.5.35-rel33.0.611.rhel6
  Percona-Server-devel-55.x86_64 0:5.5.35-rel33.0.611.rhel6
  Percona-Server-server-55.x86_64 0:5.5.35-rel33.0.611.rhel6

Dependency Installed:
  Percona-Server-shared-55.x86_64 0:5.5.35-rel33.0.611.rhel6

Complete!
root@linger [~]# /etc/init.d/mysql start
Starting MySQL (Percona Server).... SUCCESS!
root@linger [~]# mysql_upgrade
Looking for 'mysql' as: mysql
FATAL ERROR: Can't execute 'mysql'
root@linger [~]# mysql_upgrade
Looking for 'mysql' as: mysql
FATAL ERROR: Can't execute 'mysql'
root@linger [~]# mysql_upgrade
Looking for 'mysql' as: mysql
FATAL ERROR: Can't execute 'mysql'
root@linger [~]# /etc/init.d/mysql restart
Shutting down MySQL (Percona Server)................. SUCCESS!
Starting MySQL (Percona Server)..... SUCCESS!
root@linger [~]# /etc/init.d/mysql start
Starting MySQL (Percona Server) SUCCESS!
root@linger [~]# mysql_upgrade
Looking for 'mysql' as: mysql
FATAL ERROR: Can't execute 'mysql'
root@linger [~]# ^C
root@linger [~]#
 
try running it as the root user for MySQL

Do you have anything inside this file?
Code:
/root/.my.cnf
 
try running it as the root user for MySQL

Do you have anything inside this file?
Code:
/root/.my.cnf

[client]
password="pass"
user=root

But the pass is not my root server's password, it's a password that I'm not familiar with.

"try running it as the root user for MySQL"
Do you have it top of your hat Matt, the command?

Thank you.
 
[client]
password="pass"
user=root

But the pass is not my root server's password, it's a password that I'm not familiar with.

"try running it as the root user for MySQL"
Do you have it top of your hat Matt, the command?

Thank you.
It's not your servers root password, it's your MySQL root users password.

Code:
mysql_upgrade -u root -p
it will ask you for the password. Use the one in that file.
 
Top Bottom