Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to install docksal on windows 10 pro (1903 build 18362.239) #1103

Closed
alex-belyaev opened this issue Jul 22, 2019 · 13 comments
Closed

Comments

@alex-belyaev
Copy link

Description

Trying to install docksal on newly installed Win 10, during bash <(curl -fsSL https://get.docksal.io) got

ATTENTION: Installer requires administrative privileges to continue with Docksal setup.
           On macOS and Linux please enter your current user password,
           in Ubuntu App for Windows 10 use Linux user password in this step.
           For more information, see https://docs.docksal.io/getting-started/setup/#install
[sudo] password for alex:
'\\wsl$\Ubuntu-18.04\home\alex'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
[STEP 1/4] Updating fin...
'\\wsl$\Ubuntu-18.04\home\alex'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
fin 1.86.2 downloaded...
'\\wsl$\Ubuntu-18.04\home\alex'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
[STEP 2/4] Updating stack files...
overrides-ide.yml
overrides-osxfs.yml
services.yml
stack-acquia.yml
stack-default.yml
stack-default-nodb.yml
stack-node.yml
stack-pantheon.yml
volumes-bind.yml
volumes-nfs.yml
volumes-none.yml
volumes-unison.yml
Configuring network settings...
[STEP 3/4] Updating tools...
'\\wsl$\Ubuntu-18.04\home\alex'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
Installing docker-machine v0.16.1...
Downloading docker-machine-Windows-x86_64.exe...
############################################################################################################### 100.0%
chmod: changing permissions of '/c/Users/Alex/.docksal/bin/docker-machine.exe': Operation not permitted
Check file permissions and internet connection.

Also tried:

alex@Umbrella:~$ chmod +x /c/Users/Alex/.docksal/bin/docker-machine.exe
chmod: changing permissions of '/c/Users/Alex/.docksal/bin/docker-machine.exe': Operation not permitted
alex@Umbrella:~$ chmod +x /mnt/c/Users/Alex/.docksal/bin/docker-machine.exe
chmod: changing permissions of '/mnt/c/Users/Alex/.docksal/bin/docker-machine.exe': Operation not permitted

Output of fin config:

fin config output
alex@Umbrella:~$ fin config
'\\wsl$\Ubuntu-18.04\home\alex'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
 ERROR:  Cannot detect project root.
        Please make sure you have .docksal directory in the root of your project.
        To setup a basic Docksal stack in the current directory run fin config generate

Output of fin sysinfo:

fin sysinfo output
alex@Umbrella:~$ fin sysinfo
'\\wsl$\Ubuntu-18.04\home\alex'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
███  OS
WSL Ubuntu 18.04
Linux Umbrella 4.4.0-18362-Microsoft #1-Microsoft Mon Mar 18 12:02:00 PST 2019 x86_64 x86_64 x86_64 GNU/Linux

███  ENVIRONMENT
MODE : VirtualBox VM
DOCKER_HOST :

███  FIN
fin version: 1.86.2

███  DOCKER COMPOSE
EXPECTED VERSION: 1.23.2
docker-compose version 1.23.2, build 1110ad01
docker-py version: 3.6.0
CPython version: 3.6.7
OpenSSL version: OpenSSL 1.1.0f  25 May 2017

███  DOCKER
EXPECTED VERSION: 18.09.2

Client: Docker Engine - Community
Version:           18.09.2
API version:       1.39
Go version:        go1.10.8
Git commit:        6247962
Built:             Sun Feb 10 04:11:47 2019
OS/Arch:           linux/amd64
Experimental:      false
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

███  DOCKER MACHINE
EXPECTED VERSION: 0.16.1
/usr/local/bin/fin: line 5697: docker-machine: command not found

/usr/local/bin/fin: line 5699: docker-machine: command not found
███  DOCKER: DOCKER IS NOT RUNNING


███  HDD Usage
docker-machine executable was not found. (Try running 'fin update')
@Martins15
Copy link

I have the same issue after installing windows update. @lmakarov please investigate.

@lmakarov lmakarov added this to To do in Docksal 1.13.0 via automation Aug 6, 2019
@Martins15
Copy link

I've had a similar problem when I used windows ubuntu console. Then I've tried to install manually the latest virtualbox and latest babun, then install docksal using these 2 commands: https://docksal.io/installation#windows-virtualbox

And it worked!

@sean-e-dietrich
Copy link
Member

Thanks @Martins15 was able to confirm a similar but different issue

sean@DESKTOP-DAN4NA6:~$ curl -fsSL get.docksal.io | bash
'\\wsl$\Legacy\home\sean'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
wslpath: Invalid argument
[STEP 1/4] Updating fin...
'\\wsl$\Legacy\home\sean'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
wslpath: Invalid argument
fin 1.86.2 downloaded...
'\\wsl$\Legacy\home\sean'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
wslpath: Invalid argument
[STEP 2/4] Updating stack files...
overrides-ide.yml
overrides-osxfs.yml
services.yml
stack-acquia.yml
stack-default.yml
stack-default-nodb.yml
stack-node.yml
stack-pantheon.yml
volumes-bind.yml
volumes-nfs.yml
volumes-none.yml
volumes-unison.yml
Configuring network settings...
[STEP 3/4] Updating tools...
'\\wsl$\Legacy\home\sean'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
wslpath: Invalid argument
Installing docker-machine v0.16.1...
Downloading docker-machine-Windows-x86_64.exe...
######################################################################## 100.0%
 ALERT:  VirtualBox version should be 5.2.26 or higher
'\\wsl$\Legacy\home\sean'
CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.
wslpath: Invalid argument
Downloading and installing VirtualBox 5.2.26
Warning: Failed to create the file Usage: -a force result to absolute path
Warning: format -u translate from a Windows path to a WSL path (default) -w
Warning: translate from a WSL path to a Windows path -m translate from a WSL
Warning: path to a Windows path, with '/' instead of '\' EX: ws
curl: (23) Failed writing body (0 != 1492)

@lmakarov
Copy link
Member

There are two issues here. Both were introduced in the recent Windows 10 v1903 update, which added a new feature in WSL - Accessing Linux files from Windows.

From that article:

Known issues:
...
Accessing Linux files is treated the same as accessing a network resource, and any rules for accessing network resources will still apply e.g: When using CMD, cd \wsl$\Ubuntu\home will not work (as CMD does not support UNC paths as current directories), however copy \wsl$\Ubuntu\home\somefile.txt C:\dev\ will work
...

So Windows binaries in WSL are now launched with their working directory set to a UNC path like \\wsl$\Ubuntu\<working directory in WSL>, which results in the first issue.

Issue 1: CMD.EXE does not understand UNC paths

CMD.EXE was started with the above path as the current directory.
UNC paths are not supported.  Defaulting to Windows directory.

This is a non-fatal warning, which shows up whenever cmd.exe is invoked by fin.
It is a mere annoyance and will not cause any issues.

It only happens when running fin within a Linux directory (e.g. Linux user's home). Switching to a Windows directory (e.g., /mnt/c/) can be used as a workaround.

Looks like the issue is considered expected and may not get fixed in the new versions of WSL:
microsoft/WSL#3809 (comment)

Moving on.

Issue 2: Broken symlink resolution to Windows paths in WSL

This one is not obvious right away. The symptoms look like this

user@HTPC:/mnt/c$ bash <(curl -fsSL https://get.docksal.io)
...
[STEP 3/4] Updating tools...
Installing docker-machine v0.16.1...
Downloading docker-machine-Windows-x86_64.exe...
################################################################################################################# 100.0%
Creating docker machine 'docksal'...
 ERROR:  Proper creation of virtual machine has failed
        For details please refer to the log above.
        It is recommended to remove malfunctioned virtual machine.
Remove docksal? [y/n]:  

What actually happens their is calls to docker-machine binary fail silently. This is a fatal error and prevents fin from creating the VM.

Here's a more clear demonstration of the issue:

# broken
user@HTPC:~$ ~/.docksal/bin/docker-machine --version

# workaround
user@HTPC:~$ $(readlink ~/.docksal/bin/docker-machine) --version
docker-machine.exe version 0.16.1, build cce350d7

Note: wslpath binary also has issue with correctly resolving symlinks, which may be related to the Issue 2 above.

# broken
user@HTPC:~$ wslpath -w ~/.docksal/bin/docker-machine
\\wsl$\Ubuntu-18.04\home\user\.docksal\bin\docker-machine

# workaround
user@HTPC:~$ wslpath -w $(readlink ~/.docksal/bin/docker-machine)
C:\Users\htpc\.docksal\bin\docker-machine.exe

A relevant issue upstream: microsoft/WSL#4078

Note: I've been comparing the behavior using WSL on the following Windows versions:

  • Windows 10 v1903 (build 10.0.18362.295) - issues described above
  • Windows 10 v1803 (build 10.0.17134.950) - works as expected

lmakarov added a commit that referenced this issue Aug 16, 2019
@lmakarov lmakarov self-assigned this Aug 16, 2019
@lmakarov
Copy link
Member

Pushed fixes for both issues (fin v1.87.1).
Until this gets into a release, you can use install the development version of Docksal like this:

DOCKSAL_VERSION=develop bash <(curl -fsSL https://get.docksal.io)

Docksal 1.13.0 automation moved this from To do to Done Aug 16, 2019
@froboy
Copy link
Contributor

froboy commented Sep 6, 2019

I'm running into this same issue and the develop version hasn't resolved them.

I removed .docksal from both my Ubuntu home directory and Windows home, then ran the command above and still receive this error:

chmod: changing permissions of '/c/Users/aschwab_ct/.docksal/bin/docker-machine.exe': Operation not permitted

I realize this is closed, should I open a new ticket?

@froboy
Copy link
Contributor

froboy commented Sep 9, 2019

Update: here're my details:

Windows 10, v1903, build 18362.295

Remove all thethings and install:

$ rm -rf /c/Users/aschwab_ct/.docksal/
$ rm -rf ~/.docksal/
$ sudo rm -f /usr/local/bin/fin
$ DOCKSAL_VERSION=develop bash <(curl -fsSL https://get.docksal.io)
[!] Using Docksal version: develop
[STEP 1/4] Updating fin...
fin 1.87.1 downloaded...
[STEP 2/4] Updating stack files...
overrides-ide.yml
overrides-osxfs.yml
services.yml
stack-acquia.yml
stack-default.yml
stack-default-nodb.yml
stack-node.yml
stack-pantheon.yml
volumes-bind.yml
volumes-nfs.yml
volumes-none.yml
volumes-unison.yml
Configuring network settings...
[STEP 3/4] Updating tools...
Installing docker client v18.09.2...
Downloading docker-18.09.2.tgz...
################################################################################################################# 100.0%
Installing docker-compose v1.23.2...
Downloading docker-compose-Linux-x86_64...
################################################################################################################# 100.0%
Installing docker-machine v0.16.1...
Downloading docker-machine-Windows-x86_64.exe...
################################################################################################################# 100.0%
chmod: changing permissions of '/c/Users/aschwab_ct/.docksal/bin/docker-machine.exe': Operation not permitted
Check file permissions and internet connection.

output of fin sysinfo:

$ fin sysinfo
███  OS
WSL Ubuntu 18.04
Linux L36718-Win10 4.4.0-18362-Microsoft #1-Microsoft Mon Mar 18 12:02:00 PST 2019 x86_64 x86_64 x86_64 GNU/Linux

███  ENVIRONMENT
MODE : VirtualBox VM
DOCKER_HOST :

███  FIN
fin version: 1.87.1

███  DOCKER COMPOSE
EXPECTED VERSION: 1.23.2
docker-compose version 1.23.2, build 1110ad01
docker-py version: 3.6.0
CPython version: 3.6.7
OpenSSL version: OpenSSL 1.1.0f  25 May 2017

███  DOCKER
EXPECTED VERSION: 18.09.2

Client: Docker Engine - Community
 Version:           18.09.2
 API version:       1.39
 Go version:        go1.10.8
 Git commit:        6247962
 Built:             Sun Feb 10 04:11:47 2019
 OS/Arch:           linux/amd64
 Experimental:      false
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?

███  DOCKER MACHINE
EXPECTED VERSION: 0.16.1
/usr/local/bin/fin: line 443: --version: command not found

███  DOCKER: DOCKER IS NOT RUNNING


███  VIRTUALBOX
EXPECTED VERSION: 5.2.26
6.0.12r133076

███  HDD Usage
docker-machine executable was not found. (Try running 'fin update')

attempting to chmod the failing file. fin update reverts to the stable release from the dev version, so I have to run the installer, which seems to re-download the file, reverting the permissions anyway.

$ sudo chmod -x /c/Users/aschwab_ct/.docksal/bin/docker-machine.exe
$ ls -la /c/Users/aschwab_ct/.docksal/bin/docker-machine.exe
-rwxrwxrwx 1 root root 28615168 Sep  9 10:58 /c/Users/aschwab_ct/.docksal/bin/docker-machine.exe
$ fin system start
Configuring network settings...
docker-machine executable was not found. (Try running 'fin update')
$ DOCKSAL_VERSION=develop bash <(curl -fsSL https://get.docksal.io)
[!] Using Docksal version: develop
[STEP 1/4] Updating fin...
fin 1.87.1 downloaded...
[STEP 2/4] Updating stack files...
overrides-ide.yml
overrides-osxfs.yml
services.yml
stack-acquia.yml
stack-default.yml
stack-default-nodb.yml
stack-node.yml
stack-pantheon.yml
volumes-bind.yml
volumes-nfs.yml
volumes-none.yml
volumes-unison.yml
Configuring network settings...
[STEP 3/4] Updating tools...
Installing docker-machine v0.16.1...
Downloading docker-machine-Windows-x86_64.exe...
################################################################################################################# 100.0%
chmod: changing permissions of '/c/Users/aschwab_ct/.docksal/bin/docker-machine.exe': Operation not permitted
Check file permissions and internet connection.

@achekulaev achekulaev reopened this Sep 9, 2019
Docksal 1.13.0 automation moved this from Done to To do Sep 9, 2019
@achekulaev
Copy link
Member

The problem with the comment above is that for some reason WSL sees all files on Windows filesystem as owned by root. Surprisingly user is able to create/delete files, but not able to chmod successfully, at the same time however sudo chmod does not fail.

@froboy
Copy link
Contributor

froboy commented Sep 11, 2019

@achekulaev thanks for all your help here and in Slack. your last tip last night was a winner. I used the instructions in https://devblogs.microsoft.com/commandline/automatically-configuring-wsl/ to add options = "metadata" in the wsl.conf file, rebooted, and the installation is proceeding as expected now. I'm not quite through the woods yet, but this issue seem to be resolved. Thanks again!

@marcusanderss
Copy link

I tried to follow the instruction for docksalubuntu installation on windows 10:
https://docksal.io/installation#windows-virtualbox
I could not get it up and running. I have version 1809 build 17763.805

@marcusanderss
Copy link

ALERT: VirtualBox version should be 5.2.32 or higher
wslpath: Invalid argument
Do you want to download VirtualBox 5.2.32 to 'Usage: -a force result to absolute path format -u translate from a Windows path to a WSL path (default) -w translate from a WSL path to a Windows path -m translate from a WSL path to a Windows path, with '/' instead of '' EX: wslpath 'c:\users'/Downloads/VirtualBox-5.2.32-132073-Win.exe' and install it? [y/n]: y
Warning: Failed to create the file Usage: -a force result to absolute path
Warning: format -u translate from a Windows path to a WSL path (default) -w
Warning: translate from a WSL path to a Windows path -m translate from a WSL
Warning: path to a Windows path, with '/' instead of '' EX: wslpath
Warning: 'c:\users'/Downloads/VirtualBox-5.2.32-132073-Win.exe: No such file
Warning: or directory
0.0%
curl: (23) Failed writing body (0 != 1495)

@marcusanderss
Copy link

I uninstalled everything and downloaded latest virtualbox version.
~$ fin system start
wslpath: Invalid argument
Configuring network settings...
docker-machine executable was not found. (Try running 'fin update') doesn't work unfortunately

@digitalsanity
Copy link

@achekulaev thanks for all your help here and in Slack. your last tip last night was a winner. I used the instructions in https://devblogs.microsoft.com/commandline/automatically-configuring-wsl/ to add options = "metadata" in the wsl.conf file, rebooted, and the installation is proceeding as expected now. I'm not quite through the woods yet, but this issue seem to be resolved. Thanks again!

Thank you! This should be on the FAQ at least .. May 19, 2020 and I just spent a couple of hours tracking this down ..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
Development

No branches or pull requests

8 participants