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

Installation of OpenFOAM-2.1.0 on ubuntu 11.10 system

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

Reply
 
LinkBack Thread Tools Display Modes
Old   January 7, 2012, 02:55
Default Installation of OpenFOAM-2.1.0 on ubuntu 11.10 system
  #1
Member
 
Elh. A2. BAH
Join Date: Jan 2012
Posts: 64
Rep Power: 6
ebah6 is on a distinguished road
Hello everybody,

I am trying to get started with OpenFOAM on my ubuntu 11.10 but I run into difficulty very soon.
Following the instructions from: http://www.openfoam.org/download/source.php,
When I source the ~/.bashrc file, I get the following error messages:
================================
alpha@alpha-Lenovo-G455:~/OpenFOAM/OpenFOAM-2.1.0/etc$ source ~/.bashrc
bash: /opt/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
bash: /opt/OpenFOAM-2.1.0/etc/config/settings.sh: No such file or directory
bash: /opt/OpenFOAM-2.1.0/etc/config/aliases.sh: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
bash: /opt/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
================================================== =============
I do not why it is pointing to the /opt/... directory.
I checked the bashrc in the OpenFOAM/OpenFOAM-2.1.0/etc/bashrc and I could read the following:
--------------------------------------------------
# Location of the OpenFOAM installation
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
foamInstall=$HOME/$WM_PROJECT
# foamInstall=~$WM_PROJECT
# foamInstall=/opt/$WM_PROJECT
# foamInstall=/usr/local/$WM_PROJECT
#
# END OF (NORMAL) USER EDITABLE PART
#############
and few lines down in the same file I have:
# Source project setup files
# ~~~~~~~~~~~~~~~~~~~~~~~~~~
_foamSource $WM_PROJECT_DIR/etc/config/settings.sh
_foamSource $WM_PROJECT_DIR/etc/config/aliases.sh
-----------------------------------------------------------------

To the best of my understanding all the references to "/opt/..." are comment by the "#".

Can someone out there help see clear in this installation?

Thank you very much in advance.

alpha.
ebah6 is offline   Reply With Quote

Old   January 7, 2012, 05:09
Default
  #2
Member
 
Andy Jones
Join Date: Sep 2010
Location: Columbus, Ohio
Posts: 78
Rep Power: 7
andyj is on a distinguished road
I installed 2.1.0 on Ubuntu 11.10 using the packages for Ubuntu. No problems.

Look very carefully at your path
If your user name is alpha, the path would be /home/OpenFOAM/alpha-2.1.0
Also note the Capital Letters FOAM in OpenFoam.
http://linuxcommand.org/learning_the_shell.php
andyj is offline   Reply With Quote

Old   January 7, 2012, 05:17
Default
  #3
Member
 
Andy Jones
Join Date: Sep 2010
Location: Columbus, Ohio
Posts: 78
Rep Power: 7
andyj is on a distinguished road
When your source the bash in the text editor you have to click " save " in the menu bar of the text editor to save it in the bashrc
Then close the text editor.
Reopen the bashrc and see if you saved it before you closed it.
I think its the last line in bashrc according to the directions
andyj is offline   Reply With Quote

Old   January 7, 2012, 05:51
Default
  #4
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 9,531
Blog Entries: 36
Rep Power: 97
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings to all!

I believe the problem here is that a previous OpenFOAM installation is contaminating the shell environment.

Edit the file "$HOME/.bashrc" and remove any references to other OpenFOAM versions that aren't needed. Start a new terminal and you should no longer have that error.

In case you do need more than one version of OpenFOAM, then see this post: paraview compilation error paraview-3.12.0 post #18.

Best regards,
Bruno
__________________
___
I'll be at OFW11 in Portugal
wyldckat is offline   Reply With Quote

Old   January 7, 2012, 05:58
Default
  #5
Member
 
Andy Jones
Join Date: Sep 2010
Location: Columbus, Ohio
Posts: 78
Rep Power: 7
andyj is on a distinguished road
If all else fails install with the Ubuntu Deb Packs

http://www.openfoam.org/download/ubuntu.php
Installing from source is harder.
I am no expert on installs.
close and reopen your command terminal and see if that helps
type pwd to see what directory your terminal is currently in
Opt is a default install location.
Anything different in the Openfoam instructions command prompt in the directions from your command prompt?
Watch out for capital letters, spaces and punctuation at the command prompt
also the " / " may not be necessary when using cd command
thats all I can think of..hope it helps
andyj is offline   Reply With Quote

Old   January 7, 2012, 05:59
Default
  #6
Member
 
Elh. A2. BAH
Join Date: Jan 2012
Posts: 64
Rep Power: 6
ebah6 is on a distinguished road
Thanks Andy,

Before I saw your reply, I tried setting the environment by doing the following:
----------------------------
export FOAM_INST_DIR=OpenFOAM
foamDotFile=$FOAM_INST_DIR/OpenFOAM-2.1.0/etc/bashrc
[ -f $foamDotFile ] && . $foamDotFile
------------------------
After this I was able to source the ~/.bashrc file.

However when I run ./Allwmake, it runs untill some point and the laptop just goes off even though it doesn't seem to over heat.

In your answer, you talk about the ubuntu pack, if I understand properly you are following the instructions from this link: http://www.openfoam.org/download/ubuntu.php.
I did that early and the installation went find and by default I think the package is installed in /opt repository.
Then when I try to reproduce some of the user guide I run into trouble when doing the following:
------------
cd $FOAM_SOLVERS/incompressible/pisoFoam
wmake
-------------
with this I got some permission errors.
I tried with the su root command. But still the wmake didn't complete.

So few questions:
- can you copy past the link you followed so I can sure which one is being talked about?
- also when you suggest the path: /home/OpenFOAM/alpha-2.1.0, at what do I need to consider this one?

Thank you for your time.
ebah6 is offline   Reply With Quote

Old   January 7, 2012, 06:34
Default
  #7
Member
 
Andy Jones
Join Date: Sep 2010
Location: Columbus, Ohio
Posts: 78
Rep Power: 7
andyj is on a distinguished road
I had trouble with allmake installiing on Suse 12.1 with 2.1.0.
The part where you use your user name (alpha-2.1.0) is when you set up the tutorials in the user guide to run them..ie..incompressible/icoFoam/lid cavity example. Otherwise, the tutorials wont work.
There are a bunch of components to the wmake package. Do you have all the parts of wmake installed?
Directions are different for the source code vs Ubuntu Deb Packages
The Unity desktop is new in 11.10 It is a replacement for the Genome desktop. It may still have a few bugs..maybe not. Might want to update your Ubuntu with the system needed components that look like they are system only updates.
Closing and reopening the terminal seemed to help. Its also possible the source code has the newer kernel 3.2 in it, while 11.10 is kernel 3.0
http://openfoamwiki.net/index.php/Compiling/Building (wmake tips-usage)
http://www.tfd.chalmers.se/~hani/kur...OwnLaptop.html (these guys are pros!)
I can't remember, but I think allmake might need to be told to look inside of folders
andyj is offline   Reply With Quote

Old   January 7, 2012, 06:54
Default
  #8
Member
 
Andy Jones
Join Date: Sep 2010
Location: Columbus, Ohio
Posts: 78
Rep Power: 7
andyj is on a distinguished road
I also had trouble with the terminal using workspace switcher. I think its only intended for pdf files and webpages,..not operating system commands between workspaces.
My terminal had a problem with a correctly placed " / " at the very beginning of a command. I omitted it and was able to issue commands.
Be sure and update your video driver to the newest linux version for ati or nvida.
Is it ./Allmake or /.Allmake or ./allmake or ./allmake? The help for allmake would say the correct usage. Or the man pages for wmake.
andyj is offline   Reply With Quote

Old   January 7, 2012, 07:02
Default
  #9
Member
 
Andy Jones
Join Date: Sep 2010
Location: Columbus, Ohio
Posts: 78
Rep Power: 7
andyj is on a distinguished road
http://www.openfoam.org/download/ubuntu.php
the lines following are:
Ubuntu Deb Pack Installation

Version 2.1.0, released 19/12/11

Ubuntu Versions

OpenFOAM and Paraview are currently available for the following versions of Ubuntu:
  • 10.04 LTS, codename lucid
  • 11.04, codename natty
  • 11.10, codename oneiric

Installation

OpenFOAM and Paraview can be simply installed using the apt package management tool. The user will need to provide superuser password authentication when executing the following commands with sudo
  1. In a terminal window, add OpenFOAM to the list of repository locations for apt to search, by copying and pasting the following in a terminal prompt (Applications -> Accessories -> Terminal).
andyj is offline   Reply With Quote

Old   January 8, 2012, 21:51
Default
  #10
Member
 
Elh. A2. BAH
Join Date: Jan 2012
Posts: 64
Rep Power: 6
ebah6 is on a distinguished road
Thank you all.

The links were very useful.
ebah6 is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
OpenFOAM 1.7 installation on Redhat linux maxims OpenFOAM Installation 2 November 30, 2012 05:29
openfoam installation for algeria (dz) abbes OpenFOAM Installation 4 July 18, 2011 19:16
CFX11 + Fortran compiler ? Mohan CFX 20 March 30, 2011 18:56
Installing OpenFOAM 1.6 on Ubuntu 10.4 sda OpenFOAM Installation 5 May 27, 2010 20:19
OpenFOAM 1.6 installation in Ubuntu 9.1 jsm OpenFOAM Installation 4 January 3, 2010 23:53


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