我正在尝试在 linux 虚拟机中安装知识。要安装知识,我必须安装 mysql。
当我安装 mysql 时,我得到了这个我发现的任何方式都无法解决的典型错误。
处理时遇到错误:
mysql-server-5.7
mysql-server
当我尝试命令 service mysql -status 时,它告诉我:
无法通过套接字'/var/run/mysqld/mysqld.sock''连接到本地mysql服务器
该目录不存在,因此在互联网上查找,我通过修改文件 my.conf 找到了解决方案,但该文件看起来不像其他人的示例。
#
# The MySQL database server configuration file.
#
# You can copy this to one of:
# - "/etc/mysql/my.cnf" to set global options,
# - "~/.my.cnf" to set user-specific options.
#
# One can use all long options that the program supports.
# Run program with --help to get a list of available options and with
# --print-defaults to see which it would actually understand and use.
#
# For explanations see
# http://dev.mysql.com/doc/mysql/en/server-system-variables.html
#
# * IMPORTANT: Additional settings that can override those from this file!
# The files must end with '.cnf', otherwise they'll be ignored.
#
!includedir /etc/mysql/conf.d/
!includedir /etc/mysql/mysql.conf.d/
我不知道这会解决我的问题,但这让我很头疼。主要问题是由于mysql安装错误,我无法安装knowage。
太感谢了!