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

OF 1.9 (aka OF 2.1) on Mac OS X

Register Blogs Community New Posts Updated Threads Search

Like Tree25Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 28, 2012, 13:58
Default
  #41
New Member
 
Jie Qin
Join Date: Mar 2011
Posts: 8
Rep Power: 15
qinjie1629 is on a distinguished road
I format a USB driver as a case-sensitive disk, copy the tar files into this driver, and then unzip the tar files.

I follow the instruction step by step until the last step. when I input source etc/bashrc, following error comes. Please give me some suggestions.


-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/etc/config/settings.sh: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/etc/config/aliases.sh: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory




And then, I used following command to create a link to the USB dirver
>> ln -sf /Volumes/OF OpenFOAM
>> cd OpenFOAM
>> cd OpenFOAM-2.1.0
>> source etc/bashrc

Then, I can compile the files, but, it is very slow due to the limited usb speed. How can I create a sparse image from this USB driver?

Last edited by qinjie1629; March 28, 2012 at 15:02.
qinjie1629 is offline   Reply With Quote

Old   March 28, 2012, 17:38
Default
  #42
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by qinjie1629 View Post
I format a USB driver as a case-sensitive disk, copy the tar files into this driver, and then unzip the tar files.

I follow the instruction step by step until the last step. when I input source etc/bashrc, following error comes. Please give me some suggestions.


-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/etc/config/settings.sh: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/etc/config/aliases.sh: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamEtcFile: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory
-bash: /Users/qinjie/OpenFOAM/OpenFOAM-2.1.0/bin/foamCleanPath: No such file or directory




And then, I used following command to create a link to the USB dirver
>> ln -sf /Volumes/OF OpenFOAM
>> cd OpenFOAM
>> cd OpenFOAM-2.1.0
>> source etc/bashrc

Then, I can compile the files, but, it is very slow due to the limited usb speed. How can I create a sparse image from this USB driver?
Create a SparseImage with a fitting file-system using the Disk Utility of Mac OS X and copy the files from the stick to that image using cp (with appropriate options)
gschaider is offline   Reply With Quote

Old   March 29, 2012, 05:23
Default
  #43
New Member
 
Jie Qin
Join Date: Mar 2011
Posts: 8
Rep Power: 15
qinjie1629 is on a distinguished road
Thank you for your kind help.

Here is another problem.
I test the installation by running a tutorial (/incompressible/icoFoam/cavity), when I input 'paraFoam', following errors occur

------
FATAL ERROR: ParaView reader module libraries do not exist

Please build the reader module before continuing:
cd $FOAM_UTILITIES/postProcessing/graphics/PV3Readers
./Allwclean
./Allwmake
------

when I build the PV3Readers, following errors occur
------
+ '[' -d /Users/qinjie/OpenFOAM/ThirdParty-2.1.0/platforms/darwinIntel64Gcc46/paraview-3.12.0 -a -r /Users/qinjie/OpenFOAM/ThirdParty-2.1.0/platforms/darwinIntel64Gcc46/paraview-3.12.0 ']'
------

I built the ThirdParty-2.1.0 twice, and the paraFoam cannot be used.

I install a built Qt4.8.1 (DMG file) and then install a built ParaView3.14 (DMG file). But, the paraFoam still cannot be used.

I found an introduction about how to use pre-build ParaView for OpenFOAM, but, it is used for Linux, not Mac.

I found this words in the instruction of this thread:
------
"As usual I didn't bother to get the PV3Reader (aka paraFoam) to compile. Use an up-to-date paraview from Kitware with the built in reader for OF"
------
I donot know what is that mean 'the built in reader for OF'.

Last edited by qinjie1629; March 29, 2012 at 09:58.
qinjie1629 is offline   Reply With Quote

Old   March 31, 2012, 12:26
Default
  #44
New Member
 
hi, Legend
Join Date: Feb 2012
Posts: 1
Rep Power: 0
hi_Legend is on a distinguished road
Quote:
Originally Posted by lithos View Post
Sorry guys for being late. Here is a link to the manual: https://rapidshare.com/files/3641151...OS_X.pdf?bin=1

Please let me know if you could store this somewhere else. Thanks.

Hava a nice weekend.

Could anyone email me this pdf file? Thanks in advance!
hellolegend@gmail.com
hi_Legend is offline   Reply With Quote

Old   March 31, 2012, 17:19
Default
  #45
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by qinjie1629 View Post
Thank you for your kind help.

Here is another problem.
I test the installation by running a tutorial (/incompressible/icoFoam/cavity), when I input 'paraFoam', following errors occur

------
FATAL ERROR: ParaView reader module libraries do not exist

Please build the reader module before continuing:
cd $FOAM_UTILITIES/postProcessing/graphics/PV3Readers
./Allwclean
./Allwmake
------

when I build the PV3Readers, following errors occur
------
+ '[' -d /Users/qinjie/OpenFOAM/ThirdParty-2.1.0/platforms/darwinIntel64Gcc46/paraview-3.12.0 -a -r /Users/qinjie/OpenFOAM/ThirdParty-2.1.0/platforms/darwinIntel64Gcc46/paraview-3.12.0 ']'
------

I built the ThirdParty-2.1.0 twice, and the paraFoam cannot be used.

I install a built Qt4.8.1 (DMG file) and then install a built ParaView3.14 (DMG file). But, the paraFoam still cannot be used.

I found an introduction about how to use pre-build ParaView for OpenFOAM, but, it is used for Linux, not Mac.

I found this words in the instruction of this thread:
------
"As usual I didn't bother to get the PV3Reader (aka paraFoam) to compile. Use an up-to-date paraview from Kitware with the built in reader for OF"
------
I donot know what is that mean 'the built in reader for OF'.
Compilation of the PV3Reader is possible but I never bother because you need a self-compiled paraview (the binaries provided by kitware don't provide the required headers etc).

Nevertheless: create a file foo.foam (the extension is important) in your case folder and Paraview can open it (that is the built-in reader)
gschaider is offline   Reply With Quote

Old   April 1, 2012, 08:06
Default
  #46
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
Greetings to all!

Since you are all very busy and I had some time to spare, I asked Michael Plagge for permission to transcribe the pdf he posted here some time ago and I've finally got around to doing it: http://openfoamwiki.net/index.php/Ho...enFOAM_v21_Mac
If anyone wants to improve the wiki page, feel free to do so, specially because I don't have a Mac

I've also updated a bit the main category for Mac OS X: http://openfoamwiki.net/index.php/Ca...AM_on_Mac_OS_X

If anyone wants to something like this in the future, namely copy-paste PDF stuff to a wiki page, some instructions are provided here: http://openfoamwiki.net/index.php/Ta...enFOAM_v21_Mac

Best regards,
Bruno

PS: this ain't no April Fools' lie
bigphil likes this.
__________________
wyldckat is offline   Reply With Quote

Old   April 1, 2012, 10:18
Default
  #47
New Member
 
Jie Qin
Join Date: Mar 2011
Posts: 8
Rep Power: 15
qinjie1629 is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
Greetings to all!

Since you are all very busy and I had some time to spare, I asked Michael Plagge for permission to transcribe the pdf he posted here some time ago and I've finally got around to doing it: http://openfoamwiki.net/index.php/Ho...enFOAM_v21_Mac
If anyone wants to improve the wiki page, feel free to do so, specially because I don't have a Mac

I've also updated a bit the main category for Mac OS X: http://openfoamwiki.net/index.php/Ca...AM_on_Mac_OS_X

If anyone wants to something like this in the future, namely copy-paste PDF stuff to a wiki page, some instructions are provided here: http://openfoamwiki.net/index.php/Ta...enFOAM_v21_Mac

Best regards,
Bruno

PS: this ain't no April Fools' lie


Great! Thank you so much for your help.
qinjie1629 is offline   Reply With Quote

Old   April 12, 2012, 19:29
Default
  #48
New Member
 
Rob
Join Date: Apr 2012
Posts: 4
Rep Power: 14
cocopops is on a distinguished road
I seem to doing fine with the ins ructions until I have to source the etc/bashrc file.

I get the error "-bash: ulimit: −n: invalid number".

Anyone know how I can fix this? Cheers.
cocopops is offline   Reply With Quote

Old   April 13, 2012, 04:18
Default
  #49
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
Greetings Rob and welcome to the forum!

Run on your command line this command:
Code:
ulimit −n 1024
Does it give the same error? If so, try another smaller value.

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   April 13, 2012, 04:39
Default
  #50
New Member
 
Rob
Join Date: Apr 2012
Posts: 4
Rep Power: 14
cocopops is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
Greetings Rob and welcome to the forum!

Run on your command line this command:
Code:
ulimit −n 1024
Does it give the same error? If so, try another smaller value.

Best regards,
Bruno
Hey Bruno, thanks for the help. I get no error or message at all when I type this command.

I tried deleting the line altogether, but I got an error when compiling.
cocopops is offline   Reply With Quote

Old   April 13, 2012, 04:49
Default
  #51
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 cocopops View Post
Hey Bruno, thanks for the help. I get no error or message at all when I type this command.

I tried deleting the line altogether, but I got an error when compiling.
Ooops, I forgot to check which "/etc/bashrc" the original article was refering to. Check the instructions again and you should see that it refers to "OpenFOAM-2.1.0/etc/bashrc", not "/etc/bashrc"...
__________________
wyldckat is offline   Reply With Quote

Old   April 13, 2012, 04:59
Default
  #52
New Member
 
Rob
Join Date: Apr 2012
Posts: 4
Rep Power: 14
cocopops is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
Ooops, I forgot to check which "/etc/bashrc" the original article was refering to. Check the instructions again and you should see that it refers to "OpenFOAM-2.1.0/etc/bashrc", not "/etc/bashrc"...
This is the bashrc I was using. Should I get some sort of message when typing "ulimit -n 1024"?
cocopops is offline   Reply With Quote

Old   April 13, 2012, 05:07
Default
  #53
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 cocopops View Post
This is the bashrc I was using. Should I get some sort of message when typing "ulimit -n 1024"?
Nope, there shouldn't be any message, at least as far as I remember...
You can run that command after sourcing the file:
Code:
. OpenFOAM/OpenFOAM-2.1.0/etc/bashrc
ulimit -n 1024
__________________
wyldckat is offline   Reply With Quote

Old   April 13, 2012, 05:41
Default
  #54
New Member
 
Michael
Join Date: Dec 2011
Location: Geneva
Posts: 28
Rep Power: 15
lithos is on a distinguished road
Hey,

there should be an output of the current limit on the command line. I attach you a screenshot.

If you set the ulimit, there should be no output, see second screenshot.

Cheers,

Michael
Attached Images
File Type: jpg ulimit.jpg (19.7 KB, 27 views)
File Type: jpg ulimit2.jpg (16.9 KB, 20 views)

Last edited by lithos; April 13, 2012 at 05:43. Reason: Adding second command line screenshot
lithos is offline   Reply With Quote

Old   April 13, 2012, 06:04
Default
  #55
Assistant Moderator
 
Bernhard Gschaider
Join Date: Mar 2009
Posts: 4,225
Rep Power: 51
gschaider will become famous soon enoughgschaider will become famous soon enough
Quote:
Originally Posted by lithos View Post
Hey,

there should be an output of the current limit on the command line. I attach you a screenshot.

If you set the ulimit, there should be no output, see second screenshot.

Cheers,

Michael
What interests me is the source of the error message. I don't find a call to ulimit in my etc/bashrc.

Could you have a look where it is with (lets look everywhere to be sure)

grep -r ulimit $WM_PROJECT_DIR/etc/*

and post the extract of the script (and state where you got the Mac-patches from)
gschaider is offline   Reply With Quote

Old   April 13, 2012, 06:18
Default
  #56
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 Bernhard,

No need for that, because ulimit is being introduced manually, accordingly to the instructions from here: http://openfoamwiki.net/index.php/Ho...enFOAM_v21_Mac - search for "ulimit"

But like I wrote before, I don't have a Mac to fully test the instructions...

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Old   April 13, 2012, 07:26
Default
  #57
New Member
 
Michael
Join Date: Dec 2011
Location: Geneva
Posts: 28
Rep Power: 15
lithos is on a distinguished road
Quote:
Originally Posted by gschaider View Post
What interests me is the source of the error message. I don't find a call to ulimit in my etc/bashrc.

Could you have a look where it is with (lets look everywhere to be sure)

grep -r ulimit $WM_PROJECT_DIR/etc/*

and post the extract of the script (and state where you got the Mac-patches from)
Well, sorry for not mentioning it, but I mean the etc/bashrc in my OpenFOAM-directory where I added the lines for ulimit and export WM_NCOMPPROCS manually. Normally you should not use /etc/bashrc on a Mac unless you know what you're doing.

If cocopops has still problems, it might be a problem of his operating system.

Concerning the manual, it worked exact the way I wrote it down. I am just trying to install the older 1.7.1 version which has a similar way.
lithos is offline   Reply With Quote

Old   April 13, 2012, 15:58
Default
  #58
New Member
 
Rob
Join Date: Apr 2012
Posts: 4
Rep Power: 14
cocopops is on a distinguished road
I'm fairly sure I got no error when trying to source it earlier, but when I got home (didn't want to compile it in public, laptop gets a bit noisy!" I got another error when trying to run './Allwmake'.

So I started again, and I'm back to the limit error. I understand I can set the value myself, but I'm not sure how I decide a value.

Sorry for the questions, I'm not used to command line stuff (I know, maybe I'm not ready for OpenFOAM, but I want to give it a go), I usually just double-click things to run them, hah.
cocopops is offline   Reply With Quote

Old   April 13, 2012, 16:33
Default
  #59
New Member
 
Michael
Join Date: Dec 2011
Location: Geneva
Posts: 28
Rep Power: 15
lithos is on a distinguished road
Quote:
Originally Posted by cocopops View Post
I'm fairly sure I got no error when trying to source it earlier, but when I got home (didn't want to compile it in public, laptop gets a bit noisy!" I got another error when trying to run './Allwmake'.

So I started again, and I'm back to the limit error. I understand I can set the value myself, but I'm not sure how I decide a value.

Sorry for the questions, I'm not used to command line stuff (I know, maybe I'm not ready for OpenFOAM, but I want to give it a go), I usually just double-click things to run them, hah.
Hey,
normally if you type
Code:
ulimit -n 1024
it keeps the value until you close the terminal and open a new one. The entry in the bashrc script is just to enable this every time you recompile some part of OpenFOAM. The command changes the number of files a process is allowed to open at the same time. Since the compilation involves a lot of small text files it is advisable to set it to a higher value like 1024 (default is 256).

Could you please tell us which version of OS X you're using?

Have a nice evening.
wyldckat likes this.
lithos is offline   Reply With Quote

Old   April 13, 2012, 16:37
Default
  #60
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 Rob,

Quote:
Originally Posted by cocopops View Post
So I started again, and I'm back to the limit error. I understand I can set the value myself, but I'm not sure how I decide a value.
Like I wrote before, you can simply source the "bashrc" file and run it afterwards, because AFAIK ulimit is only necessary during the building stage:
Code:
. OpenFOAM/OpenFOAM-2.1.0/etc/bashrc
ulimit -n 1024
Note that by source I mean that the following two commands should do the exact same thing:
Code:
. OpenFOAM/OpenFOAM-2.1.0/etc/bashrc
source OpenFOAM/OpenFOAM-2.1.0/etc/bashrc
As for the errors you're getting, you can do the following steps:
Code:
./Allwmake > Allwmake.log 2>&1
tar -czf log.tar.gz Allwmake.log
Then attach the file "log.tar.gz" to your next post so we can have a look at it.
If you want to keep your working paths and user names private, then before compressing the "Allwmake.log" file, use a text editor to search and replace all of the sensitive words.

In the mean time, I'm going to do another review to the wiki page and put some additional sections on it, so it's easier to point people to it.
edit: done!

Best regards,
Bruno
__________________

Last edited by wyldckat; April 13, 2012 at 17:16. Reason: see "edit:"
wyldckat is offline   Reply With Quote

Reply

Tags
compilation error


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
Extend Project 1.6-ext Binary Release for Mac OS X hjasak OpenFOAM Announcements from Other Sources 26 November 5, 2013 17:50
Openfoam mac: Compiling custom libraries atareen64 OpenFOAM 3 April 14, 2011 12:01
OpenFOAM-1.6 on Mac OS X 10.6.1 elvisjohndowson OpenFOAM 6 October 21, 2009 16:45
Mac Simple Install Request or Processing Assistance Help sjohnson OpenFOAM Installation 4 December 12, 2008 08:46
MAC + SOLA for free surface T Main CFD Forum 1 April 11, 2001 14:43


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