-bash: ./mfixsolver: No such file or directory

I copied the .mfx file set in MFIX on Windows to the WSL environment and followed the command in the official website file:“build_mfixsolver --batch -j”, and it showed that BUILD SUCCESSFUL. However, When I entered “mfixsolver -f .mfx” or “mpirun -np 4 ./mfixsolver -f .mfx NODESI=2 NODESJ=2 NODESK=1” in the terminal, the error was reported as follows:
[proxy:0:0@WDY-PC] HYDU_create_process (utils/launch/launch.c:74): execvp error on file ./mfixsolver (No such file or directory)
[proxy:0:0@WDY-PC] HYDU_create_process (utils/launch/launch.c:74): execvp error on file ./mfixsolver (No such file or directory)
[proxy:0:0@WDY-PC] HYDU_create_process (utils/launch/launch.c:74): execvp error on file ./mfixsolver (No such file or directory)
[proxy:0:0@WDY-PC] HYDU_create_process (utils/launch/launch.c:74): execvp error on file ./mfixsolver (No such file or directory)


Does anyone know where the error occurred

Hi @gzy

Note that WSL is not supported or tested by us at all. What is your motivation for using it?

I don’t currently have a WSL instance for testing but I have a guess what might be happening here.

The “interactive” solver (which allows the GUI to pause, stop, modify, and examine a running job) is started by a script which is called mfixsolver.sh on Linux and mfixsolver.bat on Windows. On Linux we create a symlink mfixsolver -> mfixsolver.sh but since symbolic links require administrator privilege on Windows, we omit this step.

For comparison, the “batch” solver (which does not support interaction with the GUI) is a binary not a script and is called mfixsolver on Linux and mfixsolver.exe on Windows. The intention is that the solver can be started by typing ‘mfixsolver’ regardless of whether it is built in batch or interactive mode.

Your installation shows “Installing: mfixsolver.sh” so it looks like WSL is being detected as some kind of Linux, but somehow the symlink is not being made. I wonder if it is because of this:

WINDOWS = sys.platform.startswith('win')

I’m not sure what sys.platform reports on WSL. Can you please start a Python prompt under WSL and do

>>> import sys
>>> print(sys.platform)

Thank you for your reply!
I think MFIX can only perform parallel computing in a Linux environment, but not in Windows.
And according to your prompts, type the command in the terminal and get the following results.

Something is strange here, you say you built in batch mode but the last line of the install in your screenshot says Installing: mfixsolver.sh instead of Installing: mfixsolver

Is there a file called mfixsolver in your work dir? Are you sure you specified the --batch flag?

As a test, I did the following:

  1. Install WSL on WIndows 11 via wsl --install

  2. Download and run https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-Linux-x86_64.sh to set up Mamba in WSL. (Mamba is a lightweight alternative to Anaconda, we are switching over from Anaconda to Mamba for the next MFiX release).

  3. Download and install MFiX as a Conda/Mamba package from https://mfix.netl.doe.gov/products/mfix/download/
    Skip step 1 “Download Anaconda” and for step 2 replace the conda at the beginning of the command line with mamba.

  4. Activate the mfix-23.3.2 environment: mamba activate mfix-23.3.2

When I do this and run build_mfixsolver -j I get this:

Note Installing: mfixsolver not Installing: mfixsolver.sh

Again, WSL is not supported or recommended by the MFiX team, but you might be able to get it to work. Note that the native Windows version of MFiX supports SMP but not DMP. It might be possible to get DMP working using Microsoft MPI but nobody has tried this yet.

Thank you for your reply, but strangely enough, I compiled the batch command according to the official website file( 5.2. Building a Batch Solver — MFiX 23.3 documentation )After compilation, only the generated mfixsolver. so file is displayed instead of the mfixslover. I will carefully investigate the reason and thank you again for your answer.

Please un

(mfix-23.3.2)$ build_mfixsolver  --verbose --dmp --batch >& build_log.txt 

and upload the build_log.txt file here.

– Charles