Web Hosting Talk







View Full Version : upgrade to mysql 4 in cpanel


solyalex
06-24-2003, 02:09 PM
hi

i upgrade now to mysql 4 from cpanel.... and then do easy apache..


will i got a database coruption ????????

coz i see mysql Client API version 3.23.49

Configure Command

'./configure' '--with-apxs=/usr/local/apache/bin/apxs' '--with-xml' '--enable-bcmath' '--enable-calendar' '--enable-ftp' '--with-gd' '--with-jpeg-dir=/usr/local' '--with-png-dir=/usr' '--with-xpm-dir=/usr/X11R6' '--enable-magic-quotes' '--with-mysql' '--with-pear' '--enable-sockets' '--enable-track-vars' '--with-ttf' '--with-freetype-dir=/usr' '--enable-gd-native-ttf' '--enable-versioning' '--with-zlib'


alot of people say that php must compiled with mysql and give path not --with mysql

SPaReK
06-24-2003, 03:38 PM
You will need to recompile PHP and specify the directory to MySQL. Try changing to the directory where the PHP source is. Usually:

/home/cpapachebuild/buildapache/php-4.3.1

or something similar, depending on what version of PHP you are running. Then rerun the configuration script, but specify the path to MySQL:

./configure --with-apxs=/usr/local/apache/bin/apxs --with-xml --enable-bcmath --enable-calendar --enable-ftp --with-gd --with-jpeg-dir=/usr/local --with-png-dir=/usr --with-xpm-dir=/usr/X11R6 --enable-magic-quotes --with-mysql=/usr --with-pear --enable-sockets --enable-track-vars --with-ttf --with-freetype-dir=/usr --enable-gd-native-ttf --enable- versioning --with-zlib

Then do a 'make' and a 'make install'

You will probably need to restart Apache for the new PHP module to be recognized. You might consider backing up your libphp4.so module file in /etc/httpd/libexec before recompiling PHP.

solyalex
06-24-2003, 06:27 PM
soo thereis no way to do that throw easy apache...........


does all cpanel users do that ... to make mysql 4 run...... i think that cpanel solve the problem


also read this on mysql web site


http://mysql.mirror.stop.hu/downloads/mysql-4.0.html

Linux Advisory: Several of our users have reported random table corruption with Linux kernel 2.2.14 under heavy load. The table corruptions went away after an upgrade to a newer kernel. It appears that version 2.2.14 of the Linux kernel has a bug in the I/O implementation. Under some rather rare circumstances, the kernel will write incorrect data to the disk.

We recommend that all users currently running Linux kernel version 2.2.14 upgrade to the most recent version, which is of this writing, version 2.2.21

Nymix-CB
06-24-2003, 06:32 PM
When you guys will learn that CPanel can't do everything...damn learn something about your servers! We do not have any Control Panels, we don't use them and we don't like them. All manually...

When a customer will need GD installed on PHP, you are gonna look at easyapache and say DAH he's not there. "What do I do?????"...

Buy yourself a quick linux book and do it in SSH, it's so simple!

solyalex
06-24-2003, 06:36 PM
:) realy we got cpanel to give as a user backend

we was having plain servers in the past and it was running great ..... coz you control every thing on the server ......


but with cpanel you will got afraid to upgrade a program coz its may make system unstable .... soo control panel = you dont control any thing ....... :)

solyalex
06-25-2003, 01:09 PM
the databases start coruption frpm today......

sasha
06-25-2003, 01:46 PM
cpanel upgrade script is broken and even if you specify not to use built-in mysql, but rather the one installed, it will still use built-in version. The reason for this is some error in logic while buildscript is created.

This is my (mosltly ignored ) post on cpanel forums.


export WITHMYSQL="--with-mysql"
if [ -e "/usr/local/bin/mysql" ]; then
export WITHMYSQL="--with-mysql=/usr/local"
fi
if [ -e "/usr/bin/mysql" ]; then
export WITHMYSQL="--with-mysql=/usr"
fi
export WITHMYSQL="--with-mysql"

Obviously that the last line should not be there, if you want to build php with system mysql libs.


You can still use cpanel upgrade if you edit the buildscript after upgrade starts, but before it starts building PHP, and remove the last
export WITHMYSQL="--with-mysql"
line.

This WILL NOT prevent database corruption. Couple things you have to do after are:
1. fix mysql priviledges (read upgrade README on mysql website)
2. check and optimize all mysql databases (myismchk)
3. Make sure you hace proper my.cnf file. (often in /etc/my.cnf, but check your mysql startup script to make sute this is the location). Search on rackshack forums for thread that has mysql config that works very well for many hosts.

Btw in not-related issue, be ready to find out CLI and CGI versions of PHP installed on your system after this. One in /usr/bin and other one in /usr/local/bin

does this confirm rumours that CPANEL is secretly run by that Redmond company whose name I dare not pronaunce??