Koozali.org: home of the SME Server

MySQL 3 or 4 in SME 6?

Jesper Bille Haun

MySQL 3 or 4 in SME 6?
« on: June 26, 2003, 02:23:03 PM »
Does anyone know which version of MySQL is in SME 6b?

Dave

Re: MySQL 3 or 4 in SME 6?
« Reply #1 on: June 26, 2003, 11:18:25 PM »
SME 6beta2 reports MySQL 3.23.56

Dave

Jesper Bille Haun

Re: MySQL 3 or 4 in SME 6?
« Reply #2 on: June 27, 2003, 04:55:55 PM »
Thank you. What a shame. Version 4 is much better and in production. It is no longer a beta. It has been stable for several months.

Dan Brown

Re: MySQL 3 or 4 in SME 6?
« Reply #3 on: June 27, 2003, 05:24:22 PM »
Keep in mind, SME is still fundamentally based on Redhat, and presumably this is the latest updated version of MySQL that redhat has released for 7.3.  Why is this a "shame"?

Kevin Tollison

Re: MySQL 3 or 4 in SME 6?
« Reply #4 on: July 01, 2003, 06:52:47 PM »
What would it take and how much stuff would it break to upgrade SME 5.6 of 6.0 to MySQL 4.0?  I would like to work on a project like this because the new version on InfoCenteral (www.infocentral.org)(http://www.kwtconsulting.com/infocentral/infocentral-howto.htm) requires version
4 for some of its functions.  It is using the UNION operator and will eventually use  InnoDB tables which support transactions.  I am also interested in the OpenGIS support in the upcoming 4.1 release (http://www.mysql.com/events/uc2003/highlights.html).

Any takers?  I will research it for a few days then post in devinfo.

Kevin

Noah Berlove

Re: MySQL 3 or 4 in SME 6?
« Reply #5 on: July 03, 2003, 10:56:50 PM »
Dan Brown wrote:
>
> Keep in mind, SME is still fundamentally based on Redhat, and
> presumably this is the latest updated version of MySQL that
> redhat has released for 7.3.  Why is this a "shame"?

One simple reason -- Red Hat's rpm's are not as good as the ones from MySQL.  

Noah

Noah Berlove

Re: MySQL 3 or 4 in SME 6?
« Reply #6 on: July 03, 2003, 11:17:08 PM »
Kevin,

Upgrading MySQL is not too difficult. The only catch is that the version of MySQL that comes with SME 6 (and earlier)  was installed with rpms from Red Hat.  I always use the rpms from mysql.com as they are better than the ones from Red Hat.  However, the rpms from mysql.com use different names and places files in different locations than the Red Hat rpms do (hence all the copying and moving of files below).  After downloading the latest rpm's from the mysql.com and run the following script:

#!/bin/bash
rpm -ivh --force --nodeps MySQL-server-4.0.13-0.i386.rpm
/etc/rc.d/init.d/mysql stop
rm -f /usr/libexec/mysqld
cp /usr/sbin/mysqld /usr/libexec
rm -f /etc/rc.d/rc*.d/*mysql
rm -f /etc/rc.d/init.d/mysql
rpm -ivh --force MySQL-client-4.0.13-0.i386.rpm
rpm -ivh --force MySQL-devel-4.0.13-0.i386.rpm
rpm -ivh --force MySQL-shared-compat-4.0.13-0.i386.rpm
cp /usr/lib/libmy* /usr/lib/mysql
/etc/rc.d/init.d/mysqld start
/etc/e-smith/events/actions/restart-httpd-graceful

------

If you plan on accessing MySQL from another computer on your network, you will also need to do the following on an SME 6 box:

/sbin/e-smith/config setprop mysqld LocalNetworkingOnly no
/sbin/e-smith/expand-template /root/.my.cnf
/etc/rc.d/init.d/mysqld restart

Let me know if you have any problems with this.

Noah

Jesper Bille Haun

Re: MySQL 3 or 4 in SME 6?
« Reply #7 on: July 03, 2003, 11:55:53 PM »
Thank you... That was what I needed. MySQL 4 is much better than version 3. It has better fulltext indexing, which I use.

Charlie Brady

Re: MySQL 3 or 4 in SME 6?
« Reply #8 on: July 04, 2003, 12:03:28 AM »
Noah Berlove wrote:
>The only catch is that
> the version of MySQL that comes with SME 6 (and earlier)  was
> installed with rpms from Red Hat.  I always use the rpms from
> mysql.com as they are better than the ones from Red Hat.
> However, the rpms from mysql.com use different names and
> places files in different locations than the Red Hat rpms do
> (hence all the copying and moving of files below).

When you use a package management system, such as rpm, you should allow it to do its job. No copying and moving, and no --force or --nodeps unless you know exactly what you are doing and why you are doing it.

> After
> downloading the latest rpm's from the mysql.com and run the
> following script:

I would advice people not to use that script. Instead, remove all existing mysql components:

rpm -e --nodeps mysql mysql-client mysql-server
rpm -e mysql-devel
rpm -e mysqlclient9

Then do:

rpm -Uhv MySQL-server-4.0.13-0.i386.rpm \
MySQL-client-4.0.13-0.i386.rpm \
MySQL-shared-compat-4.0.13-0.i386.rpm

Then fix whatever configuration and startup code you need to fix.

You're asking for trouble having two sets of mysql rpms installed, and then mangling both of them by shuffling things around.

My 2c worth.

Charlie

Noah Berlove

Re: MySQL 3 or 4 in SME 6?
« Reply #9 on: July 04, 2003, 12:56:38 AM »
> When you use a package management system, such as rpm, you
> should allow it to do its job. No copying and moving, and no
> --force or --nodeps unless you know exactly what you are
> doing and why you are doing it.

I realize this.  The problem is that the rpms from Red Hat and the rpms from mysql.com do things differently.  

> I would advice people not to use that script. Instead, remove
> all existing mysql components:
...
>
> Then fix whatever configuration and startup code you need to
> fix.

This is actually my plan, but haven't had a chance to complete this yet.  The startup scripts from mysql.com are different than Red Hat's (or more specifically, the scripts for 4.0.x are different).
 
> You're asking for trouble having two sets of mysql rpms
> installed, and then mangling both of them by shuffling things
> around.

You are right about this, but so far, I have not run into any problems.  

> My 2c worth.

You know, the other solution would be for Mitel to use the mysql.com rpms instead of the Red Hat ones ;^)

Noah

Charlie Brady

Re: MySQL 3 or 4 in SME 6?
« Reply #10 on: July 04, 2003, 01:18:52 AM »
Noah Berlove wrote:

> You know, the other solution would be for Mitel to use the
> mysql.com rpms instead of the Red Hat ones ;^)

We have no reason to do that(*). RedHat's RPMs work just fine for storing webmail preferences.

Charlie

(*) Nor spare moments to do it in.

Noah Berlove

Re: MySQL 3 or 4 in SME 6?
« Reply #11 on: July 04, 2003, 04:43:00 AM »
Charlie Brady wrote:
>Instead, remove all existing mysql components:
>
> rpm -e --nodeps mysql mysql-client mysql-server
> rpm -e mysql-devel
> rpm -e mysqlclient9
>
> Then do:
>
> rpm -Uhv MySQL-server-4.0.13-0.i386.rpm \
> MySQL-client-4.0.13-0.i386.rpm \
> MySQL-shared-compat-4.0.13-0.i386.rpm
>
> Then fix whatever configuration and startup code you need to
> fix.

I did as you suggested and then did the following to handle startup:

chkconfig --levels 2345 mysql on
rm /etc/rc.d/rc7.d/S90mysqld
ln -s /etc/rc.d/init.d/mysql /etc/rc.d/rc7.d/S90mysqld

Seems to work fine and is much cleaner.

Noah

Kevin Tollison

Re: MySQL 3 or 4 in SME 6?
« Reply #12 on: July 04, 2003, 08:39:09 AM »
Thanks,

I will do it next week on my test box

Kevin

baddog

Re: MySQL 3 or 4 in SME 6?
« Reply #13 on: July 04, 2003, 04:41:52 PM »
I followed Charlie's instructions as described above and sure enough, I was able to log into the MySQL server at the version 4 on SME 6.   I restarted the service and mysql.sock promptly disappeared, exactly the same problem I was having all along with my unaided attempts to upgrade.

Does anyone know how to avoid this mysql.sock issue?  Or how to restore the file with the attributes srwxwrxwrx (note the 's').  It lives in  /var/lib/mysql/mysql.sock

If no response on this, I will have to nuke my install and try Noah's proven method.  If Noah's method works as I hope; I will try to break the mysql install and post the results.

Cheers!

guestHH

Re: MySQL 3 or 4 in SME 6?
« Reply #14 on: September 22, 2003, 11:17:15 AM »
Interesting,

would anybody be kind enough to make up a final 'proven' how-to and post it on contribs.org? Mysql4 is a wanted feature for more people...

TIA

Regards,
guestHH

Jesper Bille Haun

Re: MySQL 3 or 4 in SME 6?
« Reply #15 on: September 22, 2003, 03:19:58 PM »
I would like to support this. MySQL 4 is very important to me too.

/

Jesper Bille Haun

Baddogg

Re: MySQL 3 or 4 in SME 6?
« Reply #16 on: September 22, 2003, 10:53:47 PM »
I have successfully upgraded to Mysql 4.013 and have all the associated libraries.  It was a long hall, but I have done it 3 times with both 5.6 and 6.0.  Special thanks to Noah for the clues...

Email me with subject of mysql or my filters will kill the email if you would like information of what I didJesper Bille Haun wrote:

Noah Berlove

Re: MySQL 3 or 4 in SME 6?
« Reply #17 on: September 22, 2003, 11:13:33 PM »
I've sucessfully installed MySQL 4 a number of times.  I'll go through all of my notes and write up a nice How-To shortly.  In the mean time, here are the basic steps:

- stop MySQL and remove the exisiting rpms (rpm -e)

- download the MySQL 4 rpms from mysql.com (don't use Red Hat's rpms), make sure the use the libraries which are compatible with MySQL 3 & 4.

- install the rpms (use rpm -Uvh)

- do the following to handle startup:
   chkconfig --levels 2345 mysql on
   rm /etc/rc.d/rc7.d/S90mysqld
   ln -s /etc/rc.d/init.d/mysql /etc/rc.d/rc7.d/S90mysqld

Note: the chkconfig step was necessary with MySQL 4.0.13 and eartlier.   I believe more recent MySQL rpms have fixed the bug which required this.  Go back through this thread for some more details.

Noah

haj

Re: MySQL 3 or 4 in SME 6?
« Reply #18 on: March 09, 2004, 12:59:05 AM »
Quote from: "RequestedDeletion"
Interesting,

would anybody be kind enough to make up a final 'proven' how-to and post it on contribs.org? Mysql4 is a wanted feature for more people...

TIA

Regards,
RequestedDeletion


Does anyone knows how to enable innoDB table type after an upgrade to Mysql4 ??

haj

Re: MySQL 3 or 4 in SME 6?
« Reply #19 on: March 18, 2004, 01:34:42 AM »
Quote from: "haj"
Does anyone knows how to enable innoDB table type after an upgrade to Mysql4 ??


Found it ! Altought, the how to is wrong on configuring the server to launch mysql at server boot.

Try following my comments there:
http://no.longer.valid/mylinks/singlelink.php?cid=208&lid=355