CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   [OpenFOAM.org] Getting Started: mkdir missing operand (https://www.cfd-online.com/Forums/openfoam-installation/143697-getting-started-mkdir-missing-operand.html)

sisi October 31, 2014 06:18

Getting Started: mkdir missing operand
 
I have exactly the same problem:

Quote:

mkdir -p $FOAM_RUN
Error:

Quote:

mkdir: missing operand
Try `mkdir --help' for more information.
How to declare the variable???

Quote:

FOAM_RUN=run
:confused:

alexeym October 31, 2014 08:07

Hi,

variable FOAM_RUN is defined on line 204 of $WM_PROJECT_DIR/etc/config/settings.sh file.

If yours is empty, it seems you've forgotten to set up environment with
Code:

$ source <path to your OpenFOAM installation>/etc/bashrc

sisi October 31, 2014 09:40

Thanks! I need to learn more about OpenFOAM Environment Variables. That did solve my problem:

Code:

source $HOME/OpenFOAM/OpenFOAM-2.3.0/etc/bashrc

HappyS5 May 31, 2018 19:58

mkdir: missing operand
 
Hello,

I am new to OpenFOAM and Ubuntu.

When I try to do the following:

mkdir -p $FOAM_RUN

I get the following error:

mkdir: missing operand
Try 'mkdir --help' for more information.

Can someone help me please. Remember, I am new to OpenFOAM and UBuntu. So please be detailed with your help.

wyldckat June 1, 2018 16:25

Quick question/answer: Knowing which version of OpenFOAM and Ubuntu, as well as which installation instructions you've followed, would make it easier to diagnose the problem.

So, I'll try guessing that you installed OpenFOAM 5 Deb package(s) on Ubuntu 16.04 or 17.10, in which case, you will need to run the following command to activate this version of OpenFOAM:
Code:

source /opt/openfoam5/etc/bashrc
For more details, read the respective version's section "User Configuration" here: https://openfoam.org/download/5-0-ub...-configuration

Then you should be able to run the command:
Code:

mkdir -p $FOAM_RUN
without any problems... or at least I hope so, unless something went wrong during the installation.


All times are GMT -4. The time now is 01:29.