I'm using:
Mac OS X
MySQL Ver 14.14 Distrib 5.6.27
And latest MySQL workbench, which, for some reason, still telling me, that it uses MySQl version 5.6.24.
So, I could create new connections, but when I try to configure local management, in stage of test settings I always get:
Error: error calling Python module function
WbAdmin.testInstanceSettingByName
Check if /etc/my.cnf can be accessed File was found at the expected
location Check if section for instance mysqld exists in /etc/my.cnf
Traceback (most recent call last): File
"/Applications/MySQLWorkbench.app/Contents/Resources/plugins/wb_admin_grt.py",
line 777, in testInstanceSettingByName
if check_if_config_file_has_section(open(config_file, "r"), section): IOError: [Errno 13] Permission denied: '/etc/my.cnf'
Operation failed: error calling Python module function
WbAdmin.testInstanceSettingByName
I suppose, that it is caused by absence of any server instances. When I try to Rescan for Local MySQL Servers, I get message:
No servers were found.
So, what's wrong? How to solve this problem, how to create a server instance?
Related
I'm trying to transfer my database from Microsoft Access to MySQL (I'm using MySQL workbench). for that I need to connect MySQL to Access but I'm facing some problems.
I'm following these guidelines:
https://dev.mysql.com/doc/workbench/en/wb-migration-database-access.html
when testing the connection it shows this error message:
Unhandled exception: grt.Dict key must be string.
I checked the log for more information and this is what I found :
Starting...
Connect to source DBMS...
- Connecting to source...
Connecting to ...
Opening ODBC connection to DSN=northwind...
Traceback (most recent call last):
File "C:\Program Files\MySQL\MySQL Workbench 8.0 CE\modules\db_msaccess_re_grt.py", line 701, in connect
return MsAccessReverseEngineering.connect(connection, password)
File "C:\Program Files\MySQL\MySQL Workbench 8.0 CE\modules\db_msaccess_re_grt.py", line 152, in connect
con = db_driver.connect(connection, password)
File "C:\Program Files\MySQL\MySQL Workbench 8.0 CE\workbench\db_driver.py", line 95, in connect
connection = library.connect(connection_string, password=password)
pyodbc.Error: ('HY000', 'The driver did not supply an error!')
Traceback (most recent call last):
File "C:\Program Files\MySQL\MySQL Workbench 8.0 CE\workbench\wizard_progress_page_widget.py", line 71, in run
self.func()
File "C:\Program Files\MySQL\MySQL Workbench 8.0 CE\modules\migration_source_selection.py", line 456, in task_connect
username = self.main.plan.migrationSource.connection.parameterValues.userName
KeyError: 'grt.Dict key must be a string'
ERROR: Error during Connect to source DBMS: 'grt.Dict key must be a string'
ERROR: Exception in task 'Connect to source DBMS': KeyError('grt.Dict key must be a string',)
Failed
It seems that I need to make some changes in the files but I don't have any idea how to do that and I couldn't find answers to that online.
Hello this is late [very]. The solution that worked for me was making sure during adding a DSN (Data Source Name) you added your database [as in the ms access file]
See this image if my words aren't clear:
You see this error if you're trying to migrate data from an old-format database (Access < 2010 .mdb file) using a newer ODBC connector. First save the file in a more recent format first (.accdb), and then try the migration again.
Does MySql workbench support the DB2 to MySql migration ?
Steps I followed :
Installed DB2 ODBC driver and and defined the conection parameters for my DB2 database in 'Source Selection'.
I am using Database System as "Generic RDBMS" and Connection Method as "ODBC Data Source" and DSN with DB2 ODBC driver.
Defined the MySql database details in 'Target Selection'
When I do next and it goes to 'Fetch Schema List', I get error as below. Although my source and target database connection successful.
Error logs from workbench as follows :
Starting...
Connect to source DBMS...
Connecting to source...
Connection to apparently lost, reconnecting...
Connecting to ...
Opening ODBC connection to DSN=EESBPTS...
Connected
Connect to source DBMS done
Check target DBMS connection...
Connecting to target...
Check target DBMS connection done
Retrieve schema list from source....
Checking connection...
Connection to apparently lost, reconnecting...
Connecting to ...
Opening ODBC connection to DSN=EESBPTS...
Connected
Fetching catalog names...
Fetching schema names...
Fetching schema names from None...
Traceback (most recent call last):
File "C:\Program Files\MySQL\MySQL Workbench 6.2 CE\workbench\wizard_progress_page_widget.py", line 192, in thread_work
self.func()
File "C:\Program Files\MySQL\MySQL Workbench 6.2 CE\modules\migration_source_selection.py", line 456, in task_fetch_schemata
self.main.plan.migrationSource.doFetchSchemaNames(only_these_catalogs)
File "C:\Program Files\MySQL\MySQL Workbench 6.2 CE\modules\migration.py", line 255, in doFetchSchemaNames
self.state.sourceSchemataNames.append("%s.%s" % (self._db_module.quoteIdentifier(catalog), self._db_module.quoteIdentifier(schema)))
TypeError: DbGenericRE.quoteIdentifier(): argument 1 must be a string but is None
ERROR: Retrieve schema list from source: DbGenericRE.quoteIdentifier(): argument 1 must be a string but is None
Failed
Please help me to proceed further.
Mysql performance tuning,
when i am executing tuning-primer.sh script on cygwin on windows os that type of error occurs.
No valid socket file "/tmp/mysql.sock" found!
The mysqld process is not running or it is installed in a custom location.
If you are sure mysqld is running, execute script in "prompt" mode or set
the socket= variable at the top of this.
tuning-primer.sh script downloaded from https://launchpad.net/mysql-tuning-primer , after all i have run this script with prompt mode provide uid,pwd error is same.
any solution ?..
Note: Mysql server 5.6.14 is running on my computer. I have mysql.sock file in /var/lib/mysql/mysql.soc directory. I also link as /tmp/mysql.sock.
In my form field type, i edit the file menu these error will appear,
Fatal error: Uncaught exception 'PDOException' with message
'SQLSTATE[HY000]: General error: 2006 MySQL server has gone away' in
D:\wamp\www\cms_development\includes\database\database.inc on line
2168 ( ! ) PDOException: SQLSTATE[HY000]: General error: 2006 MySQL
server has gone away in
D:\wamp\www\cms_development\includes\database\database.inc on line
2168
Anybody Know how to rectify this error...
This may be because of max_allowed_packet
Change in the my.ini/my.cnf file. Include the single line under [mysqld] in your file
max_allowed_packet=500M
now restart the MySQL service once you are done. You can see it's curent value in mysql like this:
SHOW VARIABLES LIKE 'max_allowed_packet'
You can read about it here http://dev.mysql.com/doc/refman/5.1/en/packet-too-large.html
This is for Linux Users.In terminal,
Step 1:
locate my.cnf
And you copy the Path
Step 2:
sudo gedit "Paste the path"
Step 4:
Changed "max_allowed_packet" from "1m" to "32m" and saved my.cnf
sudo "path" restart
(or) Do Normal System Restart
I had a similar problem. mysql would crash while drupal8 was going through install process. restarting mysql would eliminate the "mysql has gone away ..." error but drupal install would never finish. the following combination of mysql and apache configs provided a stable digitalocean droplet for me:
https://www.digitalocean.com/community/questions/mysql-server-keeps-stopping-unexpectedly?answer=26016
I'm using MySql Workbench to connect to a remote MySQL instance. I have a connection setting that allows me query tables, create tables... but it fails when I try to migrate data from Microsoft SQL Server to MySQL.
Here are the steps:
Database -> migration... Enter the connection data for Source DBMS -> test connection pass. Enter the source DBMS select the existing saved connection -> test connection pass. Go to next step.
I receive the error Can't connect to MySQL server on '127.0.0.1' (10061) (code 2003).
Below the complete log. Any ideas?
> Starting...
Connect to source DBMS...
- Connecting to source...
Connect to source DBMS done
Check target DBMS connection...
- Connecting to target...
Connecting to Mysql#localhost::3306#localhost:32222...
Traceback (most recent call last):
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\modules\db_mysql_fe_grt.py", line 137, in connect
con.connect()
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\workbench\db_utils.py", line 169, in connect
raise MySQLError(modules.DbMySQLQuery.lastError(), modules.DbMySQLQuery.lastErrorCode(), "%s#%s" % (self.connect_info.parameterValues["userName"], self.connect_info.parameterValues["hostName"]))
workbench.db_utils.MySQLError: Can't connect to MySQL server on '127.0.0.1' (10061) (code 2003)
Connecting to Mysql#localhost::3306#localhost:32222...
Traceback (most recent call last):
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\modules\db_mysql_fe_grt.py", line 137, in connect
con.connect()
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\workbench\db_utils.py", line 169, in connect
raise MySQLError(modules.DbMySQLQuery.lastError(), modules.DbMySQLQuery.lastErrorCode(), "%s#%s" % (self.connect_info.parameterValues["userName"], self.connect_info.parameterValues["hostName"]))
workbench.db_utils.MySQLError: Can't connect to MySQL server on '127.0.0.1' (10061) (code 2003)
Traceback (most recent call last):
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\workbench\wizard_progress_page_widget.py", line 65, in run
self.func()
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\modules\migration_source_selection.py", line 450, in task_test_target
raise e
SystemError: MySQLError("Can't connect to MySQL server on '127.0.0.1' (10061) (code 2003)"): error calling Python module function DbMySQLFE.connect
ERROR: Error during Check target DBMS connection: MySQLError("Can't connect to MySQL server on '127.0.0.1' (10061) (code 2003)"): error calling Python module function DbMySQLFE.connect
Traceback (most recent call last):
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\workbench\wizard_progress_page_widget.py", line 543, in update_status
task.run()
File "C:\Program Files (x86)\MySQL\MySQL Workbench 5.2 CE\workbench\wizard_progress_page_widget.py", line 80, in run
raise e
SystemError: MySQLError("Can't connect to MySQL server on '127.0.0.1' (10061) (code 2003)"): error calling Python module function DbMySQLFE.connect
ERROR: Exception in task 'Check target DBMS connection': SystemError('MySQLError("Can\'t connect to MySQL server on \'127.0.0.1\' (10061) (code 2003)"): error calling Python module function DbMySQLFE.connect',)
I got the same error in MySQL Workbench 5.2.47 with two MySQL databases which work fine otherwise. It seems like a bug and I am surprised Oracle released a non-working wizard.
A workaround is to use Server Administration in Workbench for the two databases and use Data Export and Data Import/Restore respectively. However, this only works if you migrate from MySQL to MySQL. In addition, Data Export/Import functionality is buggy too.