CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   Problem installing OF 1.5 on Ubuntu 9.05 (https://www.cfd-online.com/Forums/openfoam-installation/64039-problem-installing-1-5-ubuntu-9-05-a.html)

smart April 27, 2009 14:59

Problem installing OF 1.5 on Ubuntu 9.05
 
Hi,

I am a beginner in LINUX/OpenFOAM. I recently installed a dual boot (Xp, Ubuntu) on my computer. I want to install OpenFOAM 1.5 so I have download and unpack the files in home/cj9998/OpenFOAM directory since I cannot add folder in "home". I am stuck in the third point of the readme file (installation).

Firstly, I run the foamSystemCheck script and all are OK!

I run "echo $SHELL" and the result is : /bin/bash

From this, I have to add the following line to the end of my $home/.bashrc file:
$home/cj9998/OpenFOAM/OpenFOAM-1.5/etc/bashrc

How can I do this? If I open bashrc with "gedit ~/.bashrc, the file open and I can add the previous line at the end. I am not sure that this manner is OK!

After that, I have to update the environment variables by sourcing the $home/.bashrc file by typing in the terminal:
~/.bashrc
The following result is obtained: bash: /home/cj9998/.bashrc: Permission denied

Please, can you help me solving the problem?

alberto April 27, 2009 16:14

This is the correct line for your ~/.bashrc:

. $HOME/OpenFOAM/OpenFOAM-1.5.x/etc/bashrc

Best,

smart April 28, 2009 16:07

capital letter or not?
 
Thank you, but when I open a terminal, I get :
sylvain@Sylvain:~$

My OpenFOAM files are in:
home/Sylvain/OpenFOAM/OpenFOAM-1.5/

HOME or home?

And I cannot have permission when I type:

.$home/.bashrc

How I can have this permission to write the line at the end of the file?

Thank you

alberto April 28, 2009 18:33

Open a new terminal, type:

cd /home/Sylvain
gedit .bashrc

Add the following line at the end of the file:

. $HOME/OpenFOAM/OpenFOAM-1.5.x/etc/bashrc

Please, cut and paste it exactly and completely. There is a dot (.) followed by a space and then $HOME...

Best,

smart April 28, 2009 20:03

permission denied!
 
Thanks a lot but when I type:
.$HOME/.bashrc

I get:

bash: ./home/sylvain/.bashrc: no file or folderof this type

if I try:
.$sylvain/.bashrc

I get:

bash: ./.bashrc: Permission denied

When I open a new terminal it is write:
sylvain@Sylvain:~$

is it normal and OK?

So I cannot source the environment variables!

Thank a lot for your help.

alberto April 28, 2009 20:57

Hi,

the procedure I told you didn't require these steps ;)

You should simply:

  • Open the file ~/.bashrc in an editor. For example, type in a terminal:
    • gedit ~/.bashrc
  • Copy exactly this line at the end of it:
    • . $HOME/OpenFOAM/OpenFOAM-1.5.x/etc/bashrc
The next time you open a terminal, the OpenFOAM configuration settings will be set up.

P.S. UNIX is case sensitive. Sylvain is not silvain in a path. :)

Best,

smart April 28, 2009 21:12

Testing the installation!
 
Thank you for your fast reply!

With your answer, OpenFOAM should be correctly installed. But when I check the installation setup by executing the "foamInstallationTest" script a fatal error occurs:

sylvain@Sylvain:~/OpenFOAM/OpenFOAM-1.5/bin$ ./foamInstallationTest
Executing ./foamInstallationTest:


Checking basic setup...
-------------------------------------------------------------------------------

FATAL ERROR: OpenFOAM environment not configured.

Please refer to the installation section of the README file:
<OpenFOAM installation dir>/OpenFOAM-1.5/README
to source the OpenFOAM environment.

sylvain@Sylvain:~/OpenFOAM/OpenFOAM-1.5/bin$

How can I install the software correctly? Under windows, we need a executable file (".exe") to install a program. With Linux, what is the way?

I would like to know what is the source of this error? Ubuntu? OpenFOAM installation? The fact that I am connected as user instead of root? Thank you to help me finding the solution.

Have a good night!

alberto April 28, 2009 21:18

It is correct to be user and not root. So that's not the problem.

It seems that your local console (bash) configurations are not loaded from the configuration file you introduced in .bashrc. I am not familiar with ubuntu however, so I don't know its details.

For detailed installation instructions of OpenFOAM please refer to its README file.

Best,

Xabi April 29, 2009 03:08

Hi smart,
I think you need to update the enviroment variables before you test the installation. Type the following:
  • . $HOME/.bashrc
By the way,I am also trying to install OF in ubuntu and i have problems with the next step. Let me know if you succeed.
/Xabi

smart April 29, 2009 08:49

unable to source environment variables!
 
Thanks a lot Xabi but when I type:
.$HOME/.bashrc

I get:

bash: ./home/sylvain/.bashrc: no file or folderof this type

if I try:
.$sylvain/.bashrc

I get:

bash: ./.bashrc: Permission denied

When I open a new terminal it is write:
sylvain@Sylvain:~$

is it normal and OK?

So I cannot source the environment variables!

What have you done?

What is your computer configuration and version of Ubuntu?

tino_boelke April 29, 2009 15:43

You have to type:

. $HOME/.bashrc

with space after the Dot, or just open a new terminal or a new tab in the terminal you are right now (the bashrc is executed in every terminal after opening). Everyone of these operations will load the commands from this file.

smart June 29, 2009 15:32

I succeed!
 
Hi all,

I finaly get the OpenFOAM-1.5-dev running perfectly. I changed my linux system to Ubuntu 8.04. I experienced problems with paraFoam and paraview under ubuntu 9.04.

I solved the problem by installing paraview 3.4.0 instead of 3.3-cvs. For this, I changed some file (buildParaView3.3-cvs, in OpenFOAM-1.5-dev/bin and in OpenFOAM-1.5-dev/bin/tools and the bashrc in OpenFOAM-1.5-dev/etc/apps to point to the ParaView-3.4.0 folder (OpenFOAM/ThirdParty/ParaView-3.4.0).

I think it should be OK too with the ubuntu 9.04 in which the qmake version 4.3.5 should be installed.

Thank to all!

yapalparvi June 30, 2009 18:08

Problems installing OpenFoam on ubuntu 9.04
 
/usr/bin/ld: cannot find -lconversion
collect2: ld returned 1 exit status
make[3]: *** [/home/ramesh/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/star4ToFoam] Error 1
make[2]: *** [star4ToFoam] Error 2
/usr/bin/ld: cannot find -lfiniteVolume
collect2: ld returned 1 exit status
make[3]: *** [/home/ramesh/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/foamMeshToFluent] Error 1
make[2]: *** [foamMeshToFluent] Error 2
/usr/bin/ld: cannot find -lmeshTools
collect2: ld returned 1 exit status
make[3]: *** [/home/ramesh/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/polyDualMesh] Error 1
make[2]: *** [polyDualMesh] Error 2
make[2]: Target `application' not remade because of errors.
make[1]: *** [conversion] Error 2
make[1]: Target `application' not remade because of errors.
make: *** [mesh] Error 2
In file included from chemkinToFoam.C:31:
/home/ramesh/OpenFOAM/OpenFOAM-1.5/src/thermophysicalModels/combustion/lnInclude/chemkinReader.H:50:23: error: FlexLexer.h: No such file or directory
In file included from chemkinToFoam.C:31:
/home/ramesh/OpenFOAM/OpenFOAM-1.5/src/thermophysicalModels/combustion/lnInclude/chemkinReader.H:65: error: expected class-name before ‘{’ token
make[2]: *** [Make/linuxGccDPOpt/chemkinToFoam.o] Error 1
make[2]: Target `/home/ramesh/OpenFOAM/OpenFOAM-1.5/applications/bin/linuxGccDPOpt/chemkinToFoam' not remade because of errors.
make[1]: *** [chemkinToFoam] Error 2
make[1]: Target `application' not remade because of errors.
make: *** [thermophysical] Error 2
make: Target `application' not remade because of errors.
+ [ = doc ]



Please let me know how can I fix it. Thanks

zarraceno July 1, 2009 12:49

Quote:

Originally Posted by smart (Post 220871)
Hi all,

I finaly get the OpenFOAM-1.5-dev running perfectly. I changed my linux system to Ubuntu 8.04. I experienced problems with paraFoam and paraview under ubuntu 9.04.

I solved the problem by installing paraview 3.4.0 instead of 3.3-cvs. For this, I changed some file (buildParaView3.3-cvs, in OpenFOAM-1.5-dev/bin and in OpenFOAM-1.5-dev/bin/tools and the bashrc in OpenFOAM-1.5-dev/etc/apps to point to the ParaView-3.4.0 folder (OpenFOAM/ThirdParty/ParaView-3.4.0).

I think it should be OK too with the ubuntu 9.04 in which the qmake version 4.3.5 should be installed.

Thank to all!

Hi.. what tipe of machine, do you have ?

yapalparvi July 1, 2009 14:12

Quote:

Originally Posted by zarraceno (Post 221118)
Hi.. what tipe of machine, do you have ?


I have 64 bit machine running ubuntu 9.04 on it

sagkavin July 20, 2009 07:52

I have similar problem the output of ./foamInstallationTest is



FATAL ERROR: No remote shell available.
OpenFOAM 1.5 enviroment requires either ssh and/or rsh.
Contact your system administrator.


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

The system test has evoked 1 fatal error(s).

The foam installation contains 2 critical error(s).

smart July 20, 2009 09:30

This is a fatal error only if you want to use parallel computing. Otherwise, don't mind about this message. If you want to use this option, you will able to fix this issue latter by installing ssh or rsh.

chiven August 9, 2009 01:22

Hi, Ramesh, I recompile the OpenFoam-1.6, and just meet the same errors like yours:
/usr/bin/ld: cannot find -lconversion
/usr/bin/ld: cannot find -lfiniteVolume
/usr/bin/ld: cannot find -lmeshTools

Would you like to share your experiences fixing this problem with me? Thank you in advance.
Best regards,
Chiven

chiven August 10, 2009 19:12

The thirdParty software is installed, problems is over.

Good luck.
Chiven


All times are GMT -4. The time now is 02:07.