WSL2 터미널에서 아래 명령어로 Ubuntu 패키지를 업데이트합니다. 아래 명령어로 mysql을 설치합니다. 설치확인하고 버전 번호를 확인합니다. 해당 명령어로 mysql을 실행합니다. 위 명령어를 실행한 후에 아래와 같은 에러가 발생한다면 아래와 같이 명령어를 실행해줍니다. (리눅스OS에 따라 상이)MySQL 시작
I do not know how to make Ubuntu 20.04 su behave like Ubuntu 18.04 su.
The difference is because in Ubuntu 20.04/Focal su is provided by the util-linux package. In Ubuntu 18.04/Bionic su is provided by the login package (built from the source package shadow).
A key implementation difference appears to be support for DEFAULT_HOME in /etc/login.defs. The manpage for Bionic's su mentions in its Configuration section
DEFAULT_HOME (boolean) Indicate if login is allowed if we can't cd to the home directory. Default is no. If set to yes, the user will login in the root (/) directory if it is not possible to cd to her home directory.The manpage for Focal's version of su does not mention DEFAULT_HOME.
I found a few relevant entries in the changelog for the shadow package
* Use explicit --without-su configure flag -- Balint Reczey <> Fri, 20 Dec 2019 16:39:40 +0100 ... * Drop Lintian override for su, it is not shipped in login anymore -- Balint Reczey <> Mon, 08 Jul 2019 15:58:46 +0200 ... * Stop shipping su and break old util-linux version. (See #833256) -- Andreas Henriksson <> Fri, 27 Jul 2018 10:07:37 +0200It looks like the change was made upstream in Debian and coordinated in //bugs.debian.org/cgi-bin/bugreport.cgi?bug=833256 . The lack of DEFAULT_HOME support is mentioned but is not considered a blocker.
标签: 数据库 mysql
这种错误一般是 mysql 服务器异常关机导致的,解决方案如下:
# Ubuntu
sudo service mysql stop
sudo usermod -d /var/lib/mysql/ mysql
sudo service mysql start
# CentOS sudo systemctl stop mysql.service sudo usermod -d /var/lib/mysql/ mysql sudo systemctl start mysql.service
智能推荐
ubuntu系统mysql.h no such file or directory
在Ubuntu系统中,你已经安装了mysql,即你使用sudo apt-get install mysql-server mysql-client然而使用C语言访问mysql数据库时,却发现出现了如下错误: 出现这个错误是因为系统没有安装mysql安装包 sudo apt-get install libmysql++-dev即可 编译时需要加连接-lmysqlclient. 编译源程序的时候,...
mysql_connect(): [2002] No such file or directory
在mac中搭建php的开发环境 1. apach ---- 推荐用MAMP。你只要把你的php文件/项目放入到htdocs(/Applications/MAMP/htdocs)目录下,启动mamp,输入localhost就可以直接看见你这个目录下的所有文件了。--由于这种相对简单,这里不再赘述,如果任何问题,欢迎联系交流。 2. nginx ---- 由于没有已经集成的工具,nginx...
猜你喜欢
docker build no such file or directory
在我构建新的镜像的时候, 发生 了 no such file or directory 的错误。 这个错误找了半天, 没头绪, 后来灵光一现, 原来是我的文件夹名字写错了 我的目录结构是这样的 sample 文件夹中有一个Dockerfile 文件和一个nginx文件夹, nginx文件夹中有global.conf&nbs...
2020-10-12 21:33:27 阅读:1901 来源: 互联网
标签:service No sudo stop var start cannot mysql directory
这种错误一般是 mysql 服务器异常关机导致的,解决方案如下:
# Ubuntusudo service mysql stop sudo usermod -d /var/lib/mysql/ mysql sudo service mysql start# CentOS sudo systemctl stop mysql.service sudo usermod -d /var/lib/mysql/ mysql sudo systemctl start mysql.service
标签:service,No,sudo,stop,var,start,cannot,mysql,directory
来源: //www.cnblogs.com/cnwcl/p/13805643.html
Error
su: warning: cannot change directory to /nonexistent: No such file or directory
taehyeki 2022. 2. 2. 17:07
MySQL 설치
WSL2 터미널에서
아래 명령어로 Ubuntu 패키지를 업데이트합니다.
sudo apt update아래 명령어로 mysql을 설치합니다.
sudo apt install mysql-server설치확인하고 버전 번호를 확인합니다.
mysql --versionMySQL 시작
해당 명령어로 mysql을 실행합니다.
sudo /etc/init.d/mysql start위 명령어를 실행한 후에
아래와 같은 에러가 발생한다면
su: warning: cannot change directory to /nonexistent: No such file or directory아래와 같이 명령어를 실행해줍니다. (리눅스OS에 따라 상이)
# Ubuntu sudo service mysql stop sudo usermod -d /var/lib/mysql/ mysql sudo service mysql start