CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Installation

OpenFOAM-1.6 install cookbook

Register Blogs Members List Search Today's Posts Mark Forums Read

Like Tree1Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 23, 2009, 17:38
Default
  #21
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
What is the output of "echo $FOAM_APPBIN" and "which blockMesh"? If one of both doesn't give you a path, rerun foamInstallationTest and post the output.
akidess is offline   Reply With Quote

Old   September 23, 2009, 17:54
Default
  #22
Member
 
Join Date: May 2009
Posts: 54
Rep Power: 17
gfilip is on a distinguished road
"which blockMesh" does not give an output. Here is the output of foamInstallationTest

Code:
Executing /home/greg/OpenFOAM/OpenFOAM-1.6.x/bin/foamInstallationTest:


Checking basic setup...
-------------------------------------------------------------------------------
Shell:              bash
Host:               greg-laptop
OS:                 Linux version 2.6.24-24-generic
-------------------------------------------------------------------------------


Checking main OpenFOAM env variables...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid      Crit
-------------------------------------------------------------------------------
$WM_PROJECT_INST_DIR /home/greg/OpenFOAM                      yes       yes
$WM_PROJECT_USER_DIR /home/greg/OpenFOAM/greg-1.6.x           yes       no
$WM_THIRD_PARTY_DIR  /home/greg/OpenFOAM/ThirdParty-1.6.x     yes       yes
-------------------------------------------------------------------------------


Checking the OpenFOAM env variables set on the PATH...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid Path Crit
-------------------------------------------------------------------------------
$WM_PROJECT_DIR      /home/greg/OpenFOAM/OpenFOAM-1.6.x       yes  yes  yes

$FOAM_APPBIN         ...1.6.x/applications/bin/linuxGccDPOpt  yes  yes  yes
$FOAM_SITE_APPBIN    ...penFOAM/site/1.6.x/bin/linuxGccDPOpt  no        no
$FOAM_USER_APPBIN    ...1.6.x/applications/bin/linuxGccDPOpt  no        no
$WM_DIR              /home/greg/OpenFOAM/OpenFOAM-1.6.x/wmake  yes  yes  yes
-------------------------------------------------------------------------------


Checking the OpenFOAM env variables set on the LD_LIBRARY_PATH...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid Path Crit
-------------------------------------------------------------------------------
$FOAM_LIBBIN         ...OAM/OpenFOAM-1.6.x/lib/linuxGccDPOpt  yes  yes  yes
$FOAM_SITE_LIBBIN    ...penFOAM/site/1.6.x/lib/linuxGccDPOpt  no        no
$FOAM_USER_LIBBIN    ...penFOAM/greg-1.6.x/lib/linuxGccDPOpt  no        no
$MPI_ARCH_PATH       ...penmpi-1.3.3/platforms/linuxGccDPOpt  yes  yes  yes
-------------------------------------------------------------------------------


Third party software
-------------------------------------------------------------------------------
Software Version   Location 
-------------------------------------------------------------------------------
gcc      4.3.3     ...OAM/ThirdParty-1.6.x/gcc-4.3.3/platforms/linux/bin/gcc
gzip     1.3.12    /bin/gzip                                                
tar      1.19      /bin/tar                                                 
icoFoam  1.6.x     .../OpenFOAM-1.6.x/applications/bin/linuxGccDPOpt/icoFoam
-------------------------------------------------------------------------------


Summary
-------------------------------------------------------------------------------
Base configuration ok.

Critical systems ok.


done.
And the output of the echo:
Code:
greg@greg-laptop:~$ echo $FOAM_APPBIN
/home/greg/OpenFOAM/OpenFOAM-1.6.x/applications/bin/linuxGccDPOpt
gfilip is offline   Reply With Quote

Old   September 23, 2009, 18:10
Default
  #23
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
Ok, so the paths and environment variables seem ok, but the binary is missing. I think something must have gone wrong during compiling. Go to /home/greg/OpenFOAM/OpenFOAM-1.6.x/applications/ and execute ./Allwmake. If that doesn't give any errors the binary should be there afterwards.

I'm using OF-1.5 but this should be the same for 1.6.x.
akidess is offline   Reply With Quote

Old   September 23, 2009, 18:46
Default
  #24
Member
 
Join Date: May 2009
Posts: 54
Rep Power: 17
gfilip is on a distinguished road
That managed to fix it. Thank you very much.

-Greg
gfilip is offline   Reply With Quote

Old   September 24, 2009, 02:55
Default
  #25
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 177
Rep Power: 18
MadsR is on a distinguished road
Great it worked out :-)

I guess I'll put such hints into the header of the script.

/Mads
__________________
Online free airfoil-mesher for OpenFOAM here
MadsR is offline   Reply With Quote

Old   September 24, 2009, 14:28
Default
  #26
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
Oh by the way Mads, I just noticed you should make the script exit if an error occurs at any point; e.g. compiling doesn't make sense if the script bails at the git checkout for some reason.
akidess is offline   Reply With Quote

Old   September 30, 2009, 06:14
Default
  #27
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 177
Rep Power: 18
MadsR is on a distinguished road
That's a great idea. Any hints as to how to do that :-)

/Mads
__________________
Online free airfoil-mesher for OpenFOAM here
MadsR is offline   Reply With Quote

Old   September 30, 2009, 14:49
Default
  #28
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
set -e is probably the most straightforward way to make bash exit on errors. Just include that somewhere at the top of the script.
akidess is offline   Reply With Quote

Old   October 1, 2009, 01:38
Default
  #29
Senior Member
 
Phoevos
Join Date: Mar 2009
Posts: 104
Rep Power: 17
fivos is on a distinguished road
Hi,

I have tried your script for the OpenFoam v1.6.x installation. In the end when the foamInstallationTest runs I get the following results:
Code:
Executing /home/fivos/OpenFOAM/OpenFOAM-1.6.x/bin/foamInstallationTest:
 
 
Checking basic setup...
-------------------------------------------------------------------------------
Shell:              bash
Host:               fivos-desktop
OS:                 Linux version 2.6.27-14-generic
-------------------------------------------------------------------------------
 
 
Checking main OpenFOAM env variables...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid      Crit
-------------------------------------------------------------------------------
$WM_PROJECT_INST_DIR /home/fivos/OpenFOAM                     yes       yes
$WM_PROJECT_USER_DIR /home/fivos/OpenFOAM/fivos-1.6.x         no        no
$WM_THIRD_PARTY_DIR  /home/fivos/OpenFOAM/ThirdParty-1.6.x    yes       yes
-------------------------------------------------------------------------------
 
 
Checking the OpenFOAM env variables set on the PATH...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid Path Crit
-------------------------------------------------------------------------------
$WM_PROJECT_DIR      /home/fivos/OpenFOAM/OpenFOAM-1.6.x      yes  yes  yes
 
$FOAM_APPBIN         ...6.x/applications/bin/linux64GccDPOpt  yes  yes  yes
$FOAM_SITE_APPBIN    ...nFOAM/site/1.6.x/bin/linux64GccDPOpt  no        no
$FOAM_USER_APPBIN    ...6.x/applications/bin/linux64GccDPOpt  no        no
$WM_DIR              .../fivos/OpenFOAM/OpenFOAM-1.6.x/wmake  yes  yes  yes
-------------------------------------------------------------------------------
 
 
Checking the OpenFOAM env variables set on the LD_LIBRARY_PATH...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid Path Crit
-------------------------------------------------------------------------------
$FOAM_LIBBIN         ...M/OpenFOAM-1.6.x/lib/linux64GccDPOpt  yes  yes  yes
$FOAM_SITE_LIBBIN    ...nFOAM/site/1.6.x/lib/linux64GccDPOpt  no        no
$FOAM_USER_LIBBIN    ...FOAM/fivos-1.6.x/lib/linux64GccDPOpt  no        no
$MPI_ARCH_PATH       ...nmpi-1.3.3/platforms/linux64GccDPOpt  yes  yes  yes
-------------------------------------------------------------------------------
 
 
Third party software
-------------------------------------------------------------------------------
Software Version   Location 
-------------------------------------------------------------------------------
gcc      4.3.3     ...M/ThirdParty-1.6.x/gcc-4.3.3/platforms/linux64/bin/gcc
gzip     1.3.12    /bin/gzip                                                
tar      1.20      /bin/tar                                                 
icoFoam  1.6.x     ...penFOAM-1.6.x/applications/bin/linux64GccDPOpt/icoFoam
-------------------------------------------------------------------------------
 
 
Summary
-------------------------------------------------------------------------------
Base configuration ok.
 
Critical systems ok.
 
 
done.
The result of $FOAM_APPBIN is :

Code:
fivos@fivos-desktop:~/OpenFOAM/OpenFOAM-1.6.x$ echo $FOAM_APPBIN
/home/fivos/OpenFOAM/OpenFOAM-1.6.x/applications/bin/linux64GccDPOpt
When I rerun the ./Allwmake, as akidess said, I get many

make[1]: Leaving directory `/home/fivos/OpenFOAM/OpenFOAM-1.6.x/applications/........'
And in the end :
make: Target `application' not remade because of errors.
(Also in the make.log there is the same thing)

However when I give the blockMesh, or checkMesh, icoFoam commands for example they are recognised.

So the questions are :
- Why do I get these 'no' at the foamInstallationTest, are these normal?
- Why there are errors during make in the applications folder?


Any help is appreciated.

PS : I forgot to mention I am using the 64 - bit script since I am using Ubuntu 8.10 64 bit.

Last edited by fivos; October 1, 2009 at 05:03.
fivos is offline   Reply With Quote

Old   October 1, 2009, 19:46
Default
  #30
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Germany
Posts: 1,377
Rep Power: 30
akidess will become famous soon enough
Phoevos, my reply with ./Allwmake was very specific to gfilip's problem. Are you having the same problem? Why are you trying to recompile the applications directory? Nobody will be able to tell you why you are getting errors making the applications directory without knowing the errors (to my knowledge there are no psychics on the forum :P).

What makes you think your OpenFOAM installation isn't functional?
akidess is offline   Reply With Quote

Old   October 2, 2009, 02:47
Default
  #31
Senior Member
 
Phoevos
Join Date: Mar 2009
Posts: 104
Rep Power: 17
fivos is on a distinguished road
As far as I have tested OpenFOAM seems to work.

But why are these no's from the foamInstallationTest, is this normal?

As regards for the error during (re)build, I dont know why it was caused and I dont have any clue of what exactly is happening - I get this line (make: Target `application' not remade because of errors) at the end of the make.log after building all files, without any information about what these errors might be, or any more clues.

I have not been able to test OpenFOAM extensively, to make sure if it works or not. All commands, that I have tested till now work, so maybe there isnt any problem in the installation at all and these errors might be trivial for OpenFOAM's operation.

I apologise if my first message was vague, I believe that now I have made clear what bothers me.

Last edited by fivos; October 2, 2009 at 06:33.
fivos is offline   Reply With Quote

Old   October 3, 2009, 07:06
Default
  #32
Senior Member
 
Phoevos
Join Date: Mar 2009
Posts: 104
Rep Power: 17
fivos is on a distinguished road
After using OpenFOAM a bit, I believe that it is working normally. So ignore my previous messages.

Anyway thank you Madsr for your nice script!
fivos is offline   Reply With Quote

Old   October 6, 2009, 21:17
Default hi
  #33
Member
 
sarangarajan
Join Date: Sep 2009
Posts: 31
Rep Power: 17
sarajags_89 is on a distinguished road
~/OpenFOAM/OpenFOAM-1.6.x$ ./Allwmake >make.log 2>&1 I am getting stuck at this point.. does it take a long time for this step to complete?..thanks in advance.it is in the same step for more than 20 mins. is it normal? or shall I close it

Last edited by sarajags_89; October 6, 2009 at 21:35.
sarajags_89 is offline   Reply With Quote

Old   October 7, 2009, 02:14
Default
  #34
New Member
 
Dalibor
Join Date: Mar 2009
Location: Sweden
Posts: 8
Rep Power: 17
dado is on a distinguished road
Quote:
Originally Posted by sarajags_89 View Post
~/OpenFOAM/OpenFOAM-1.6.x$ ./Allwmake >make.log 2>&1 I am getting stuck at this point.. does it take a long time for this step to complete?..thanks in advance.it is in the same step for more than 20 mins. is it normal? or shall I close it
It took more than 3 h on my computer to compile everything
dado is offline   Reply With Quote

Old   October 7, 2009, 15:23
Default
  #35
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 177
Rep Power: 18
MadsR is on a distinguished road
yeah, it can take 5-8 hours on a slow computer...
__________________
Online free airfoil-mesher for OpenFOAM here
MadsR is offline   Reply With Quote

Old   October 7, 2009, 18:49
Default
  #36
Member
 
sarangarajan
Join Date: Sep 2009
Posts: 31
Rep Power: 17
sarajags_89 is on a distinguished road
hi it took 3hrs .. When I start paraview from the cavity case file I get the following msg " A reader for cavity.Openfoam could not be found" please select one of the following.
1.protein data bank files
plot 3d files
digital elevation map files
stereo lithography
gaussian cube files
raw(binary files)
pop ocean files
AVS UCD binary /ASCII files
SESAME
comma -separated grid files
MFIX unstructured grid files
fluent case files
openfoam files
cosmology files

Which one do i select
!!!
thanks in adv

cheers

sarang
sarajags_89 is offline   Reply With Quote

Old   October 8, 2009, 03:58
Default
  #37
New Member
 
bigred's Avatar
 
Matthew Philpott
Join Date: Aug 2009
Location: Belgium
Posts: 24
Rep Power: 17
bigred is on a distinguished road
Quote:
Originally Posted by sarajags_89 View Post
hi it took 3hrs .. When I start paraview from the cavity case file I get the following msg " A reader for cavity.Openfoam could not be found" please select one of the following.
1.protein data bank files
plot 3d files
digital elevation map files
stereo lithography
gaussian cube files
raw(binary files)
pop ocean files
AVS UCD binary /ASCII files
SESAME
comma -separated grid files
MFIX unstructured grid files
fluent case files
openfoam files
cosmology files

Which one do i select
!!!
thanks in adv

cheers

sarang
That would be my guess (the one in bold)
__________________
CAELinux 2009 + OF1.5
Ubuntu 9.04 x64 (jaunty jackalope) + OF1.6
bigred is offline   Reply With Quote

Old   October 8, 2009, 05:06
Default
  #38
New Member
 
Join Date: Mar 2009
Posts: 27
Rep Power: 17
jugghead is on a distinguished road
Thanks for the script!
jugghead is offline   Reply With Quote

Old   October 8, 2009, 09:10
Default
  #39
Member
 
Join Date: May 2009
Posts: 54
Rep Power: 17
gfilip is on a distinguished road
Quote:
Originally Posted by sarajags_89 View Post
hi it took 3hrs .. When I start paraview from the cavity case file I get the following msg " A reader for cavity.Openfoam could not be found" please select one of the following.
1.protein data bank files
plot 3d files
digital elevation map files
stereo lithography
gaussian cube files
raw(binary files)
pop ocean files
AVS UCD binary /ASCII files
SESAME
comma -separated grid files
MFIX unstructured grid files
fluent case files
openfoam files
cosmology files

Which one do i select
!!!
thanks in adv

cheers

sarang

Hi Sarang,

I had the same issue. All you have to do is compile the PV3 OF file reader (even though it is showing up on the list) through:

Code:
cd $FOAM_UTILITIES/postProcessing/graphics/PV3FoamReader
    ./Allwclean
    ./Allwmake

Hope it helps.

-Greg
gfilip is offline   Reply With Quote

Old   October 8, 2009, 09:17
Default
  #40
New Member
 
M. Li
Join Date: Apr 2009
Posts: 13
Rep Power: 17
cnlimin is on a distinguished road
Quote:
Originally Posted by MadsR View Post
Hi there.

I am not sure if this helps anyone, but for what it's worth, I thought I'd share how I install OpenFOAM on a fresh Ubuntu 9.04 system in a somewhat fool-proof way...By installing I mean real install with compiling, not "only" downloading of binaries.

I have previously spent quite some time, installing OpenFOAM, so I was trying to simplify and organise the process. I like to bake cakes, so I'll put it in a cookbook way if that's okay with you.

1. you need to have a Ubuntu 9.04 system running (or a similar apt-get enabled distro)
2. you need to be logged in as the user you want to be using OF as (not just using su)
3. you need to be allowed to run the sudo command
4. download my install-script found here
5. read through the script and see if you find anything upsetting (please notify me if you do)
6. either - for the not so faint-hearted - run the script "automatically" by typing . ./installOF OR manually copy-paste each line from the script to your command-line and execute, a bit safer, the installation process step-wise
7. you could bake a cake now, as step 6 probably will take a really long time
8. enjoy OpenFOAM, a cup of coffee and your cake
9. if everything above worked out, you can actually maintain your OpenFOAM install by typing git pull in the OpenFOAM-1.6.x-directory followed by ./Allwmake

The script is "verision 1.0" - please use this at your own risk and don't hold anything against me if your summer-vacation pictures are deleted (actually if this happens I really wonder how my script could have caused that )

Let me know if this is useless, or if it helps you out.

Cheers,
Mads
First, thank you very much for providing this script and I'm executed it on ubuntu 9.04 (32bit).
The installation of OpenFOAM1.6 is successful.
Thank you again!

Last edited by cnlimin; October 9, 2009 at 09:01.
cnlimin is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
install OpenFoam 1.6 by building source: how? niudie OpenFOAM Installation 13 April 26, 2011 01:48
How to Install OpenFOAM on 64 Ubuntu 9.04 hansel OpenFOAM Installation 62 March 19, 2010 15:43
install openfoam 1.6 on opensuse 11.0 andresbh OpenFOAM Installation 8 September 30, 2009 01:48
Install openFOAM 1.6 on debian 32bit - blockMesh: command not found fossy OpenFOAM Installation 1 August 28, 2009 05:06
Install of OpenFOAM 1.6 Error 1 Error 2 & run tutorial potac OpenFOAM Installation 3 August 27, 2009 10:04


All times are GMT -4. The time now is 10:45.