CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Installation (https://www.cfd-online.com/Forums/openfoam-installation/)
-   -   [OpenFOAM.org] Problems installing OpenFOAM 2.4.0 on Ubuntu 16.04 (https://www.cfd-online.com/Forums/openfoam-installation/168746-problems-installing-openfoam-2-4-0-ubuntu-16-04-a.html)

donminoti March 28, 2016 07:37

Problems installing OpenFOAM 2.4.0 on Ubuntu 16.04
 
1 Attachment(s)
Hi wyldckat,
if intrested bellow is the results for OF2.4 on 16.04 ( Final beta release)

Well i have tried to install OF, using source files and Deb package ,both not work !.

# For Deb packages, the installer manager error message is :
Dependency is not satisfiable: libboost-thread 1.54.0

# For source build (same procedure as for 15.10) , the make.log is in attachment (both OF & PV) , it seems no error for PV, however still can not launch it !

Thanks
Best regards

wyldckat March 28, 2016 08:29

Hi donminoti,

Sorry, I completely forgot about Flex :( It was updated to 2.6 recently and only OpenFOAM 3.0.1 and newer is prepared for it, as far as I can remember.

Give me a few hours and I'll have the wiki page for 2.4.0 updated with instructions for Ubuntu 16.04.

Best regards,
Bruno

edit: The post above + this one and the 2 below came from this thread: http://www.cfd-online.com/Forums/ope...tml#post591857

wyldckat March 28, 2016 11:46

Hi donminoti,

Done and tested: https://openfoamwiki.net/index.php/I...u#Ubuntu_16.04

In your case, you can do the following steps to fix the problem:
Code:

#Go into OpenFOAM's main source folder
cd $WM_PROJECT_DIR
 
#Change how the flex version is checked
find src applications -name "*.L" -type f | xargs sed -i -e 's=\(YY\_FLEX\_SUBMINOR\_VERSION\)=YY_FLEX_MINOR_VERSION < 6 \&\& \1='

#Still better be certain that the correct Qt version is being used
export QT_SELECT=qt4
 
# This next command will take a while... somewhere between 30 minutes to 3-6 hours.
./Allwmake > make.log 2>&1
 
#Run it a second time for getting a summary of the installation
./Allwmake > make.log 2>&1

Hopefully this will finish up your build.

Best regards,
Bruno

donminoti March 28, 2016 11:56

Hi Bruno,

Great , good job. Both OF & PV are working well.

Thank you again for your support,
Best regards

Aslan_nzr May 4, 2016 17:08

1 Attachment(s)
Hi Bruno
I have problem in installing OpenFOAM 2.4 on the ubuntu 16.04 (git repository). I installed OF 3.0.1 without any problem,but i need OF2.4, I read the post about the several versions of OF by using aliases.and i did the same, but I failed to install it.
thank you in advance.
best regards

wyldckat May 8, 2016 14:08

Quick answer @Aslan_nzr: Please do the following steps, as detailed in post #3:
Quote:

Originally Posted by wyldckat (Post 591986)
In your case, you can do the following steps to fix the problem:
Code:

#Go into OpenFOAM's main source folder
cd $WM_PROJECT_DIR
 
#Change how the flex version is checked
find src applications -name "*.L" -type f | xargs sed -i -e 's=\(YY\_FLEX\_SUBMINOR\_VERSION\)=YY_FLEX_MINOR_VERSION < 6 \&\& \1='

#Still better be certain that the correct Qt version is being used
export QT_SELECT=qt4
 
# This next command will take a while... somewhere between 30 minutes to 3-6 hours.
./Allwmake > make.log 2>&1
 
#Run it a second time for getting a summary of the installation
./Allwmake > make.log 2>&1


As for the problem with CGAL, I'm still looking into this. The error is a bit strange, because I didn't have this problem in the (virtual) machine where I tested.

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

edit: I've solved the problem with building CGAL: http://openfoamwiki.net/index.php/In...u#Ubuntu_16.04

I didn't notice the error that I had gotten on the build I had made before on the VM. You can run the following commands to finish up the build:
Code:

foam

sed -i -e 's/^\(cgal_version=\).*/\1cgal-system/' OpenFOAM-2.4.0/etc/config/CGAL.sh

wmREFRESH

mkdir -p $CGAL_ARCH_PATH
mkdir -p $BOOST_ARCH_PATH



#Go into OpenFOAM's main source folder
cd $WM_PROJECT_DIR
 
#Still better be certain that the correct Qt version is being used
export QT_SELECT=qt4
 
# This next command will take a while... somewhere between 30 minutes to 3-6 hours.
./Allwmake > log.make 2>&1
 
#Run it a second time for getting a summary of the installation
./Allwmake > log.make 2>&1

And this should solve most of the problems.

Aslan_nzr May 9, 2016 03:31

Dear wyldckat.
Thank you so much.
It works for me...

FluentStarter May 31, 2016 05:32

1 Attachment(s)
Hello together,

I'm also facing some problems during the installation of Paraview.
A few days ago I already built (or at least I thought I built) Open Foam and Paraview but during the first tests with some tutorials I kept receiving errors indicating that Paraview is not installed properly. I searched in the web an tried to fix it, but couldn't find help.

So I deleted all the files and started to install it again, following the OpenFoam2.4.0 installation guide form OpenFoamWiki.

When I try to build Paraview there are a lot of errors and up to now I could't solve them.
Maybe someone has an idea how to solve those problems?

EDIT:
Succesfull Installation with this Bug-Fix....

http://bugs.openfoam.org/view.php?id=1734

Eron September 9, 2016 11:47

Quote:

Originally Posted by FluentStarter (Post 602595)
Hello together,

I'm also facing some problems during the installation of Paraview.
A few days ago I already built (or at least I thought I built) Open Foam and Paraview but during the first tests with some tutorials I kept receiving errors indicating that Paraview is not installed properly. I searched in the web an tried to fix it, but couldn't find help.

So I deleted all the files and started to install it again, following the OpenFoam2.4.0 installation guide form OpenFoamWiki.

When I try to build Paraview there are a lot of errors and up to now I could't solve them.
Maybe someone has an idea how to solve those problems?

EDIT:
Succesfull Installation with this Bug-Fix....

http://bugs.openfoam.org/view.php?id=1734

Hello FluentStarter,

This bug-fix should definitely work.
The point is that the line defining GLX_GLXEXT_LEGACY in vtkXOpenGLRenderWindow.cxx file is commented by default, which is kinda weird because NOT defining this will include glxext.h insteaad of glext.h from the library, and the former does not declare GLintptr. Kinda dumb too because there's a comment right above this defining line that states that you actually SHOULD define GLX_GLXEXT_LEGACY to prevent glx.h from including glxext.h.

This is why you need to fix it previously when building ParaView, just as https://openfoamwiki.net/index.php/I...u#Ubuntu_16.04 says:
Code:

sed -i -e 's=//#define GLX_GLXEXT_LEGACY=#define GLX_GLXEXT_LEGACY=' \
  ParaView-4.1.0/VTK/Rendering/OpenGL/vtkXOpenGLRenderWindow.cxx
 
cd $WM_THIRD_PARTY_DIR/ParaView-4.1.0
 
wget http://www.paraview.org/pipermail/paraview/attachments/20140210/464496cc/attachment.bin -O Fix.patch
patch -p1 < Fix.patch
 
cd VTK
wget https://github.com/gladk/VTK/commit/ef22d3d69421581b33bc0cd94b647da73b61ba96.patch -O Fix2.patch
patch -p1 < Fix2.patch
 
cd ../..


aeroeng91 November 6, 2016 06:18

Internal compiler error: segmentation fault
 
3 Attachment(s)
Hi all,

I followed the instructions with the bugfixes on my laptop and everything compiled fine. The same procedure on my desktop gave me an internal compiler error for PV and subsequently OF. Both machines run Ubuntu 16.04. I have attached the logmake files (I had to split the PV log into two parts because of file size limitations).

For reference, the desktop is running
Code:

gcc (Ubuntu 5.4.0-6ubuntu1~16.04.2) 5.4.0 20160609
Code:

cmake version 3.5.1
Thanks in advance for any insight.

MC

Attachment 51523

Attachment 51524

Attachment 51525

wyldckat November 6, 2016 15:35

Quote:

Originally Posted by aeroeng91 (Post 624324)
Thanks in advance for any insight.

Quick answer: Either your desktop machine as very little RAM available or it's having a memory-CPU problem that needs to be fixed. If it crashes often (at least once a day?), then your machine has hardware issues.

From the ParaView build:
Code:

/usr/include/x86_64-linux-gnu/bits/wchar2.h:245:1: internal compiler error: Segmentation fault
 __fortify_function wchar_t *
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-5/README.Bugs> for instructions.

From the OpenFOAM build:
Code:

PRODUCT_OPERATOR(typeOfSum, +, add)
 ^
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-5/README.Bugs> for instructions.

I had this kind of problem some years ago and one of the memory modules was corrupted due to a motherboard malfunction or some electrical issue of some sort. After removing the memory module, everything went back to normal.

For more details on how to check on RAM and CPU: https://openfoamwiki.net/index.php/H...and_CPU_are_OK

The other possibility would be if there was some problem during the installation of Ubuntu, e.g. disk malfunction and byte corruption.

aeroeng91 November 7, 2016 02:38

Quote:

Originally Posted by wyldckat (Post 624393)
Quick answer: Either your desktop machine as very little RAM available or it's having a memory-CPU problem that needs to be fixed. If it crashes often (at least once a day?), then your machine has hardware issues.
...
I had this kind of problem some years ago and one of the memory modules was corrupted due to a motherboard malfunction or some electrical issue of some sort. After removing the memory module, everything went back to normal.

Hi wyldcat,

Thanks for the (spot-on) assessment. I had upgraded my RAM prior to installing. I ran the stressapptest and everything checked out to be fine*. I then recompiled PV without getting any errors.

I then proceeded to compile OF and it got caught up with any segmentation fault at a late stage, which shows that somewhere there's a reliability issue with my memory. I ran Allwmake again and it patched up the parts in the compilation where it had failed due to the memory issue. Checked the tutorials and all's running fine.

Thanks for the help!

swap_9068 March 16, 2017 12:16

My openfoam installation problem solved. Thank you very much Bruno Santos for writing so many post for providing fixes for openfoam installations.

Falahaty January 13, 2021 17:07

I am having problem with installing OpenFOAM2.4.x on Ubuntu16.04. Could anyone help me please?

I could succesfully install OpenFOAM2.4.0, and for using some sampes I need to upgrade it to 2.4.x, but it doesn't work. I have followed the instructions given in https://openfoamwiki.net/index.php/I...M-2.4.x/Ubuntu.

Thanks in advance.


All times are GMT -4. The time now is 21:23.