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

[OpenFOAM.org] Problems installing OpenFOAM 2.4.0 on Ubuntu 16.04

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

Like Tree3Likes
  • 2 Post By wyldckat
  • 1 Post By swap_9068

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 28, 2016, 08:37
Default Problems installing OpenFOAM 2.4.0 on Ubuntu 16.04
  #1
Member
 
belamou
Join Date: Apr 2009
Posts: 40
Rep Power: 17
donminoti is on a distinguished road
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
Attached Files
File Type: gz make.log.tar.gz (19.9 KB, 17 views)
donminoti is offline   Reply With Quote

Old   March 28, 2016, 09:29
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
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
Tobi and hamedhiv like this.
__________________

Last edited by wyldckat; March 28, 2016 at 13:14. Reason: see "edit:"
wyldckat is offline   Reply With Quote

Old   March 28, 2016, 12:46
Default
  #3
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
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
wyldckat is offline   Reply With Quote

Old   March 28, 2016, 12:56
Default
  #4
Member
 
belamou
Join Date: Apr 2009
Posts: 40
Rep Power: 17
donminoti is on a distinguished road
Hi Bruno,

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

Thank you again for your support,
Best regards
donminoti is offline   Reply With Quote

Old   May 4, 2016, 18:08
Default
  #5
New Member
 
aslan nazari
Join Date: May 2016
Posts: 8
Rep Power: 10
Aslan_nzr is on a distinguished road
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
Attached Files
File Type: gz make.log.tar.gz (24.2 KB, 29 views)
Aslan_nzr is offline   Reply With Quote

Old   May 8, 2016, 15:08
Default
  #6
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer @Aslan_nzr: Please do the following steps, as detailed in post #3:
Quote:
Originally Posted by wyldckat View Post
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.

Last edited by wyldckat; May 8, 2016 at 16:54.
wyldckat is offline   Reply With Quote

Old   May 9, 2016, 04:31
Default
  #7
New Member
 
aslan nazari
Join Date: May 2016
Posts: 8
Rep Power: 10
Aslan_nzr is on a distinguished road
Dear wyldckat.
Thank you so much.
It works for me...
Aslan_nzr is offline   Reply With Quote

Old   May 31, 2016, 06:32
Default
  #8
Member
 
Join Date: Apr 2014
Location: N/A
Posts: 50
Rep Power: 12
FluentStarter is on a distinguished road
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
Attached Files
File Type: zip log.zip (88.7 KB, 2 views)

Last edited by FluentStarter; May 31, 2016 at 15:37.
FluentStarter is offline   Reply With Quote

Old   September 9, 2016, 12:47
Default
  #9
New Member
 
Eron Tiago
Join Date: Oct 2014
Posts: 2
Rep Power: 0
Eron is on a distinguished road
Quote:
Originally Posted by FluentStarter View Post
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 ../..
Eron is offline   Reply With Quote

Old   November 6, 2016, 07:18
Default Internal compiler error: segmentation fault
  #10
New Member
 
Marius-Corne Meijer
Join Date: Sep 2016
Location: Pretoria, South Africa
Posts: 4
Rep Power: 10
aeroeng91 is on a distinguished road
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

log.make.tar.gz

log.makePV_part1of2.tar.gz

log.makePV_part2of2.tar.gz
aeroeng91 is offline   Reply With Quote

Old   November 6, 2016, 16:35
Default
  #11
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quote:
Originally Posted by aeroeng91 View Post
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.
__________________
wyldckat is offline   Reply With Quote

Old   November 7, 2016, 03:38
Default
  #12
New Member
 
Marius-Corne Meijer
Join Date: Sep 2016
Location: Pretoria, South Africa
Posts: 4
Rep Power: 10
aeroeng91 is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
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!
aeroeng91 is offline   Reply With Quote

Old   March 16, 2017, 13:16
Default
  #13
New Member
 
Nicky
Join Date: Oct 2013
Posts: 8
Rep Power: 13
swap_9068 is on a distinguished road
My openfoam installation problem solved. Thank you very much Bruno Santos for writing so many post for providing fixes for openfoam installations.
wyldckat likes this.

Last edited by swap_9068; March 17, 2017 at 10:25.
swap_9068 is offline   Reply With Quote

Old   January 13, 2021, 18:07
Default
  #14
New Member
 
Hosein Falahaty
Join Date: Jan 2021
Posts: 10
Rep Power: 5
Falahaty is on a distinguished road
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.
Falahaty 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
Frequently Asked Questions about Installing OpenFOAM wyldckat OpenFOAM Installation 3 November 14, 2023 12:58
Map of the OpenFOAM Forum - Understanding where to post your questions! wyldckat OpenFOAM 10 September 2, 2021 06:29
[waves2Foam] Difficulties installing with OpenFOAM 4.1 on Ubuntu 16.04 Ben UWIHANGANYE OpenFOAM Community Contributions 4 May 4, 2018 06:14
[OpenFOAM.com] Installation of OpenFOAM 1.7.1 on Ubuntu 16.04 MM_Khan OpenFOAM Installation 11 September 3, 2017 10:22
Installing OpenFOAM 2.2.0 on Ubuntu 12.10 i686 AHutchison OpenFOAM Installation 6 June 4, 2013 13:11


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