MySQL database file MYD not updating
Posted by: dran (---.s4139.c3-0.tlg-cbr4.atw-tlg.pa.cable.rcncustomer.com)
Date: February 03, 2021 12:31AM

I understand that MySQL table data gets stored in MYD files in the following folder:

C:\wamp64\bin\mysql\mysql8.0.18\data\

But those files in there have timestamps from yesterday! And I have updated my database records all day today!

Why aren't those data files being updated? I want to set up automatic backup of the files containing my database data, but first I want to understand why the files are not updating with every save. Thanks!

Options: ReplyQuote
Re: MySQL database file MYD not updating
Posted by: Otomatic (Moderator)
Date: February 03, 2021 09:00AM

Hi,

This is not the responsibility of Wampserver. See at MySQL.

The MYD files are not the only files to constitute a database, several other files are taken into account: ib_logfile0, ibdata1, mysql.ibd, and others.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons



Edited 1 time(s). Last edit at 02/03/2021 10:16AM by Otomatic.

Options: ReplyQuote
Re: MySQL database file MYD not updating
Posted by: dran (---.s4139.c3-0.tlg-cbr4.atw-tlg.pa.cable.rcncustomer.com)
Date: February 03, 2021 10:27PM

I tested. Looks like the MYD files actually DO get updated right away. But Windows fails to update the "Date modified" timestamp. I have no idea why, but it doesn't matter. All I wanted was to ensure the data was saved to disk and not sitting in memory somewhere. Thanks.

Options: ReplyQuote
Re: MySQL database file MYD not updating
Posted by: Otomatic (Moderator)
Date: February 04, 2021 09:29AM

Hi,

I think you're forgetting a "trick"!
MySQL uses a cache and this cache will actually be written only when the MySQL service is stopped, so either when you quit Wampserver or when you shut down Windows.

---------------------------------------------------------------
Documentation Apache - Documentation PHP - Documentation MySQL - Wampserver install files & addons

Options: ReplyQuote


Sorry, only registered users may post in this forum.