mysql如何查看自己数据库文件所在的位置

mysql如何查看自己数据库文件所在的位置

 

C:\Program Files\MySQL\MySQL Server 5.5

 

  • mysql数据库

方法/步骤

 
  1.  

    第1步:

    打开mysqml文件夹,显示的文件如下,然后找到my.ini文件,如图所示。

    mysql如何查看自己数据库文件所在的位置
  2.  

    第2步:

    选中my.ini文件,这时候点击鼠标右键依次选择”打开方式“然后选择”记事本打开“

    mysql如何查看自己数据库文件所在的位置
  3.  

    第3步:

    以记事本的方式打开my.ini文件后,按ctrl+f搜索”datadir“就可以找到你数据库的物理路径

    mysql如何查看自己数据库文件所在的位置
  4.  

    第4步:

    如果你想修改数据库文件的存储位置,可以直接在这里修改,如下图红框所示。

    mysql如何查看自己数据库文件所在的位置
  5.  

    第5步:

    按照上面所找到的路径,我们打开上面的路径的data文件夹,显示如下图。

    mysql如何查看自己数据库文件所在的位置
  6. 6

    第6步:

    如果想对数据库进行搬迁,只需要复制”data“这个文件夹,覆盖新环境下的”data“文件就可以了。

    mysql如何查看自己数据库文件所在的位置
  7.  

    解决方法:

    1、增加id文件是否存在的判断

    2、方法写了2次h.GetFilePath("txtpath");


    3、使用线程发生get请求增加时间限制2000
    // 执行get请求.
    RequestConfig requestConfig = RequestConfig.custom().setSocketTimeout(2000).setConnectTimeout(2000).build();//设置请求和传输超时时间
    httpget.setConfig(requestConfig);

    4、Cache类使用静态类,静态方法
    5、数据池链接数
    6、内存网站
    7、if (!str.equals(""))

     

    增加日志判断

    序列化类增加

     

    解决办法:
    1.将内部类写成静态的
    2.将内部类单独写一个.java文件 implements Serializable


    避免死循环

    方法写了2次h.GetFilePath("txtpath");
    public static String readFile(String websiteid) {

     

    Illegal access: this web application instance has been stopped already. Could not load META-INF/services/javax.xml.bind.JAXBContext. The eventual following stack trace is caused by an error thrown for debugging purposes as well as to attempt to terminate the thread which caused the illegal access, and has no functional impact.
    javax.xml.bind.UnmarshalException: Unable to create an instance of javax.xml.ws.wsaddressing.W3CEndpointReference
    - with linked exception:

# MySQL Server Instance Configuration File
# ----------------------------------------------------------------------
# Generated by the MySQL Server Instance Configuration Wizard
#
#
# Installation Instructions
# ----------------------------------------------------------------------
#
# On Linux you can copy this file to /etc/my.cnf to set global options,
# mysql-data-dir/my.cnf to set server-specific options
# (@localstatedir@ for this installation) or to
# ~/.my.cnf to set user-specific options.
#
# On Windows you should keep this file in the installation directory
# of your server (e.g. C:\Program Files\MySQL\MySQL Server X.Y). To
# make sure the server reads the config file use the startup option
# "--defaults-file".
#
# To run run the server from the command line, execute this in a
# command line shell, e.g.
# mysqld --defaults-file="C:\Program Files\MySQL\MySQL Server X.Y\my.ini"
#
# To install the server as a Windows service manually, execute this in a
# command line shell, e.g.
# mysqld --install MySQLXY --defaults-file="C:\Program Files\MySQL\MySQL Server X.Y\my.ini"
#
# And then execute this in a command line shell to start the server, e.g.
# net start MySQLXY
#
#
# Guildlines for editing this file
# ----------------------------------------------------------------------
#
# In this file, you can use all long options that the program supports.
# If you want to know the options a program supports, start the program
# with the "--help" option.
#
# More detailed information about the individual options can also be
# found in the manual.
#
#
# CLIENT SECTION
# ----------------------------------------------------------------------
#
# The following options will be read by MySQL client applications.
# Note that only client applications shipped by MySQL are guaranteed
# to read this section. If you want your own MySQL client program to
# honor these values, you need to specify it as an option during the
# MySQL client library initialization.
#
[client]

port=3309

[mysql]

default-character-set=gb2312


# SERVER SECTION
# ----------------------------------------------------------------------
#
# The following options will be read by the MySQL Server. Make sure that
# you have installed the server correctly (see above) so it reads this
# file.
#
[mysqld]

# The TCP/IP Port the MySQL Server will listen on
port=3309


#Path to installation directory. All paths are usually resolved relative to this.
basedir="C:/Program Files/MySQL/MySQL Server 5.5/"

#Path to the database root
datadir="C:/ProgramData/MySQL/MySQL Server 5.5/Data/"

# The default character set that will be used when a new schema or table is
# created and no character set is defined
character-set-server=gb2312

# The default storage engine that will be used when create new tables when
default-storage-engine=INNODB

# Set the SQL mode to strict
sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"

# The maximum amount of concurrent sessions the MySQL server will
# allow. One of these connections will be reserved for a user with
# SUPER privileges to allow the administrator to login even if the
# connection limit has been reached.
max_connections=100

# Query cache is used to cache SELECT results and later return them
# without actual executing the same query once again. Having the query
# cache enabled may result in significant speed improvements, if your
# have a lot of identical queries and rarely changing tables. See the
# "Qcache_lowmem_prunes" status variable to check if the current value
# is high enough for your load.
# Note: In case your tables change very often or if your queries are
# textually different every time, the query cache may result in a
# slowdown instead of a performance improvement.
query_cache_size=32M

# The number of open tables for all threads. Increasing this value
# increases the number of file descriptors that mysqld requires.
# Therefore you have to make sure to set the amount of open files
# allowed to at least 4096 in the variable "open-files-limit" in
# section [mysqld_safe]
table_cache=256

# Maximum size for internal (in-memory) temporary tables. If a table
# grows larger than this value, it is automatically converted to disk
# based table This limitation is for a single table. There can be many
# of them.
tmp_table_size=35M


# How many threads we should keep in a cache for reuse. When a client
# disconnects, the client's threads are put in the cache if there aren't
# more than thread_cache_size threads from before. This greatly reduces
# the amount of thread creations needed if you have a lot of new
# connections. (Normally this doesn't give a notable performance
# improvement if you have a good thread implementation.)
thread_cache_size=8

#*** MyISAM Specific options

# The maximum size of the temporary file MySQL is allowed to use while
# recreating the index (during REPAIR, ALTER TABLE or LOAD DATA INFILE.
# If the file-size would be bigger than this, the index will be created
# through the key cache (which is slower).
myisam_max_sort_file_size=100G

# If the temporary file used for fast index creation would be bigger
# than using the key cache by the amount specified here, then prefer the
# key cache method. This is mainly used to force long character keys in
# large tables to use the slower key cache method to create the index.
myisam_sort_buffer_size=69M

# Size of the Key Buffer, used to cache index blocks for MyISAM tables.
# Do not set it larger than 30% of your available memory, as some memory
# is also required by the OS to cache rows. Even if you're not using
# MyISAM tables, you should still set it to 8-64M as it will also be
# used for internal temporary disk tables.
key_buffer_size=50M

# Size of the buffer used for doing full table scans of MyISAM tables.
# Allocated per thread, if a full scan is needed.
read_buffer_size=64K
read_rnd_buffer_size=256K

# This buffer is allocated when MySQL needs to rebuild the index in
# REPAIR, OPTIMZE, ALTER table statements as well as in LOAD DATA INFILE
# into an empty table. It is allocated per thread so be careful with
# large settings.
sort_buffer_size=256K


#*** INNODB Specific options ***


# Use this option if you have a MySQL server with InnoDB support enabled
# but you do not plan to use it. This will save memory and disk space
# and speed up some things.
#skip-innodb

# Additional memory pool that is used by InnoDB to store metadata
# information. If InnoDB requires more memory for this purpose it will
# start to allocate it from the OS. As this is fast enough on most
# recent operating systems, you normally do not need to change this
# value. SHOW INNODB STATUS will display the current amount used.
innodb_additional_mem_pool_size=2M

# If set to 1, InnoDB will flush (fsync) the transaction logs to the
# disk at each commit, which offers full ACID behavior. If you are
# willing to compromise this safety, and you are running small
# transactions, you may set this to 0 or 2 to reduce disk I/O to the
# logs. Value 0 means that the log is only written to the log file and
# the log file flushed to disk approximately once per second. Value 2
# means the log is written to the log file at each commit, but the log
# file is only flushed to disk approximately once per second.
innodb_flush_log_at_trx_commit=1

# The size of the buffer InnoDB uses for buffering log data. As soon as
# it is full, InnoDB will have to flush it to disk. As it is flushed
# once per second anyway, it does not make sense to have it very large
# (even with long transactions).
innodb_log_buffer_size=1M

# InnoDB, unlike MyISAM, uses a buffer pool to cache both indexes and
# row data. The bigger you set this the less disk I/O is needed to
# access data in tables. On a dedicated database server you may set this
# parameter up to 80% of the machine physical memory size. Do not set it
# too large, though, because competition of the physical memory may
# cause paging in the operating system. Note that on 32bit systems you
# might be limited to 2-3.5G of user level memory per process, so do not
# set it too high.
innodb_buffer_pool_size=96M

# Size of each log file in a log group. You should set the combined size
# of log files to about 25%-100% of your buffer pool size to avoid
# unneeded buffer pool flush activity on log file overwrite. However,
# note that a larger logfile size will increase the time needed for the
# recovery process.
innodb_log_file_size=20M

# Number of threads allowed inside the InnoDB kernel. The optimal value
# depends highly on the application, hardware as well as the OS
# scheduler properties. A too high value may lead to thread thrashing.
innodb_thread_concurrency=8


log-error="C:/D/lamp/log/error.log"
general-log=1
general-log-file="C:/D/lamp/log/mysql.log"
long_query_time=3
slow_query_log=1
slow-query-log_file="C:/D/lamp/log/slowquery.log"

转载于:https://www.cnblogs.com/w2017/p/8269325.html

weixin_30338481
关注 关注
  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
详述查看 MySQL 数据文件存储位置的方法
CG国斌的博客
10-01 2万+
我们可能会有一个疑惑,那就是:当我们在本地(自己的电脑)安装完 MySQL 之后,也创建了很多的数据库啊、表啊,也存储了很多的数据啊,但是这些内容都存储到哪里了呢?特别是,当我们需要直接操作这些数据文件的时候,翻遍了整个电脑,却找不到 MySQL 的数据文件到底在哪里,这就有些坑爹啦!在这里,教给大家一个非常简单的能够立即定位到 MySQL 数据文件的存储位置方法,即在 MySQL 客户端键入如下命
MySQL查看自己数据库文件所在的位置】附:互联网大厂 数据库面试题:简述索引的作用,以及常见的索引类型和优缺点;MySQL的事务隔离级别有哪些?请分别说明各个隔离级别的特点以及可能出现的问题。
追光者♂:记录、分享、总结、提升,现象级专栏《Python从入门到人工智能》作者,无惧黑暗,坚信曙光
03-09 1万+
本篇文章较为详细地讲解了如何查找mysql数据库真实物理文件的存储位置,只要我们直接复制数据库文件,即可对数据库进行搬迁,也可以对数据库文件的存放位置进行改变。 方法如下: 第1步: 打开 mysqml 文件夹,显示的文件如下,然后找到 my.ini 文件,如图所示。 第2步: 选中 my.ini 文件,这时候点击鼠标右键依次选择”打开方式“然后选择”记事本打开“。如图。 第3步: 以记事本的方式打开 my.ini 文件后,按 ctrl+f 搜索 ”datadir“ 就可以找到你数据库
查看Mysql数据库文件位置
weixin_34125592的博客
05-11 458
windows—— 搜一搜你的系统盘,一般根目录下会有个my.ini的文件,是隐藏的,这就是mysql的配置文件,内容如下: #This File was made using the WinMySQLadmin 1.0 Tool #2002-1-4 10:51:53 #Uncomment or Add only the keys that you know how ...
mysql 数据库管理
最新发布
2201_75549363的博客
08-28 921
数据定义语言(DDL)用于创建、修改和删除数据库对象,如数据库、表、索引等。
mysql 的进程文件位置_查看Mysql数据库文件位置
weixin_36379084的博客
01-20 121
windows——搜一搜你的系统盘,一般根目录下会有个my.ini的文件,是隐藏的,这就是mysql的配置文件,内容如下:#This File was made using the WinMySQLadmin 1.0 Tool#2002-1-4 10:51:53#Uncomment or Add only the keys that you know how works.#Read the MyS...
MySQL数据库的数据文件保存在哪?MySQL数据存在哪里
xiangxueerfei的博客
09-15 1万+
其中ibdata1、.ibd文件存放在mysql数据库安装目录的data文件夹中,而.frm文件在安装时如果没有设置的话那么默认的存放地址为C:\Documents and Settings\All Users\ApplicationData\MySQL\MySQL Server 5.1\data这个文件路径下的data文件夹内。Python所有方向的技术点做的整理,形成各个领域的知识点汇总,它的用处就在于,你可以按照上面的知识点去找对应的学习资源,保证自己学得较为全面。最后祝大家天天进步!
MySQL 数据库的临时文件究竟储存在哪里
09-11
总结来说,MySQL数据库的临时文件存储位置受环境变量控制,可以自定义以适应不同的存储需求,而临时文件的使用则涉及到数据库的排序、查询优化和表结构的变更等多种操作。理解这一机制有助于优化数据库性能并管理...
〖Python 数据库开发实战 - MySQL篇⑧〗- MySQL的配置文件与常用的配置方案
易编橙 · 终身成长社群,相遇已是上上签!
07-17 4万+
今天这一章节,我们来讲解一下 MySQL 的配置文件。既然开始写数据库的学习章节,就不能简单的讲一下 "增、删、改、查" ,再讲讲 "创建索引"、"回滚事务"等等。 学数据库就要学明白,毕竟将来是靠技术赚钱的。要学习明白怎么用,怎么配置,学懂学透彻了;当然了 MySQL 的配置有上百个,所以这里会挑选其中最重要的一些参数给大家介绍一下,其他的参数等到用到的时候再来介绍吧。...
MySQL数据库配置信息查看和修改
拾年一剑 的专栏
10-19 1万+
当在不同团队间使用MySQL数据库时,最好是保证数据库的配置信息是一致的,否则会因为不同开发同事的SQL规范不一样,导致出现一些不必要的SQL问题; 本篇博客,主要记录如何查看数据的配置信息,及相关解释。
查找mysql数据库文件的存放位置
weixin_30294021的博客
11-13 101
mysql数据库中,有时候并不是很容易找出mysql数据库文件data的存放位置吗,这时就可以使用mysql自带的命令行工具进行查询。具体命令如下:showvariableslike'%datadir%'; 转载于:https://www.cnblogs.com/xubox/p/3422215.html...
查看MySQL创建的数据库在电脑中的存储位置
m0_51791413的博客
02-18 2284
按下回车键后,会要求输入密码。输入数据库账号对应的密码,如果密码正确,就能顺利进入MySQL命令行。其中,用户名是数据库的访问账号,-p表示需要输入密码才能连接数据库。通常ProgramData文件是被隐藏的。
查看本地MySQL的安装路径方式
weixin_40317130的博客
03-29 315
在命令窗口中输入mysql命令时,提示“mysql不是内部命令或外部命令,也不是可运行的程序或批处理文件”, 发现此问题是由于系统的环境变量中未配置MySQL安装目录可执行文件的路径,可能是安装MySQL时是默认按照的,此时已经忘记了安装位置,各个盘符中找了一遍,都没有找到。那么要怎样才能找到其安装的路径呢? 其实方法很简单,只需登录MySQL的客户端,然后输入命令即可: `show variables like "%char%";` ...
MYSQL 查看当前处于哪个数据库
weixin_64348970的博客
12-17 7837
显示的内容 有一行叫 Current database : mysql , 这里的mysql 就是当前正在使用的数据库。查询出来的结果中,第一行为Tables_in_mysql , 这里的mysql 就是当前正在使用的数据库。表示当前访问的的是哪个数据库, 或者登录到了哪个数据库。一、用select database()语句。二,用 show tables 语句。三、用status语句。
MySQL(架构篇)
weixin_52064447的博客
11-24 1107
MySQL从3.23.34开始包含InnoDB存储引擎。5.5版本及以后,默认采用InnoDB引擎InnoDB是MySQL的默认事务引擎,主要用来处理大量的短期事务。可以确保事务的完整和回滚数据结构:表名.frm存储表结构(MySQL8.0后合并到表名.ibd)表名.ibd存储数据和索引InnoDB是处理巨大数量的最大性能设计。在以前版本中,字典数据以元数据文件、非事务表等来存储。现在这些元数据文件被删除了。比如等都在MySQL8.0中不存在了。
如何查看本地MySQL的安装路径
热门推荐
强强的博客
05-10 5万+
    在命令窗口中输入mysql命令时,提示“mysql不是内部命令也不是可运行的程序”,发现此问题是由于系统的环境变量中未配置MySQL安装目录可执行文件的路径,可是安装MySQL时是默认按照的,此时已经忘记了安装位置,各个盘符中找了一遍,都没有找到。那么要怎样找到其安装的路径呢?    其实方法很简单,只需登录MySQL的客户端,然后输入命令:show variables like "%ch...
如何查看MySQL创建的数据库在电脑中的存储路径
m0_59281987的博客
09-24 2237
如何查看MySQL创建的数据库在电脑中的存储路径
如何查看本地的mysql安装的位置
weixin_44517927的博客
02-28 602
第一步:找到MySQLClient 如图一 双击打开 图一 第二步 进入MySQL客户端输入密码 如图二 图二 第三步 输入命令 show variables like “%char%”;
mysql数据库所在位置
07-28
在常见的Linux系统上,默认情况下,MySQL数据库文件通常位于`/var/lib/mysql/`目录下。而在Windows系统中,默认位置可能是`C:\ProgramData\MySQL\MySQL Server X.X\data\`,其中X.X代表MySQL的版本号。当然,这些...
写文章

热门文章

  • STM32 的PWM关闭方法 7932
  • golang illegal base64 data at input byte 7505
  • shell中打印带有时间的日志的命令(转) 6177
  • LR寄存器 6084
  • linux下使用ping出现connect:network is unreachable解决办法 5810

最新文章

  • 5. react 组件拆分 和 组件传值
  • RabbitMQ
  • mysql-5.7.27 安装
2019年781篇
2018年751篇
2017年741篇
2016年576篇
2015年387篇
2014年298篇
2013年283篇
2012年176篇
2011年143篇
2010年102篇
2009年116篇
2008年68篇
2007年57篇
2006年41篇
2005年28篇
2004年10篇
2001年1篇

目录

目录

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43元 前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值

深圳坪山网站建设公司优化网站上首页烟台网站seo优化服务霸州网站关键词优化肥西网站关键词优化中山企业网站优化二次开发柯桥网站优化推广网站排名优化贰金手指科捷7怎样对网站进行内外部链接优化济南家居行业网站优化推广怎么样应城市网站做优化报价山东哪里有网站优化平台网站建设优化公司宁波网站关键词优化公司英文网站优化简历江门网站优化推荐青岛智能网站优化开户惠山区网站整站优化苏州网站优化建设团队淄博优化网站平台昆明湖南网站优化推广长春实力强的网站优化与推广揭阳seo网站优化外包坪山网站排名优化价格南宁网站推广优化是什么茌平县优化网站公司沿河县分类网站优化.网站优化后的效果九江网站关键词优化报价武汉网站排名优化软件永宁农产品网站优化香港通过《维护国家安全条例》两大学生合买彩票中奖一人不认账让美丽中国“从细节出发”19岁小伙救下5人后溺亡 多方发声卫健委通报少年有偿捐血浆16次猝死汪小菲曝离婚始末何赛飞追着代拍打雅江山火三名扑火人员牺牲系谣言男子被猫抓伤后确诊“猫抓病”周杰伦一审败诉网易中国拥有亿元资产的家庭达13.3万户315晚会后胖东来又人满为患了高校汽车撞人致3死16伤 司机系学生张家界的山上“长”满了韩国人?张立群任西安交通大学校长手机成瘾是影响睡眠质量重要因素网友洛杉矶偶遇贾玲“重生之我在北大当嫡校长”单亲妈妈陷入热恋 14岁儿子报警倪萍分享减重40斤方法杨倩无缘巴黎奥运考生莫言也上北大硕士复试名单了许家印被限制高消费奥巴马现身唐宁街 黑色着装引猜测专访95后高颜值猪保姆男孩8年未见母亲被告知被遗忘七年后宇文玥被薅头发捞上岸郑州一火锅店爆改成麻辣烫店西双版纳热带植物园回应蜉蝣大爆发沉迷短剧的人就像掉进了杀猪盘当地回应沈阳致3死车祸车主疑毒驾开除党籍5年后 原水城县长再被查凯特王妃现身!外出购物视频曝光初中生遭15人围殴自卫刺伤3人判无罪事业单位女子向同事水杯投不明物质男子被流浪猫绊倒 投喂者赔24万外国人感慨凌晨的中国很安全路边卖淀粉肠阿姨主动出示声明书胖东来员工每周单休无小长假王树国卸任西安交大校长 师生送别小米汽车超级工厂正式揭幕黑马情侣提车了妈妈回应孩子在校撞护栏坠楼校方回应护栏损坏小学生课间坠楼房客欠租失踪 房东直发愁专家建议不必谈骨泥色变老人退休金被冒领16年 金额超20万西藏招商引资投资者子女可当地高考特朗普无法缴纳4.54亿美元罚金浙江一高校内汽车冲撞行人 多人受伤

深圳坪山网站建设公司 XML地图 TXT地图 虚拟主机 SEO 网站制作 网站优化