mac 安装mysql出现一系列问题
1.在mysql官网下载5.7版本后安装,按照网上的一堆教程折腾半天,就是进不去,5.7的下载之后里边的文件显示与网上的教程都不一样,感觉少了些东西;
2.于是下载mysql5.6,打开mac终端,莫名显示如下(新打开就有,应该是什么地方配置有问题)
Last login: Sun Mar 13 17:10:15 on ttys000
-bash: Setting: command not found
lyzdeMacBook-Air:~ lyz$
3.输入以下,出现这样
lyzdeMacBook-Air:~ lyz$ /usr/local/mysql-5.6.29-osx10.8-x86_64/bin/mysql -u root -p
Enter password:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
4.查看my.cnf
# For advice on how to change settings please see
# http://dev.mysql.com/doc/refman/5.6/en/server-configuration-defaults.html
[mysqld]
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin
# These are commonly set, remove the # and set as required.
# datadir = ...
# port = ...
# server_id = ...
# socket = ...
# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
5./tmp目录下没有mysql.sock这个文件
大神帮忙看下,该怎么样才能使用mysql
2.于是下载mysql5.6,打开mac终端,莫名显示如下(新打开就有,应该是什么地方配置有问题)
Last login: Sun Mar 13 17:10:15 on ttys000
-bash: Setting: command not found
lyzdeMacBook-Air:~ lyz$
3.输入以下,出现这样
lyzdeMacBook-Air:~ lyz$ /usr/local/mysql-5.6.29-osx10.8-x86_64/bin/mysql -u root -p
Enter password:
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
4.查看my.cnf
# For advice on how to change settings please see
# http://dev.mysql.com/doc/refman/5.6/en/server-configuration-defaults.html
[mysqld]
# Remove leading # and set to the amount of RAM for the most important data
# cache in MySQL. Start at 70% of total RAM for dedicated server, else 10%.
# innodb_buffer_pool_size = 128M
# Remove leading # to turn on a very important data integrity option: logging
# changes to the binary log between backups.
# log_bin
# These are commonly set, remove the # and set as required.
# datadir = ...
# port = ...
# server_id = ...
# socket = ...
# Remove leading # to set options mainly useful for reporting servers.
# The server defaults are faster for transactions and fast SELECTs.
# Adjust sizes as needed, experiment to find the optimal values.
# join_buffer_size = 128M
# sort_buffer_size = 2M
# read_rnd_buffer_size = 2M
sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES
5./tmp目录下没有mysql.sock这个文件
大神帮忙看下,该怎么样才能使用mysql
...全文
相关推荐
Mac M系列Docker安装MySQL[源码]
为了在Mac M系列芯片上顺利安装并使用MySQL 5.7.42版本,本文详细描述了一系列步骤,首先解决了由于架构不匹配导致的Docker镜像拉取问题。
Mac安装MySQL指南[代码]
在Mac操作系统上安装MySQL数据库管理系统是一项基础但重要的任务,尤其是对于软件开发人员来说。为了完成这个任务,初学者需要遵循一系列明确的步骤。
Mac安装MySQL教程[项目代码]
通过以上介绍,我们可以看到,Mac上安装MySQL的过程包括多个步骤,需要用户仔细执行,并且在完成安装之后,还需要进行一系列的配置和优化工作,以确保MySQL数据库的稳定和安全运行。
Mac使用Homebrew安装MySQL[源码]
在Mac操作系统中安装MySQL数据库管理系统通常涉及到一系列的操作步骤,尤其当用户希望通过软件包管理工具Homebrew进行安装时。
详细的MySQL MAC软件安装、配置指南.zip
在Mac上安装MySQL需要遵循一系列步骤,包括下载安装包、配置环境变量、创建数据库用户以及启动和管理MySQL服务。首先,你需要从MySQL官方网站下载适用于Mac的最新版本安装包。


