Comments - Upgrading MariaDB on Windows

 
1 year, 3 months ago Gauthier M.

I have try the mariadb_upgrade_wizzard on 3 different Windows : Windows 10, Windows 11 and Windows Server 2019. It never works, freeze at step 5, and I have always this error in log :

Executing "C:\Program Files\MariaDB 10.11\bin\mysqld.exe" "--defaults-file=C:\Program Files\MariaDB 10.9\data3\my.ini" "--skip-networking" "--skip-grant-tables" "--enable-named-pipe" "--socket=mysql_upgrade_service_16960" "--skip-slave-start" Executing "C:\Program Files\MariaDB 10.11\bin\mysqladmin.exe" "--protocol=pipe" "--socket=mysql_upgrade_service_16960" "ping" "--no-beep" C:\Program Files\MariaDB 10.11\bin\mysqladmin.exe: connect to server at 'localhost' failed error: 'Can't connect to server on 'localhost' (10061)' Check that mariadbd is running and that the socket: 'mysql_upgrade_service_16960' exists! Executing "C:\Program Files\MariaDB 10.11\bin\mysqladmin.exe" "--protocol=pipe" "--socket=mysql_upgrade_service_16960" "ping" "--no-beep" C:\Program Files\MariaDB 10.11\bin\mysqladmin.exe: connect to server at 'localhost' failed error: 'Can't connect to server on 'localhost' (10061)' Check that mariadbd is running and that the socket: 'mysql_upgrade_service_16960' exists! Executing "C:\Program Files\MariaDB 10.11\bin\mysqladmin.exe" "--protocol=pipe" "--socket=mysql_upgrade_service_16960" "ping" "--no-beep" C:\Program Files\MariaDB 10.11\bin\mysqladmin.exe: connect to server at 'localhost' failed error: 'Can't connect to server on 'localhost' (10061)' Check that mariadbd is running and that the socket: 'mysql_upgrade_service_16960' exists!

 
1 year, 3 months ago Jorge E

I'm having the same issue with Windows Server 2019. I just get this error in the log and also gets stuck in phase 5. I'm trying to update from 10.8.3 -> 10.11.3. Please help.

Is there any way to manually run all the commands necessary to upgrade version?

Executing "C:\Program Files\MariaDB 10.10\bin\mysqladmin.exe" "--protocol=pipe" "--socket=mysql_upgrade_service_1076" "ping" "--no-beep" C:\Program Files\MariaDB 10.10\bin\mysqladmin.exe: connect to server at 'localhost' failed error: 'Can't connect to server on 'localhost' (10061)'

 
1 year, 2 months ago Blaine Ott

I ran into this same error in Phase 5 when attempting to upgrade from 5.7 to 10.6 on a Windows 2016 server. It's a VM that I've been able to clone and test multiple times by reverting snapshots. I've gradually worked my way forward and found the service upgrade works with the latest versions of 10.2 through 10.5, all the way up to 10.6.12. I get the error if I try 10.6.13 or 10.6.14. Once I had a working 10.6.12 instance, I was able to upgrade in place to the latest version since it didn't require a service update. Version 10.6.12 was released in Feb, 10.6.13 in May and 10.6.14 in June. These other comments align with that timeline. Did something signficant change in the mysql_service_upgrade process between Feb and May that was propagated across versions?

 
2 years, 1 month ago Robert Hogg

I am trying to upgrade from 10.3 to 10.8.3 so I thought I would try the 10.4 msi. It fails or as it says ' ended prematurely because of an error.'

Yes, so what is the error, where are the log files created.

The only option I changed was to not create a new database.

I can't help it I cannot see the full error details.

Rob.

 
2 years, 2 months ago Sean Anderson

I am trying to upgrade from v10.1.2 (running as service MySQL) and I have installed from the MSI for v10.2.0 (as service MySQL_10.2).

I ran the mysql_upgrade_service --service=MySQL_10.2 from the BIN folder of the new installation and got the 8 phases with a "Service 'MySQL_10.2' successfully upgraded" and started the service from service.msc

Open Heidi and I have a blank database. How would I reattach my data and bring in the users from my v10.1.2 2 instance?

Also tried running the mysql_upgrade_wizard.exe from the same BIN folder, but that said there is no service that can be upgraded to Mariad DB 10.2.0, which I assume is because I completed it from the command line, previously.

Advie would be greatly appreciated.

 
2 years, 7 months ago Laurence van Bilderbeek

We've been updating MariaDB from version 10.5 to version 10.6 following the first tow steps of the recomendations: 1. Install new version, while still retaining the old one 2. Upgrade services one by one, like described later in the document (e.g with mysql_upgrade_service). It is recommeded to have services cleanly shut down before the upgrade. 3. Uninstall old version when previous step is done.

We were looking into performing step 3, but halted when we noticed that certain configurations still refrered to the Maria Db 10.5 installation folder. These references were found in the my.ini file (path to Data folder and path to plugin folders) and also in the Windows service (Executable is the 10.6 folder, but is starts with parameter with my.ini in 10.5 folder)

I would expect, following the reccomendations, that these settings would be updatet too. We are now reluctant of removing the old version, before knowing what changes to configrations must be made prior to the removal

Can anyone clarify on this?

 
3 years ago Noah Grant

The General Recommendations section of this page indicates to install the new version (while retaining the old one), upgrade any services, then uninstall the old version. When I upgrade from 10.1.22 to 10.6.4 I run the 10.6.4 msi, have no services to upgrade, then when I run the 10.1.22 msi and choose to Remove the version (but keep the data) I end up with the Windows Service uninstalled, so my 10.6.4 version will not work. Are these steps out of date? Should the uninstall of 10.1.22 happen first, keeping the data, then install 10.6.4?

 
2 years, 9 months ago Vladislav Vaintroub

The instructions did not change since they were created. The problem is that you have no services to upgrade, on some reason the wizard decides that whatever you got is not upgradable. Those reasons could be executable name, different from mysqld.exe in the service config, or missing or unparsable my.ini , or it could not find data directory. Unfortunately, the wizard does not log its decisions, on why it excluded something.

So, no , you should not uninstall old version before installing new, or everything that is written here, and mysql_upgrade_service.exe tool would not make sense.

 
3 years, 11 months ago David Rogers

What?!?

"To install a minor upgrade, e.g 10.1.27 on top of existing 10.1.26, with MSI, just download the 10.1.26 MSI and start it."

Shouldn't it say:

To install a minor upgrade, e.g 10.1.27 on top of existing 10.1.26, with MSI, just download the 10.1.27 MSI and start it.

 
3 years, 11 months ago Vladislav Vaintroub

You're right. Thanks for notifying.

 
3 years, 11 months ago Aaron Mason

Thank you to the maintainers for a trouble-free tool for upgrading databases. Just went from 10.4.8 to 10.5.5. The wizard didn't work for me though, just threw an error that didn't explain the problem (it literally says "Fatal Error" - "mysql_upgrade_service returned error for service [service name]:" and nothing else, then closes when I click OK. Maybe it didn't like the space in the service name?)

By the bye, if you want to be able to back up your MariaDB databases without shutting them down first and without corrupting them, VSS is your friend. Simply flush updates and lock the tables (FLUSH TABLES WITH READ LOCK), create the VSS snapshot, then unlock (UNLOCK TABLES). You can then go in after the fact and copy data to your backup storage. I use this method to refresh my QA and DEVEL instances and it's never given me drama.

 
4 years, 1 month ago Nilanka Wijewardana

Trying to upgrade existing 10.1.17 to 10.4.13

Almost all the time, it fails with permission denied error related to file renaming at phase 4/7: Running 'mysql_fix_privilege_tables' ERROR 1025 (HY000) at line 385: Error on rename of '.\mysql\#sql-5834_e' to '.\mysql\event' (errno: 13 "Permission denied")

Full log content - given below

Executing "C:\Program Files\MariaDB 10.1\bin\mysqld.exe" "--defaults-file=C:\Program Files\MariaDB 10.1\data\my.ini" "--loose-innodb-fast-shutdown=0" "--skip-networking" "--enable-named-pipe" "--socket=mysql_upgrade_service_23060" "--skip-slave-start" 2020-08-05 14:53:37 23084 [Note] C:\Program Files\MariaDB 10.1\bin\mysqld.exe (mysqld 10.1.17-MariaDB) starting as process 23088 ... Executing "C:\Program Files\MariaDB 10.4\bin\mysqld.exe" "--defaults-file=C:\Program Files\MariaDB 10.1\data\my.ini" "--skip-networking" "--skip-grant-tables" "--enable-named-pipe" "--socket=mysql_upgrade_service_23060" "--skip-slave-start" Executing "C:\Program Files\MariaDB 10.4\bin\mysqladmin.exe" "--protocol=pipe" "--socket=mysql_upgrade_service_23060" "ping" 2020-08-05 14:53:41 0 [Note] C:\Program Files\MariaDB 10.4\bin\mysqld.exe (mysqld 10.4.13-MariaDB) starting as process 19880 ... C:\Program Files\MariaDB 10.4\bin\mysqladmin.exe: connect to server at 'localhost' failed error: 'Can't open named pipe to host: . pipe: mysql_upgrade_service_23060 (2)' Executing "C:\Program Files\MariaDB 10.4\bin\mysqladmin.exe" "--protocol=pipe" "--socket=mysql_upgrade_service_23060" "ping" mysqld is alive Executing "C:\Program Files\MariaDB 10.4\bin\mysql_upgrade.exe" "--protocol=pipe" "--force" "--socket=mysql_upgrade_service_23060" Phase 1/7: Checking and upgrading mysql database Processing databases mysql mysql.column_stats OK mysql.columns_priv OK mysql.db OK mysql.event OK mysql.func OK mysql.gtid_slave_pos OK mysql.help_category OK mysql.help_keyword OK mysql.help_relation OK mysql.help_topic OK mysql.host OK mysql.index_stats OK mysql.innodb_index_stats OK mysql.innodb_table_stats OK mysql.plugin OK mysql.proc OK mysql.procs_priv OK mysql.proxies_priv OK mysql.roles_mapping OK mysql.servers OK mysql.table_stats OK mysql.tables_priv OK mysql.time_zone OK mysql.time_zone_leap_second OK mysql.time_zone_name OK mysql.time_zone_transition OK mysql.time_zone_transition_type OK mysql.user OK Phase 2/7: Installing used storage engines... Skipped Phase 3/7: Fixing views Phase 4/7: Running 'mysql_fix_privilege_tables' ERROR 1025 (HY000) at line 385: Error on rename of '.\mysql\#sql-5834_e' to '.\mysql\event' (errno: 13 "Permission denied") ERROR 1025 (HY000) at line 461: Error on rename of '.\mysql\#sql-5834_e' to '.\mysql\proxies_priv' (errno: 13 "Permission denied") FATAL ERROR: Upgrade failed

 
3 years, 11 months ago Aaron Mason

Hi there, maybe try intermediate steps first? i.e. go from 10.1 to 10.2, 10.2 to 10.3, etc

 
6 years ago Andrea Censi

It throws an access violation "c0000005", how to resolve it ? I want to upgrade from 10.0.19 to 10.3.9 and i'im performing all the major steps, please help. The old service is stopped while upgrading.

Details: Firma problema: Nome evento problema: APPCRASH Nome applicazione: mysql_upgrade_service.exe Versione applicazione: 10.1.35.0 Timestamp applicazione: 5b66288b Nome modulo con errori: KERNELBASE.dll Versione modulo con errori: 6.1.7601.23796 Timestamp modulo con errori: 59029714 Codice eccezione: c0000005 Offset eccezione: 0000000000001b54 Versione SO: 6.1.7601.2.1.0.256.1 ID impostazioni locali: 1040 Informazioni aggiuntive 1: c82f Ulteriori informazioni 2: c82f1ba4a6bab5ddd4f65af9b68bc266 Ulteriori informazioni 3: d571 Ulteriori informazioni 4: d571227aa444e316853187bec1b1956f

Leggere l'informativa sulla privacy online: http://go.microsoft.com/fwlink/?linkid=104288&clcid=0x0410

Se l'informativa sulla privacy online non è disponibile, leggere quella offline: C:\Windows\system32\it-IT\erofflps.txt

 
6 years, 1 month ago Peter Deacon

I'm at a loss... not a DB master, we are looking to update from 10.0.15 to 10.2.*

Tried the next major step up 10.1.34, Installed the versions side by side but get - "There is no service that can be upgraded to MariaDB 10.1.34"

Where on earth do i go from here?

 
6 years, 1 month ago Vladislav Vaintroub

on earth, you do following: mysql_upgrade_service --service=name_of_your_service.

 
6 years, 1 month ago Peter Deacon

lol, also tried mysql_upgrade_service --service=name_of_your_service. Says the service doesn't exist.... defiantly running a MariaDB database service and have access via tools like Heidi. Not sure what could be stopping the upgrade service from seeing the service.

 
6 years, 1 month ago Vladislav Vaintroub

There is no message like this with mysql_upgrade_serivice

All service related messages are

  • OpenSCManager failed with...
  • OpenService failed with...
  • QueryServiceConfig failed with...
  • Not a valid MySQL service
  • Can not downgrade, the service is currently running as version... my version is ...
  • ChangeServiceConfig failed with..

Which one is yours ?

 
6 years, 1 month ago Peter Deacon

C:\Program Files (x86)\MariaDB 10.1\bin>mysql_upgrade_service.exe --service=MariaDbserver Phase 1/8: Changing service configuration FATAL ERROR: Not a valid MySQL service

Even reinstalled the MariaBD database onto another machine from scratch and moved the database across. ODD! Have updated from 10.0.15 to 10.0.36 fine and the service is currently running.

 
6 years, 1 month ago Vladislav Vaintroub
D:\mariadb-10.1.34-win32\bin>mysql_upgrade_service --service=MySQL
Phase 1/8: Changing service configuration
Phase 2/8: Stopping service
Phase 3/8: Starting mysqld for upgrade
Phase 4/8: Waiting for startup to complete
Phase 5/8: Running mysql_upgrade
Phase 6/8: Initiating server shutdown
Phase 7/8: Waiting for shutdown to complete
Phase 8/8: Starting service
Service 'MySQL' successfully upgraded.
Log file is written to C:\Users\wlad\AppData\Local\Temp\mysql_upgrade_service.My
SQL.log

Works for me. Can I suggest to open bug in JIRA in investigate your case, so we do not spam the KB with "bug reports".

 
3 years, 1 month ago Reinaldo Moreno

C:\Program Files\MariaDB 10.6\bin>mysql_upgrade_service --service=MariaDB Phase 1/10: Stopping service Phase 2/10: Fixing server config file Phase 3/10: Ensuring innodb slow shutdown,this can take some time Phase 4/10: Starting mysqld for upgrade Phase 5/10: Waiting for startup to complete Phase 6/10: Running mysql_upgrade Phase 7/10: Changing service configuration Phase 8/10: Initiating server shutdown Phase 9/10: Waiting for shutdown to complete Phase 10/10: Starting service Service 'MariaDB' successfully upgraded. Log file is written to C:\Users\ADMINI1\AppData\Local\Temp\2\mysql_upgrade_service.MariaDB.log

Works for me.

 
Content reproduced on this site is the property of its respective owners, and this content is not reviewed in advance by MariaDB. The views, information and opinions expressed by this content do not necessarily represent those of MariaDB or any other party.