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

OpenFOAM-1.6 install cookbook

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

Like Tree1Likes

Reply
 
LinkBack Thread Tools Display Modes
Old   December 4, 2009, 12:04
Default compiling
  #161
Senior Member
 
Join Date: Dec 2009
Posts: 112
Rep Power: 7
heavy_user is on a distinguished road
Solved the prob....nvm!

Last edited by heavy_user; December 7, 2009 at 10:18. Reason: nvm!
heavy_user is offline   Reply With Quote

Old   December 4, 2009, 12:35
Default
  #162
New Member
 
Join Date: Jul 2009
Posts: 10
Rep Power: 7
Future Science is on a distinguished road
Quote:
Originally Posted by MadsR View Post
Hi Future Science.

Are you sure that Allwmake compiles without errors?

It's really wierd. As I recall, what I did was to 1) get a new computer, 2) install Ubuntu 9.10 64-bit version and then 3) install OpenFOAM with my script. As it didn't work out entirely, I applied the links that Bruno pointed out above - and now it's working. I know this helps you like a spoon when you need a fork (meaning it's not helpful to you :-/ ). The more statements of "this is working" we get though, should prove that the script is working. We have a lot of such validation of the first-gen scripts (for 8.04) but not so much for 9.10. So it might be my installation that's broke (and hence works).

Maybe other foamers could confirm installation (or give errors) with the script on 9.10-64?

Apparently installation of OpenFOAM under Linux is quite a fragile process, and small changes can have catastrophic consequences. In your case, we still have to find out what's wrong (and change the script accordingly).

I am not aware of that "comiplerInstall = System." you are talking about? Are you trying to use the system compiler instead of the one bundled with Ubuntu - if so, why?

/Mads
Hi Mads,
sorry for not being so clear early, since I forgot to mention that at the end of the ./Allwmake I receive many (I suppose) errors around here and there.

I wanted to use the System version since it is the latest one, instead of the 4.3.x in the ThirdParty folder. Also because the first time that I've tried to install it, I got a message saying to set "System" as the compiler in the settings file. Is it better to use the System version or it makes no difference?
Future Science is offline   Reply With Quote

Old   December 5, 2009, 05:28
Default
  #163
Senior Member
 
Ahmed
Join Date: Mar 2009
Location: NY
Posts: 248
Rep Power: 9
Ahmed is on a distinguished road
Quote:
Originally Posted by MadsR View Post
Hi Ahmed.

Nice - please post the modifications needed.

If ./Allwmake >make.log 2>&1 results in a disaster on an OpenSuse system it makes good reason for changing to Ubuntu :-) it's a completely valid Linux statement so I am a bit puzzled about any problems.

What it does is to redirect the "standard output" and "standard error"-streams to the make.log file. Google is your friend here.

@Alessandro is it really needed to uninstall gcc? Seems drastic.

/Mads
So far, I have decided to write two scripts, one for Downloading/Updating and the second for installing, the first one is ready and I have tested it on my OpenSUSE 11.2
Here it is

#!/bin/bash
echo
echo
echo "Hello "$USER
echo
echo "Your current directory is:- "$PWD
echo
if test -e OpenFOAM
then
echo
echo "There is an old OpenFOAM folder, Updating source files"
echo
cd OpenFOAM
cd OpenFOAM-1.6.x
git pull
else
echo "No OpenFOAM folder found"
echo
#
# Create a new Folder OpenFOAM
# DownLoad the latest snapshot from the git repository
#
echo
echo "Creating a new OpenFOAM folder"
mkdir $HOME/OpenFOAM
cd OpenFOAM
echo
echo "Starting to DownLoad OpenFOAM-1.6.x"
echo
git clone git://repo.or.cz/OpenFOAM-1.6.x.git
echo
echo "DownLoading ThirdParty Files for 64 bits installation"
echo
wget http://sourceforge.net/projects/foam....gtgz/download
wget http://sourceforge.net/projects/foam....gtgz/download
echo
echo "Unpacking Third Party Ffiles"
echo
tar xvzf ThirdParty-1.6.General.gtgz
tar xvzf ThirdParty-1.6.linux64Gcc.gtgz
mv ThirdParty-1.6 ThirdParty-1.6.x
echo
cd ..
echo "You need to add the following statement to your .bashrc file"
echo "source $HOME/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc"
echo
emacs .bashrc
echo "Now you have modified your .bashrc file, Do the following"
echo "1- Close this terminal window, then start a new one"
echo "2- Run The InstallOpenFOAM.sh script"
echo
echo " That is all for now folks.........."

fi

Please Note the following
1- The third party files downloaded by this script are for 64 Bits installation, If you have a 32 Bits installation, just change the names of the downloaded files in the wget statements.

2- This script, hopefully, is independent of the Distro you are using.

I hope it is useful for others
Thanks and good luck to all


................................ Open Source for ever ................................
Ahmed is offline   Reply With Quote

Old   December 6, 2009, 12:37
Default
  #164
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Delft, Netherlands
Posts: 919
Rep Power: 17
akidess will become famous soon enough
Hey Ahmed,

Your script downloads the OpenFOAM source code, but never compiles it. And I think instead of launching emacs, you should add the line to .bashrc automatically, just like Mads did.

Also, please use the [code] tag when posting stuff like shell scripts, it will make your post more readable.

- Anton
akidess is offline   Reply With Quote

Old   December 7, 2009, 02:31
Default
  #165
New Member
 
sachin
Join Date: Dec 2009
Posts: 3
Rep Power: 7
sachin.pagnis is on a distinguished road
Hi Mads its really useful, and helped me to great extend as I am new to Linux, as suggested I used UBUNTU 9.04.

All the steps given in the cok book are throug but I stuck up when I started tutorials from the user guide, I started with;
mkdir -p $FOAM RUN

This made the directory at the root/home/openfoam

cp -r $FOAM TUTORIALS $FOAM RUN

but this is giving me error and I couldnt proceed further.


Please let me know where/what I should check

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
sachin.pagnis is offline   Reply With Quote

Old   December 7, 2009, 03:46
Default
  #166
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 175
Rep Power: 8
MadsR is on a distinguished road
@sachin: I never use these variables for directory names, but maybe you need an underscore in: $FOAM_TUTORIALS ?

@future science: I'd go for the compiler provided with OpenFOAM as I doubt you will find any difference - and it works (which is a good argument :-) )

@ahmed: nice, but I agree with Anton, you might want to add the last few details.

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

Old   December 7, 2009, 04:04
Default
  #167
New Member
 
sachin
Join Date: Dec 2009
Posts: 3
Rep Power: 7
sachin.pagnis is on a distinguished road
Sorry its typo, the underscore is there, I again tried with command I mentioned and I found the issue with copy 'cp' command.

But anyways; as you mentioned if you are not using the commands which OF suggests to run the tutorial, then what you would use to initiate the tutorials, if tutorial folder is placed in OpenFOAM generic file structure?
sachin.pagnis is offline   Reply With Quote

Old   December 8, 2009, 03:06
Default
  #168
New Member
 
Pradeep
Join Date: Dec 2009
Posts: 4
Rep Power: 7
pradeepmohanm is on a distinguished road
Dear Mads,
I am a linux newbie. I have tried your script on a new kubuntu 9.1 installation. But I am agetting the the following error.

Quote:
-----------------------------------------------------
64 BIT VERSION
64 BIT VERSION
64 BIT VERSION
-----------------------------------------------------
Making sure that you have all needed libraries
-----------------------------------------------------
Apparently we need to run apt-get multiple times to
be SURE that everything is installed
sudo: timestamp too far in the future: Dec 8 11:56:22 2009
[sudo] password for pradeep:
Reading package lists... Done
Building dependency tree
Reading state information... Done
flex is already the newest version.
Note, selecting gnuit instead of git
gnuit is already the newest version.
git-core is already the newest version.
build-essential is already the newest version.
python-dev is already the newest version.
libqt4-dev is already the newest version.
libreadline5-dev is already the newest version.
wget is already the newest version.
zlib1g-dev is already the newest version.
cmake is already the newest version.
The following packages were automatically installed and are no longer required:
linux-headers-2.6.31-14 linux-headers-2.6.31-14-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
flex is already the newest version.
Note, selecting gnuit instead of git
gnuit is already the newest version.
git-core is already the newest version.
build-essential is already the newest version.
python-dev is already the newest version.
libqt4-dev is already the newest version.
libreadline5-dev is already the newest version.
wget is already the newest version.
zlib1g-dev is already the newest version.
cmake is already the newest version.
The following packages were automatically installed and are no longer required:
linux-headers-2.6.31-14 linux-headers-2.6.31-14-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
flex is already the newest version.
Note, selecting gnuit instead of git
gnuit is already the newest version.
git-core is already the newest version.
build-essential is already the newest version.
python-dev is already the newest version.
libqt4-dev is already the newest version.
libreadline5-dev is already the newest version.
wget is already the newest version.
zlib1g-dev is already the newest version.
cmake is already the newest version.
The following packages were automatically installed and are no longer required:
linux-headers-2.6.31-14 linux-headers-2.6.31-14-generic
Use 'apt-get autoremove' to remove them.
0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded.
------------------------------------------------------
Downloading ThirdParty stuff
------------------------------------------------------
--2009-12-08 01:28:00-- http://downloads.sourceforge.net/foa...se_mirror=mesh
Resolving downloads.sourceforge.net... 216.34.181.59
Connecting to downloads.sourceforge.net|216.34.181.59|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: http://mesh.dl.sourceforge.net/proje...6.General.gtgz [following]
--2009-12-08 01:28:01-- http://mesh.dl.sourceforge.net/proje...6.General.gtgz
Resolving mesh.dl.sourceforge.net... 213.203.218.122
Connecting to mesh.dl.sourceforge.net|213.203.218.122|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 133110883 (127M) [application/octet-stream]
Saving to: `ThirdParty-1.6.General.gtgz'

100%[================================================== ================================================== ======================================>] 133,110,883 144K/s in 11m 50s

2009-12-08 01:39:52 (183 KB/s) - `ThirdParty-1.6.General.gtgz' saved [133110883/133110883]

--2009-12-08 01:39:52-- http://downloads.sourceforge.net/foa...se_mirror=mesh
Resolving downloads.sourceforge.net... 216.34.181.59
Connecting to downloads.sourceforge.net|216.34.181.59|:80... connected.
HTTP request sent, awaiting response... 302 Found
Location: http://mesh.dl.sourceforge.net/proje...inux64Gcc.gtgz [following]
--2009-12-08 01:39:53-- http://mesh.dl.sourceforge.net/proje...inux64Gcc.gtgz
Resolving mesh.dl.sourceforge.net... 213.203.218.122
Connecting to mesh.dl.sourceforge.net|213.203.218.122|:80... connected.
HTTP request sent, awaiting response... 200 OK
Length: 136838654 (130M) [application/octet-stream]
Saving to: `ThirdParty-1.6.linux64Gcc.gtgz'

100%[================================================== ================================================== ======================================>] 136,838,654 212K/s in 11m 24s

2009-12-08 01:51:18 (195 KB/s) - `ThirdParty-1.6.linux64Gcc.gtgz' saved [136838654/136838654]

------------------------------------------------------
Untarring - this takes a while...
------------------------------------------------------
FIX up for Ubuntu 9.10
Fix up done
------------------------------------------------------
Retrieveing OpenFOAM...
------------------------------------------------------
Initialized empty Git repository in /home/pradeep/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux64/lib64/OpenFOAM-1.6.x/.git/
remote: Counting objects: 13388, done.
remote: Compressing objects: 100% (6217/6217), done.
remote: Total 13388 (delta 7000), reused 13160 (delta 6867)
Receiving objects: 100% (13388/13388), 34.18 MiB | 205 KiB/s, done.
Resolving deltas: 100% (7000/7000), done.
./installOF64-9.10: line 53: /home/pradeep/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc: No such file or directory
I had run the script once initially - updated the programs and then had the same error. tried it again and hence its showing that all packages are updated. Thanks in advance

One more thing in the OpenFOAM folder there are only the thridparty*.gtgz files and the thirdparty folder. There is no OpenFOAM-1.6.x folder
pradeepmohanm is offline   Reply With Quote

Old   December 8, 2009, 04:11
Default
  #169
New Member
 
Pradeep
Join Date: Dec 2009
Posts: 4
Rep Power: 7
pradeepmohanm is on a distinguished road
Hey Mads,

I think i solved the problem. I found that the git pull was happening to ~/OpenFOAM/ThirdP*/gcc*/platforms/linux64. The OpenFOAM1.6 folder was being created at this location. I actually cut out a part of your script and modified that and it is compiling now. This is the part that i used

Quote:
set -e
cd ~/OpenFOAM
git clone http://repo.or.cz/r/OpenFOAM-1.6.x.git
cd ~/OpenFOAM/OpenFOAM-1.6.x/
. ~/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc
echo . ~/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc >> ~/.bashrc
echo "------------------------------------------------------"
echo "Compiling OpenFOAM...output is in make.log"
echo " THIS CAN TAKE HOURS"
echo "------------------------------------------------------"
./Allwmake >make.log 2>&1
echo "------------------------------------------------------"
echo "Checking installation - you should see NO criticals..."
echo "------------------------------------------------------"
foamInstallationTest
set +e
Did the earlier problem happen because of something i did? I made a cd to ~/OpeFOAM directory and then also changed the git pull command adding /r/ like allesandro. Dont know what i did. but hopefully this will work.

Thank you for the script
pradeepmohanm is offline   Reply With Quote

Old   December 8, 2009, 04:42
Default
  #170
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 175
Rep Power: 8
MadsR is on a distinguished road
@Pradeep: great it worked out :-)


Could someone please explain the '/r/'-difference when using git? What's that about?

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

Old   December 8, 2009, 15:33
Default
  #171
Member
 
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 7
Wolle is on a distinguished road
Hi all,

I'm totally new to CFD and OpenFOAM with a little of Linux experience and at the moment giving it a try...

First of all: I experienced the same problem as stated above by pradeepmohanm, resulting in several "file not found" issues. I think it's a matter of directory changing in the script. I tried it an my workstation today (at the moment at home) with a blank new Xubuntu 9.04 (also set up today). Cannot figure it out exactly... just arrived home.

But second and as to answer (or contribute to) your question related to the "/r" issue:

git clone git://repo.or.cz/OpenFOAM-1.6.x.git
git clone http://repo.or.cz/r/OpenFOAM-1.6.x.git

Have a closer look! The difference isn't just the "/r/", it's also "git://" or "html://". As for me (at work), I'm located behind a proxy server (as most users in business or educational networks will be) which redirects any http, https and ftp requests through http://servername:8080 (or the like)

As far, as I know git uses an own port (Wikipedia told me... ), which wont be forwarded by the most proxies. So a request via "git://...." wont be successful, while a "http://..." request should be redirected correctly.

At least that's what I suspect... maybe it's useful to you...

Cheers
Wolle
Wolle is offline   Reply With Quote

Old   December 9, 2009, 02:52
Default
  #172
Member
 
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 7
Wolle is on a distinguished road
Good morning all!

I just wanted to give some additional feedback.

1st: At home (without a proxy), the original script (using "git://..." path without /r/) for Ubuntu 9.04-64 worked out very well without any changes on a Ubuntu 8.04.3LTS-64, that has been a victim of different experiments concerning Linux... but anyway: It worked out without any problems.

2nd: At work, it didn't, as I just had to notice. As I'm behind a proxy, I changed things to "http://" and the path containing /r/. Pulling the sources worked out then.

Sadly, the terminal says the following:
Code:
Checking main OpenFOAM env variables...
-------------------------------------------------------------------------------
Environment_variable Set_to_file_or_directory                Valid      Crit
-------------------------------------------------------------------------------
$WM_PROJECT_INST_DIR /home/kretzschmar/OpenFOAM               yes       yes
$WM_PROJECT_USER_DIR ...etzschmar/OpenFOAM/kretzschmar-1.6.x  no        no
$WM_THIRD_PARTY_DIR  ...retzschmar/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      .../kretzschmar/OpenFOAM/OpenFOAM-1.6.x  yes  yes  yes

$FOAM_APPBIN         ...1.6.x/applications/bin/linuxGccDPOpt  no        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              ...schmar/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    .../kretzschmar-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.20      /bin/tar                                                 
icoFoam           
WARNING:  Conflicting installations:
          OpenFOAM settings        : /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/applications/bin/linuxGccDPOpt/icoFoam
          current path             : 
          CRITICAL ERROR

-------------------------------------------------------------------------------


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

The foam installation contains 1 critical error(s).

Review the output for warning messages and consult 
the installation guide for trouble shooting.
So, a closer look at the make.log (at home, it contained several warnings, but no errors, checked it quickly this morning) show this:
Code:
gcc -m32  -Wall -O3   -fPIC dirToString.c -o /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/wmake/bin/linuxGcc/dirToString
flex wmkdep.l
gcc -m32  -Wall -O3   -fPIC lex.yy.c -o /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/wmake/bin/linuxGcc/wmkdep
lex.yy.c:1393: warning: ‘yyunput’ defined but not used
lex.yy.c:1436: warning: ‘input’ defined but not used
wmkdep.l: In function ‘yy_scan_bytes’:
wmkdep.l:463: internal compiler error: Illegal instruction
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
make: *** [/home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/wmake/bin/linuxGcc/wmkdep] Fehler 1
+ [ -n  ]
+ [ -n  ]
+ [ -n  ]
+ [ -n  ]
+ [ -n  ]
+ cd malloc
+ ./Allwmake
+ wmake libso hoard
/bin/sh: /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/wmake/bin/linuxGcc/wmkdep: not found
'/home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/lib/linuxGccDPOpt/libhoard.so' is up to date.
+ wmake libo fbsdmalloc
/bin/sh: /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/wmake/bin/linuxGcc/wmkdep: not found
ld -melf_i386 -r -o /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/lib/linuxGccDPOpt/libfbsdmalloc.o Make/linuxGccDPOpt/fbsdmalloc.o
'/home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/lib/linuxGccDPOpt/libfbsdmalloc.o' is up to date.
+ [ -r /home/kretzschmar/OpenFOAM/ThirdParty-1.6.x/openmpi-1.3.3/platforms/linuxGccDPOpt/lib/libmpi.so ]
+ echo have OPENMPI shared library
have OPENMPI shared library
+ cd scotch_5.1
+ wmake libso src/libscotch
/bin/sh: /home/kretzschmar/OpenFOAM/OpenFOAM-1.6.x/wmake/bin/linuxGcc/wmkdep: not found
(The last line repeated several times during the whole log.)

System is a freshly set up (yesterday!) Xubuntu 9.04-32.

Any hints?

Ciao
Wolle

BTW:
Code:
kretzschmar@PCE29CK1-L:~$ gcc -dumpmachine
i686-pc-linux-gnu
kretzschmar@PCE29CK1-L:~$ gcc -dumpversion
4.3.3
So obviously the correct version of gcc should have been used, shouldn't it?
Wolle is offline   Reply With Quote

Old   December 9, 2009, 06:04
Default
  #173
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 175
Rep Power: 8
MadsR is on a distinguished road
Hi Wolle, thanks for the feedback and the enlightenment on git. I guess I should change the script to use the http-download instead, as it seem more robust.

If you have compiled and changed things back and forth, I can recommend to delete everything (rm -rf ~/OpenFOAM) and start all over again...

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

Old   December 9, 2009, 08:48
Default
  #174
Member
 
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 7
Wolle is on a distinguished road
Hi all,

I did as you told me and started all over again. Only modification was the git-source. Still no luck. The same compilation error occurs just from the start on.

By the way: it seems, that the problem is very close to the one described by Achim here:

http://www.cfd-online.com/Forums/ope...tml#post237867

And concerning the answer to Achims posting by akidess: I installed a brand new Xubuntu 9.04 yesterday and checked the RAM by the means of a complete Memtest86 run... no errors occured.

Cheers
Wolle
Wolle is offline   Reply With Quote

Old   December 10, 2009, 04:00
Default
  #175
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 175
Rep Power: 8
MadsR is on a distinguished road
Wolle, I don't know Xubuntu - is it completely the same as Ubuntu? Well obviously not completely :-) but are they virtually the same?
If possible, maybe you could try to use Ubuntu 9.10 just to check. I am really in favour of running a wide variety of distributions, but there might be an "issue" with Xubuntu. Seems that Achim had it work when he changed to Ubuntu?
__________________
Online free airfoil-mesher for OpenFOAM here
MadsR is offline   Reply With Quote

Old   December 10, 2009, 04:26
Default
  #176
Member
 
Wolfram Kretzschmar
Join Date: Dec 2009
Posts: 71
Rep Power: 7
Wolle is on a distinguished road
Hi Mads,

Yes, that might possibly be an option. I'm going to give it a try next week...

(Though Xubuntu should only be Ubuntu with Xfce instead of Gnome... To be honest: Xfce feels not that nice too...)

Cheers
Wolle
Wolle is offline   Reply With Quote

Old   December 10, 2009, 07:47
Default
  #177
Member
 
Cedric Van Holsbeke
Join Date: Dec 2009
Location: Belgium
Posts: 81
Rep Power: 7
CedricVH is on a distinguished road
Mads, I think I have found a little bug in your install-cookbook script. When I start the version for Ubuntu 9.10 64bit, it crashes at line 53 as the script can not find the folder OpenFOAM-1.6.x, even after a succesful git clone.

The reason is that the working directory is not correctly set. The script changes the working directory with the command cd ~/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux64/lib64 but does not go back to the ~/OpenFOAM folder. The solution is very simple: just add cd ~/OpenFOAM before the git command.

Code:
echo "FIX up for Ubuntu 9.10"
cd ~/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux64/lib64
mv libstdc++.so.6 libstdc++.so.6.orig
ln -s /usr/lib/libstdc++.so.6.0.10 libstdc++.so.6
mv libgcc_s.so.1 libgcc_s.so.1.orig
ln -s /lib/libgcc_s.so.1
echo "Fix up done"
echo "------------------------------------------------------"
echo "Retrieveing OpenFOAM..."
echo "------------------------------------------------------"
ln -s  ~/OpenFOAM/ThirdParty-1.6 ~/OpenFOAM/ThirdParty-1.6.x
cd ~/OpenFOAM
git clone git://repo.or.cz/OpenFOAM-1.6.x.git
cd OpenFOAM-1.6.x/
. ~/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc 
echo . ~/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc >> ~/.bashrc
I also have connection problems when using git clone git://repo.or.cz/OpenFOAM-1.6.x.git as it gives the error "connection refused". However, using git clone http://repo.or.cz/r/OpenFOAM-1.6.x.git works fine.
CedricVH is offline   Reply With Quote

Old   December 11, 2009, 05:01
Default
  #178
Senior Member
 
MadsR's Avatar
 
Mads Reck
Join Date: Aug 2009
Location: Copenhagen, Denmark
Posts: 175
Rep Power: 8
MadsR is on a distinguished road
Good call Cedric :-) thanks. I've changed your find and changed git to http (and possibly introduced other errors...)


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

Old   December 11, 2009, 09:29
Default
  #179
Senior Member
 
akidess's Avatar
 
Anton Kidess
Join Date: May 2009
Location: Delft, Netherlands
Posts: 919
Rep Power: 17
akidess will become famous soon enough
Using http:// instead of git:// will help with firewall related issues, but will also slow down the pull. Just something to keep in mind... Maybe we could add some intelligence to the script to use http only if git fails?
akidess is offline   Reply With Quote

Old   December 11, 2009, 10:19
Default
  #180
Member
 
83_Ale_83's Avatar
 
Alessandro
Join Date: Nov 2009
Posts: 67
Rep Power: 7
83_Ale_83 is on a distinguished road
Quote:
Originally Posted by CedricVH View Post
Mads, I think I have found a little bug in your install-cookbook script. When I start the version for Ubuntu 9.10 64bit, it crashes at line 53 as the script can not find the folder OpenFOAM-1.6.x, even after a succesful git clone.

The reason is that the working directory is not correctly set. The script changes the working directory with the command cd ~/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux64/lib64 but does not go back to the ~/OpenFOAM folder. The solution is very simple: just add cd ~/OpenFOAM before the git command.

Code:
echo "FIX up for Ubuntu 9.10"
cd ~/OpenFOAM/ThirdParty-1.6/gcc-4.3.3/platforms/linux64/lib64
mv libstdc++.so.6 libstdc++.so.6.orig
ln -s /usr/lib/libstdc++.so.6.0.10 libstdc++.so.6
mv libgcc_s.so.1 libgcc_s.so.1.orig
ln -s /lib/libgcc_s.so.1
echo "Fix up done"
echo "------------------------------------------------------"
echo "Retrieveing OpenFOAM..."
echo "------------------------------------------------------"
ln -s  ~/OpenFOAM/ThirdParty-1.6 ~/OpenFOAM/ThirdParty-1.6.x
cd ~/OpenFOAM
git clone git://repo.or.cz/OpenFOAM-1.6.x.git
cd OpenFOAM-1.6.x/
. ~/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc 
echo . ~/OpenFOAM/OpenFOAM-1.6.x/etc/bashrc >> ~/.bashrc
I also have connection problems when using git clone git://repo.or.cz/OpenFOAM-1.6.x.git as it gives the error "connection refused". However, using git clone http://repo.or.cz/r/OpenFOAM-1.6.x.git works fine.
Exactly, this is what I mean in my post 1,2 pages before Cedric has explained it better
__________________

83_Ale_83 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
install OpenFoam 1.6 by building source: how? niudie OpenFOAM Installation 13 April 26, 2011 00: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 00:48
Install openFOAM 1.6 on debian 32bit - blockMesh: command not found fossy OpenFOAM Installation 1 August 28, 2009 04:06
Install of OpenFOAM 1.6 Error 1 Error 2 & run tutorial potac OpenFOAM Installation 3 August 27, 2009 09:04


All times are GMT -4. The time now is 14:08.