Mysql показывает ошибку /etc/profile.d/wsl-integration.sh: невозможно создать //.cache/wslu/integration: DirectoryWSL: Ubuntu

Я устанавливаю mysql в WSL: Ubuntu 18.04 когда я перезапускаю mysql sudo service mysql restart показывает ошибку:

No directory, logging in with HOME=/
mkdir: cannot create directory ‘//.cache’: Permission denied
-su: 20: /etc/profile.d/wsl-integration.sh: cannot create //.cache/wslu/integration: Directory nonexistent

, затем попробуйте изменить файл /etc/profile.d/wsl-integration.sh

# Check if we have HOME folder
if [[ "${HOME}" == "/" ]]; then
  exit 0
fi

, но он не работает .... и показать ошибку:

No directory, logging in with HOME=/
-su: 2: /etc/profile.d/wsl-integration.sh: [[: not found
mkdir: cannot create directory ‘//.cache’: Permission denied
-su: 23: /etc/profile.d/wsl-integration.sh: cannot create //.cache/wslu/integration: Directory nonexistent

Как исправить эту проблему? спасибо ....

0
задан 20 July 2020 в 05:23

1 ответ

Может быть, вы можете найти файл .cache/wslu/integration в /home//. Там вы можете изменить файл /etc/profile.d/wsl-integration.sh следующим образом:

HOME=/home/your_name

и убрать проверку ${HOME}

1
ответ дан 2 September 2020 в 01:57

Другие вопросы по тегам:

Похожие вопросы: