Skip to Content
It is currently September 27th, 2021, 5:14 am

All times are UTC - 6 hours [ DST ]




Post new topic Reply to topic  [ 10 posts ] 
Author Message
 Post subject: Upgrade Mysql
PostPosted: January 30th, 2014, 2:36 am 
Offline
Junior User
Junior User

Joined: January 21st, 2013, 9:33 pm
Posts: 34
Hey all, I been searching for days, and have not found my answer, so I have come here now. My question is, is it possible to upgrade mysql to a newer version without uninstalling and reinstalling Sam?

_________________
Never a dull moment at MIXROCKMETAL.COM ~ UP THE IRONS \m/


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: January 30th, 2014, 9:21 am 
Offline
SVS Member
SVS Member

Joined: December 28th, 2009, 12:33 pm
Posts: 1342
Yes - how careful you have to be probably depends on how much of an upgrade you're doing, but just make a backup of your database before you upgrade, just in case.
And it depends on which version of SAM you're using, but if you're on any of the fairly recent versions (older versions may not even work correctly with 5.5, but there's no reason why you wouldn't be on 4.9.8 or 2013.6, both of which work correctly with 5.5), and you want to use the SAM backup/restore function, don't upgrade to MySQL 5.6 yet - 5.5 seems to be the latest version that works correctly with the SAM backup/restore function.

_________________
Isaac Levine - Spacial Volunteer Support (SVS)


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: February 3rd, 2014, 5:58 pm 
Offline
Junior User
Junior User

Joined: January 21st, 2013, 9:33 pm
Posts: 34
Thank you for the reply isaacl, I have been using older versions mainly because I have had good luck with them and heard some bad luck with newer versions, I currently run Sam 4.9.0 and Mysql 4.0.xx. Although once in a while I do get a Sam crash and only one time gave me a clue as to why, I caught an error report popup just before Sam vanished from the task bar and the error mentioned something to do with Mysql, so this is why I was thinking of upgrading mysql. I was thinking of looking for Mysql 5.0 and see if all goes well, or would Mysql 5.5 still be fine with Sam 4.9.0 ?

_________________
Never a dull moment at MIXROCKMETAL.COM ~ UP THE IRONS \m/


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: February 3rd, 2014, 8:49 pm 
Offline
SVS Member
SVS Member

Joined: December 28th, 2009, 12:33 pm
Posts: 1342
I have no idea if upgrading from MySQL 4.x to 5.x works, or how well it works, since 4.x is really old, and before my time...
I would recommend backing up your database (from SAM, as well as a database dump to SQL file, just in case), fully removing 4.x, and then installing 5.5 from scratch, and then restoring the database.
But there might be someone here who would know more about it than I would...

_________________
Isaac Levine - Spacial Volunteer Support (SVS)


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: February 4th, 2014, 12:08 pm 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 8254
Location: Cologne (Germany)
There is no way of UPGRADING a MySQL install from 4.0 to 5.5 directly.
This has multiple reasons: 4.1 introduced a new password encryption and invalidates all the user credentials stored in a 4.0 install.
5.0 introduced an incompatible change in the storage engine MyISAM which will invalidate all the stored data from a 4.1 and older database.

The only way to upgrade the existing install is to do the upgrade from 4.0 to 4.1 and then to 5.0 and then to 5.1 and then to 5.5 (You may skip 5.2 to 5.4)
After installing the newer version on top, you need to run the mysql_upgrade tool which should in most cases do all the structural upgrades for you.

You can of course dump your databases and recreate the contents in 5.5 or 5.6. I'd say this is the preferred way to do things.
Run MySQLDump to create a file containing the SQL statements for creating all databases and the contained data:
Code:
mysqldump -uroot -p --all-databases > backupfile.sql

And then restore that data in the new MySQL 5.5 system:
Code:
mysql -uroot -p < backupfile.sql


You might need to change the passwords (if any) for the MySQL users as the password encryption changed from MySQL 4.0 to 4.1

Documentation for the in-place upgrade of MySQL 4.0 to 5.5 can be found in these locations:
4.0 => 4.1
4.1 => 5.0
5.0 => 5.1
5.1 => 5.5

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

Shop for readymade PAL scripts by countrywesterndj - Or get a custom script made by me (or others)

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: April 24th, 2014, 5:06 am 
Offline
Senior User
Senior User

Joined: June 30th, 2005, 10:03 am
Posts: 88
Hello Mastacheata, you are very resourceful.

Many thanks.

Just to be clear in my head. The dump I do after [....You can of course dump your databases and recreate the contents in 5.5 or 5.6. I'd say this is the preferred way to do things.] this is after I do the upgrades, right and not on the old 4.0.

Thanks again

_________________
Thanks for helping me and GOD Bless
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: April 24th, 2014, 7:43 am 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 8254
Location: Cologne (Germany)
That would be pretty useless.
You have to DUMP the database contents to a file BEFORE you do the upgrade so you can RESTORE if necessary.

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

Shop for readymade PAL scripts by countrywesterndj - Or get a custom script made by me (or others)

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: April 24th, 2014, 5:02 pm 
Offline
Senior User
Senior User

Joined: June 30th, 2005, 10:03 am
Posts: 88
OK, Much thanks for making me see what a jerk that I am and must learn that when the brain is tired and I am sleeping on me I should realize that I will ask dumb questions ...-laugh

Much appreciated for the response.

Thanks

_________________
Thanks for helping me and GOD Bless
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: April 29th, 2014, 7:12 pm 
Offline
Senior User
Senior User

Joined: June 30th, 2005, 10:03 am
Posts: 88
Hello Mastacheata, sorry to be taking up some of your time here.

I have been doing lots of reading and trouble shooting to upgrade mysql to try and get FHRsam wordpress plugin going and have reached a road block and is not getting the answer to solve my issue.

I went from 4.0.25 to 4.1 to 5.0 and trying to upgrade to 5.1 so that I can upgrade to 5.5.

5.1 installed OK and according to the doc in 5.1 I my use "mysql_upgrade" in this version and every other versions above.

Here is my error:

C:\mysql\bin\mysql_upgrade -uroot -p
Enter password: ************
Looking for 'mysql.exe as: C:\mysql\bin\mysql.exe
Looking for 'mysqlcheck.exe' as: C:\mysql\bin\mysqlcheck.exe
Running 'mysqlcheck'with connection arguments: "--port = 3306"
Running 'mysqlcheck'with connection arguments: "--port = 3306"
C:\mysql\bin\mysqlcheck.exe: mysqlcheck: Got error: 1064: You have an error in your SQL sysntas; check the manual that corresponds to your Mysql server version for the right syntax to use near 'FOR UPGRADE'at line one whem executing ÇHEXK TABLE ... FOR UPGRADE'
FATAL ERROR: Upgrade Failed.

I have been at it for the last 2 days reading but still no solution to my exact situation.

Many Thanks.

Fred

_________________
Thanks for helping me and GOD Bless
Image


Top
 Profile  
Reply with quote  
 Post subject: Re: Upgrade Mysql
PostPosted: April 30th, 2014, 6:09 am 
Offline
SVS Member
SVS Member

Joined: December 6th, 2004, 9:00 am
Posts: 8254
Location: Cologne (Germany)
Quote:
The FOR UPGRADE option checks whether the named tables are compatible with the current version of MySQL. This option was added in MySQL 5.1.7.

From the MySQL handbook regarding the CHECK TABLE syntax.

It looks like you're running mysql_upgrade from a new MySQL install on a server with an old version.
I've never done an upgrade that way. Simply shut down the server, install the new version over the top, restart the server and fix the permissions (as that's basically the only thing that changes).
If everything fails, I can still restore the contents of the database using the SQL Dump. That loses the structural information (i.e. how is the database named and who may access it), but it's usually easy to restore that by hand.

_________________
Benedikt Bauer - SVS (Spacial Volunteer Support)

Shop for readymade PAL scripts by countrywesterndj - Or get a custom script made by me (or others)

My Project:
Send "Now Playing" from SAM to Twitter and/or Facebook | Sourcecode


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 10 posts ] 

All times are UTC - 6 hours [ DST ]


Who is online

Users browsing this forum: Bing [Bot] and 28 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group