mysql中安装路径在哪个文件中

安装路径在my.cnf或my.ini中。

通常它位于 supportfiles 文件夹中。

mysqlhelp|grep "Defaultoptions" 命令允许您查看路径列表。

Windows 是 my.ini,Linux 是 my.cnf。

如果找不到,请确认安装位置是否正确。

Mysql怎样更改安装路径?

安装了MYSQL找不到路径怎么办

哎,寻找MySQL路径让我头疼了好久。
I remember one time I installed mysql on my home computer, but I couldn't find the data files, which made me anxious.
首先我们来说一下如何打开命令行。
您的计算机是一个获胜的系统吗?然后在搜索框中输入“cmd”,就会出现黑色窗口。
如果是 Mac 或 Linux,请在终端中键入命令。
我当时安装mysql的时候就选择了默认路径,一直没有改过,所以所有的东西都应该在C盘。

然后输入您的密码。
打开cmd并输入“mysql -u root -p”。
按 Enter 后,系统会要求您输入密码,该密码是您在安装时设置的密码。
I set it to "1 2 3 4 5 6 " at the time, haha, it's pretty simple now that I think about it. When entering the password, nothing is displayed on the screen, this is normal.
If the password is entered correctly, type "Show global variables as '%datadir%';".请注意,分号必须大写。
当我打完这句话时,电脑发出了嘟嘟的声音,然后屏幕上出现了一长串东西,其中之一是“datadir=/c/mysql/data”。
如您所见,这是您的数据目录。

你看到了吗?最重要的是这个。
但是,请注意,路径可能会因版本或设置而异。
I installed MySQL 5 .7 at that time, and the path was under the MySQL folder on C drive.
If you install it on a server, the path may be more complicated, and sometimes it will be hidden in the system protection folder.我记得有一次我帮朋友架设了一台服务器。
He typed "dir /a" in the root directory of drive D. As a result, there were many hidden folders, and the data directory was inside them. As you can see, sometimes you have to view all the hidden files to find them.
In short, if you type the right commands and read the prompts, you can basically find it. If you really can't find it, try another computer, or look for path instructions in the installation package. At that time, I searched the Internet for a long time before I found the divine command "show global variables".