Where is mysql data stored?

Where is mysql data stored?

MySQL database storage location:

1. If MySQL uses the MyISAM storage engine, the database file types include .frm, .MYD, and .MYI. The default storage location is

C:\Documentsand Settings\AllUsers\Application Data\MySQL\MySQL Server 5.1\data

2. If MySQL uses the InnoDB storage engine, the database file types include .frm, ibdata1, and .ibd, and there are two storage locations.

The default location for .frm files is

C:\Documents and Settings\All Users\ApplicationData\MySQL\MySQL Server 5.1\data, ibdata1, .ibd

The default location for the file is the data folder under the MySQL installation directory.

Knowledge point expansion:

How to view the storage location of MySQL data files

We may have a question: After we install MySQL locally (on our own computer), we create many databases and tables and store a lot of data, but where are these contents stored? In particular, when we need to directly operate these data files, we search the entire computer but cannot find where the MySQL data files are. This is a bit annoying!

Here, I will teach you a very simple method to immediately locate the storage location of MySQL data files, that is, type the following command in the MySQL client:

show global variables like "%datadir%";

MySQL data files are stored in the Data directory. As for whether you want to check a specific database or table next, it depends on your mood!

However, you may still have a question. We have found that the MySQL data files are in the ProgramData directory of the C drive, but we have searched the entire C drive but still cannot find the ProgramData folder. Why is that? The answer is: by default, the ProgramData folder is hidden.

As for how to display hidden folders, I believe everyone has already done it well!

This is the end of this article about where MySQL data is stored. For more information about where MySQL data is stored, please search for previous articles on 123WORDPRESS.COM or continue to browse the following related articles. I hope you will support 123WORDPRESS.COM in the future!

You may also be interested in:
  • Detailed steps for migrating the data folder of the MySQL database
  • Specific steps to change the storage location of the Mysql database

<<:  JavaScript file loading and blocking issues: performance optimization case study

>>:  Comparison between Redis and Memcache and how to choose

Recommend

How to clear mysql registry

Specific method: 1. Press [ win+r ] to open the r...

MySQL joint index effective conditions and index invalid conditions

Table of contents 1. Conditions for joint index f...

Installation tutorial of MySQL 5.7 green version under windows2008 64-bit system

Preface This article introduces the installation ...

Differences between this keyword in NodeJS and browsers

Preface Anyone who has learned JavaScript must be...

mysql 8.0.16 winx64.zip installation and configuration method graphic tutorial

This article shares the specific code of MySQL 8....

JavaScript to achieve product query function

This article example shares the specific code of ...

Research on the Input Button Function of Type File

<br />When uploading on some websites, a [Se...

Detailed explanation of slots in Vue

The reuse of code in vue provides us with mixnis....

Eight hook functions in the Vue life cycle camera

Table of contents 1. beforeCreate and created fun...

Implementing long shadow of text in less in CSS3

This article mainly introduces how to implement l...

JS removeAttribute() method to delete an attribute of an element

In JavaScript, use the removeAttribute() method o...

How to authorize remote connections in MySQL in Linux

Note: Other machines (IP) cannot connect to the M...

Detailed explanation of the MySQL MVCC mechanism principle

Table of contents What is MVCC Mysql lock and tra...

Teach you the detailed process of installing DOClever with Docker Compose

Table of contents 1. What is Docker Compose and h...