conda / conda

A system-level, binary package and environment manager running on all major operating systems and platforms.
https://docs.conda.io/projects/conda/
Other
6.49k stars 1.69k forks source link

Miniconda installation fails #10611

Open gro1m opened 3 years ago

gro1m commented 3 years ago

Current Behavior

In our company, we have a "software kiosk" for installing Miniconda silently on Windows 10 machines. For some people it does not work. As there are no installation logs, the software delivery team started to make some analysis of its own. What is observed that for the people for whom the installation does not work, the installer is blocked from forking subprocesses. Is this a known issue? Of course, we do not know if Windows is blocking or if it is something with the installer, if some can instruct on how I can provide more information, I would definitively like to do so. I also tried to ask here: https://stackoverflow.com/questions/66744993/miniconda-only-installs-partially-how-can-i-find-the-error, but unfortunately there has not be an answer that could resolve the issue.

Steps to Reproduce

C:\WINDOWS\ccmcache\32\Files\Miniconda3-py39_4.9.2-Windows-x86_64.exe /InstallationType=AllUsers /AddToPath=1 /RegisterPython=1 /S /D=C:\Company\Miniconda

Expected Behavior

The installer should be able to install Miniconda.

Environment Information

`conda info`

``` Not Applicable (i.e. does not work, as conda does not get installed) ```

`conda config --show-sources`

``` Not Applicable (i.e. does not work, as conda does not get installed) ```

`conda list --show-channel-urls`

``` Not Applicable (i.e. does not work, as conda does not get installed) ```

PrzemyslawSwiderski commented 1 year ago

I had similar issue when trying to install Miniconda with the /S flag. When executing the command it completes instantly but no installation is being created. The fix in my case was to change the /D param to some non-existing catalog, so that installer will create it. I also had to wrap the command with a start /wait. Full command in my case: start /wait Miniconda3-latest-Windows-x86_64.exe /InstallationType=JustMe /RegisterPython=0 /AddToPath=0 /S /D=P:\GITHUBREPOS\python-gradle-plugin\examples\geobuf-python-project\build\python\Windows\Miniconda3-install3 Where Miniconda3-install3 is non-existing folder.

@gro1m I hope it helps :)

LTLA commented 1 year ago

I have a similar issue where adding /S causes the Miniconda installer (py10_23.5.0-3) to quit immediately on Windows 11 without any activity. I tried @PrzemyslawSwiderski's fix above but unfortunately it doesn't work for me.

Full command is:

start /wait Miniconda3-py10_23.5.0-3-Windows-x86_64.exe /InstallationType=JustMe /AddToPath=0 /RegisterPython=0 /S /D=C:\Users/aaron/AppData/Local/conda

(Apologies for any typos, I don't have any credentials on the Windows machine, so I'm just copying it off the screen.)

AFAICT the last working version of the Windows installer was 4.12.0, which was successful with the arguments above.

The other tidbit of information is that it exits with %errorlevel% set to 2. No idea what that means.

vjcitn commented 10 months ago

Confirming that this problem persists with Windows 2022-datacenter-azure-edition-hotpatch. The conda documentation here is apparently incorrect.

henryruhs commented 6 months ago

From the documentation:

grafik

That means, using /S requieres /D as well. This is what the documentation says, but from my testing (with a Windows 11 sandbox) this is not needed.

It seems to fail only when it cannot write to the destination, I suggest to run silent uninstall first.

miniconda3\Uninstall-Miniconda3.exe /S
rmdir /s /q miniconda3
vjcitn commented 6 months ago

Trying with Miniforge3-24.1.2-0-Windows-x86_64.exe the /S is simply ignored no matter how /D is handled.

LTLA commented 4 months ago

After some trial and error, I figured out some additional restrictions:

This is in addition to the previously mentioned requirement that the directory doesn't already exist.

sskutnik commented 3 months ago

I'm trying this with Miniconda3-py312_24.1.2-0-Windows-x86_64.exe and the silent mode appears to fail no matter what (including using a truncated /D path with the correct separators)