The forum is in read only mode.

blockMesh command not found

  • nottern
  • Topic Author
  • Offline
  • New Member
  • New Member
12 years 3 months ago #6258 by nottern
blockMesh command not found was created by nottern
I can't run the blockMesh command, says that it is not found
but the file blockMeshApp.C exists in the directory opt/openfoam201/applications/mesh/generation/blockMesh
how can i run the program?
12 years 3 months ago #6262 by Joël Cugnoni
Replied by Joël Cugnoni on topic Re: blockMesh command not found

you need to run this from an OpenFOAM aware terminal. Either start CAELinux-> OpenFoam Terminal or open a standard terminal and source the OpenFoam environment:

source /opt/.bashrc-OpenFOAM

or if you have a custom install:

source /opt/openfoam201/etc/bashrc

then it should work.

Joël Cugnoni - a.k.a admin
6 years 8 months ago #9182 by Daniel Iyinomen
Replied by Daniel Iyinomen on topic Re: blockMesh command not found
Hi Jcugnoni,

I had same problem and just followed your suggestion but still not working. I'm running OpenFoam version 2.0 on Ubuntu (linux) 16.04. Please what should I do? Below is the command error.

daniel@ubuntu:~$ cd fireFoam/OpenFOAM/training/cavity
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity$ ls
0 constant system
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity$ blockMesh
blockMesh: command not found

Below are the content in the folders :

daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity$ cd 0
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity/0$ ls
p U
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity/0$ cd ../..
daniel@ubuntu:~/fireFoam/OpenFOAM/training$ cd cavity/constant
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity/constant$ ls
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity/constant$ cd ../..
daniel@ubuntu:~/fireFoam/OpenFOAM/training$ cd cavity/system
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity/system$ ls
blockMeshDict controlDict fvSchemes fvSolution
daniel@ubuntu:~/fireFoam/OpenFOAM/training/cavity/system$ cd ../..
daniel@ubuntu:~/fireFoam/OpenFOAM/training$ cd cavity
6 years 7 months ago #9192 by Joël Cugnoni
Replied by Joël Cugnoni on topic Re: blockMesh command not found

if you are running CAELinux 2013, you should use the specific link Applications->Education->OpenFOAM 2.1.1 terminal to have terminal with all the variables set properly.

If you are not running a stock CAELinux install, then you need to set the environement manualy by sourcing the /opt/openfoamXXX/etc/bashrc file before you can use OpenFOAM.

For example in CAELinux 2013, OpenFOAM 2.1.1 is installed, so you should start a terminal, and then
source /opt/openfoam211/etc/bashrc

and then all the OpenFOAM commands will be available in that terminal until you close it. So make sure that you use that terminal for the tutorial!

If it does not work, please check if/which version of OpenFOAM is installed by looking at the output of
ll /opt

and then adapt the path to /opt/openfoamXX/etc/bashrc accordingly

Joël Cugnoni - a.k.a admin
Moderators: catux
Time to create page: 0.119 seconds
Powered by Kunena Forum