开发者社区> 问答> 正文

mysql 符号连接数据报错1146的问题

我遇到了一个很头疼的问题,请大家帮看看。
我将A服务器数据库文件存到我的移硬盘里,然后在A服务器的MYSQL里使用 “符号连接” 方式连接到数据库库。是好用的哦
然后呢。我在B服务器上也是这么做,B服务器可以找到数据库,可以显示出所有,可是一双击表就显示 1146错误,找不到表。
请问这是什么问题呢?
附符号链接原文档:
2.6.2.5 Splitting Data Across Different Disks on Windows Beginning with MySQL Version 3.23.16, the mysqld-max and mysql-max-nt servers in the MySQL distribution are compiled with the -DUSE_SYMDIR option. This allows you to put a database on different disk by adding a symbolic link to it (in a manner similar to the way that symbolic links work on Unix). On Windows, you make a symbolic link to a database by creating a file that contains the path to the destination directory and saving this in the mysql_data' directory under the filename database.sym'. Note that the symbolic link will be used only if the directory mysql_data_dir\database' doesn't exist. For example, if the MySQL data directory is C:mysqldata' and you want to have database foo located at D:\data\foo', you should create the file C:mysqldatafoo.sym' that contains the text D:datafoo. After that, all tables created in the database foo will be created in D:\data\foo'. Note that because of the speed penalty you get when opening every table, we have not enabled this by default even if you have compiled MySQL with support for this. To enable symlinks you should put in your my.cnf' or `my.ini' file the following entry: [mysqld]use-symbolic-links In MySQL 4.0 we will enable symlinks by default. Then you should instead use the skip-symlink

展开
收起
落地花开啦 2016-02-11 12:55:52 2956 0
1 条回答
写回答
取消 提交回答
  • 默认配的盘符对吗

    2019-07-17 18:40:36
    赞同 展开评论 打赏
问答排行榜
最热
最新

相关电子书

更多
One Box: 解读事务与分析一体化数据库 HybridDB for MySQL 立即下载
One Box:解读事务与分析一体化数据库HybridDB for MySQL 立即下载
如何支撑HTAP场景-HybridDB for MySQL系统架构和技术演进 立即下载

相关镜像