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 14 for WindowstmCygwin (https://www.cfd-online.com/Forums/openfoam-installation/57338-openfoam-14-windowstmcygwin.html)

7islands October 2, 2007 09:17

Hi David, @ls message: If you
 
Hi David,
@ls message: If you do maind the harmless warning just comment out that part of code (lines 159-168). And if I'm allowed to say a bit more, the Cygwin port as a whole is for those who have enough expertise as to be able to determine what to do by yourself, or at least with a hint in README.Cygwin: "2.1. Usually the OpenFOAM initialization script (OpenFOAM-1.4/.bashrc) automatically looks for the newest version of installed JDK. If it doesn't work set JAVA_HOME variable in OpenFOAM-1.4/.bashrc manually after unpacking the OpenFOAM distribution."

@VMware: I think it totally depends on what expertise you have and how you plan to use OpenFOAM. As for me, I have both OpenFOAM+Linux on VMware and the Cygwin port but the one I regurally use is the Cygwin port.

Takuya

djmeyer October 2, 2007 10:08

It is nice to know that the me
 
It is nice to know that the message is harmless.

OpenFOAM has been compiling for an hour or 2 so far without anything that appears to be a major error message.

FYI I was reading the README from the link above and the section 2.1 in it is different.
Also, if people never go outside their comfort zone, they never learn anything.

fugu October 26, 2007 14:18

I tried to install version 1.4
 
I tried to install version 1.4.3 of openFoam 1.4 cygwin following the README.Cygwin and the information posted on this thread.
Apparently the code compiles but when I try to issue the command foamx I get the following error message:
Starting NameServer with inet:svname:1234 ...
Starting FoamX Host Browser with inet:svname:1234 ...
/home/Luca/OpenFOAM/OpenFOAM-1.4/bin/runFoamXHB: line 153: FoamXHostBrow
mand not found
runFoamXHB : cleanup
runFoamXHB: Killing name server nsd(pid 143700).
/home/Luca/OpenFOAM/OpenFOAM-1.4/bin/runFoamXHB: line 74: 143700 Killed
nsd -ORBIIOPAddr $myIOP --ior $FOAMX_CONFIG/ns.ref < /dev/null

Any hints on how to solve the problem?
Regards

7islands October 26, 2007 19:21

Hi Luca, Hmm, extrapolating t
 
Hi Luca,
Hmm, extrapolating the seemingly truncated error message it is likely that the FoamX-stuff didn't actually compile. Could you

* check if FoamXHostBrowser really exists by which FoamXHostBrowser

and if it doesn't exist,

* go to OpenFOAM-1.4/applications/utilities/preProcessing/FoamX
* type ./Allwmake
* and report if there's anything strange?

Takuya

fugu October 27, 2007 11:17

I followed your advice and fou
 
I followed your advice and found that FoamXHostBrowser wasn't compiled
the following message reports the first in a long list of errors when I try Allwmake in the FoamX
directory:

+ cd C++
+ ./Allwmake
+ case $WM_ARCH in
+ CMD='wmake lib'
+ cd FoamXServer
+ wmake lib
Dropping import dependency files
SOURCE=FoamX.C ; g++ -m32 -Dcygwin -DDP -Wall -W -Wno-unused-parameter -Wold-st
yle-cast -O3 -DNoRepository -ftemplate-depth-30 -I/home/Luca/OpenFOAM/OpenFOAM-
1.4/src/mico-2.3.12/platforms/cygwinGcc4DPOpt/include -I/home/Luca/OpenFOAM/Ope
nFOAM-1.4/src/OpenFOAM/lnInclude -IlnInclude -I. -c $SOURCE -o Make/cygwinGcc
4DPOpt/FoamX.o
In file included from lnInclude/FoamX.H:8,
from FoamX.C:8:
/home/Luca/OpenFOAM/OpenFOAM-1.4/src/mico-2.3.12/platforms/cygwinGcc4DPOpt/inclu
de/CORBA.h:146:26: error: mico/version.h: No such file or directory
/home/Luca/OpenFOAM/OpenFOAM-1.4/src/mico-2.3.12/platforms/cygwinGcc4DPOpt/inclu
de/CORBA.h:147:24: error: mico/types.h: No such file or directory
/home/Luca/OpenFOAM/OpenFOAM-1.4/src/mico-2.3.12/platforms/cygwinGcc4DPOpt/inclu
de/CORBA.h:151:27: error: mico/template.h: No such file or directory
make: *** [Make/cygwinGcc4DPOpt/FoamX.o] Interrupt

7islands October 27, 2007 11:48

Hi, So CORBA.h exists but mic
 
Hi,
So CORBA.h exists but mico/version.h etc. don't under mico-2.3.12/platforms/cygwinGcc4DPOpt/include... quite strange. Could you this time go to
OpenFOAM-1.4/src/mico-2.3.12/include
, run
make install
and see what happens?

Takuya

7islands October 27, 2007 11:57

The point is that the mico, mi
 
The point is that the mico, ministl and coss subdirectories under OpenFOAM-1.4/src/mico-2.3.12/include/ should be copied into OpenFOAM-1.4/src/mico-2.3.12/platforms/cygwinGcc4DPOpt/include by make install. If make install doesn't work for some reason, could you try it manually?

Takuya

fugu October 27, 2007 14:00

I ran make install in OpenFOAM
 
I ran make install in OpenFOAM-1.4/src/mico-2.3.12/include
now I have coss mico e minstall under
OpenFOAM-1.4/src/mico-2.3.12/platforms/cygwinGcc4DPOpt/include
Now when I start foamx I get this message:
Starting NameServer with inet:pluto:1234 ...
uncaught MICO exception: IDL:omg.org/CORBA/INITIALIZE:1.0 (0, not-completed)
7 [sig] nsd 31152 C:\cygwin\home\Luca\OpenFOAM\OpenFOAM-1.4\src\mico-2.3.1
2\platforms\cygwinGcc4DPOpt\bin\nsd.exe: *** fatal error - called with threadlis
t_ix -1
/home/Luca/OpenFOAM/OpenFOAM-1.4/bin/runFoamXHB: line 149: 31152 Hangup
nsd -ORBIIOPAddr $myIOP --ior $FOAMX_CONFIG/ns.ref < /dev/null

7islands October 27, 2007 19:11

Hi, I'm afraid you ran into a
 
Hi,
I'm afraid you ran into a problem to which no one have a concrete solution.
My suggestions are
* double-check if you really installed openssh and its dependencies (openssl, minires, etc)
* search this forum with "uncaught MICO exception".

Takuya

fugu October 28, 2007 18:32

Takuya, thank you very much f
 
Takuya,
thank you very much for your help.
I was finally able to run foamx. Here is what I did:
I figured out that inetd wasn't working properly on my machine so no rsh and no foamx! I had inetd reinstalled, reconfigured the /etc files by running iu-config, edited the /etc/passwd file and finally re-installed the service following
http://www.mail-archive.com/cygwin@cygwin.com/msg81912.html

Then I reran the make install in
mico-2.3.12/platforms/cygwinGcc4DPOpt/include
following your instructions and recompiled foamx by running ./Allwmake in
~/openFoam/OpenFOAM-1.4/applications/utilities/preProcessing/FoamX
at this point I had it working... or at least the application window appeared.

By the way, during my wanderings I also figured out that the ping test performed in foamInstallationTest doesn't work on cygwing installation based on non-english operating system since it tests for a "received" substring in the response. Also the rsh and ssh tests use a telnet on port 22 and 222 that did not work on my machine even though rsh is actually working fine.

Hope this might help somebody else.

Luca

7islands November 4, 2007 07:46

OK those who would like to run
 
OK those who would like to run the ping test with foamInstallationTest under a non-English environment might want to try this patch http://www.cfd-online.com/OpenFOAM_D...hment_icon.gif foamInstallationTest.diff after installing Cygwin's ping by its setup.exe.

To be honest I ported foamInstallationTest rather for fun and never thought of its serious usage http://www.cfd-online.com/OpenFOAM_D...lipart/sad.gif.

Takuya

7islands November 4, 2007 09:40

Now I would like to mention th
 
Now I would like to mention that I started some preparatory studies on porting OpenFOAM to Interix, also konwn as SFU (Windows Services for Unix) or SUA (Subsystem for Unix-based Applications). The reasons I'm attracted to Interix are
  • Interix performs a lot better in I/O operations,
  • The interix I/O subsystem postulates to be set up as case sensitive (I know Cygwin also support case sensitive file handling through managed mount but it's not a usual custom),
  • Interix is Microsoft's genuine unix-like environment, which might be important to institutional users.
As of now I'm in a stage that I just barely bootstrapped gcc-4.2.2 on Interix, whose C++ and Fortran parts turned out to be mostly broken. I will open another thread regarding this project with some detailed discussions, if I can get GCC to reasonably work.

Takuya

luca_g November 20, 2007 12:23

Dear Cygwin users, I've rec
 
Dear Cygwin users,

I've recently installed OpenFOAM-1.4-3.cygwin and I wanted to try setting up a cluster of Windows PCs. Despite a few attempts I couldn't run any parallel case using LAM/MPI, and the lam system itself seemed to me not very stable.
In fact, I tried running a few of the simple examples provided with the LAM/MPI distribution and, although they worked, the lam net was crashing after launching the same code a few (2 or 3) times consecutively (i.e. without lamwiping and lambooting again each time). As far as OpenFOAM is concerned, the parallel case was starting but crashing at the first time step.

I absolutely don't mean that LAM/MPI or the OpenFOAM+LAM distribution do not work, but that I probably made some mistakes during the installation which I couldn't correct and solve.

Thus, I looked around and decided to try MPICH2.
I downloaded the source of the latest UNIX distribution (mpich2-1.0.6p1), compiled and installed it on Cygwin straightforward, run the same few example (never crashing now!) and then turned to make OpenFOAM working with MPICH2.

After a few attempts it seems that I now managed to correct all the few scripts (bashrc, Allwmake and options files) which need changes for the OpenFOAM Cygwin distribution to (optionally) compile and run with MPICH2 and I'm now running a few small cases on my cluster. Very happy, indeed !!
I'll try to understand things a bit better and later report about the performances obtained.

In case anybody (Petr, Takuya ?) would like, I could provide the patched files to allow choosing either a LAM or MPICH2 installation.
I still have to look at the FoamX stuff however.

Luca

7islands November 20, 2007 19:45

Hi Luca, Although I myself us
 
Hi Luca,
Although I myself usually don't do parallel runs it would be so nice if you post your patch here since the quality of the Windows port is always my concern, and most of all, it will help others who may be silently giving up running the Cygwin version in parallel without leaving any messages here...

As to the FoamX-stuff, as usually suggested in this forum I also suggest you learn how to get your jobs done without FoamX rather than wasting your time getting FoamX to work... although reading your posts it must already have been quite a lot of investment in time to you.

Takuya

pvita November 21, 2007 03:40

Greetings Luca! Congratulat
 
Greetings Luca!

Congratulations on porting under MPICH2. Feel free to post here your patch against 1.4-3 port release. I will check it, merge and release as 1.4-4.

Sincerely Yours,
PV

luca_g November 30, 2007 12:17

Dear All, I spent a little
 
Dear All,

I spent a little more time to better check the MPICH2 package and test some of its compile options: I'm now happy with it and I've been running parallel processes on 1, 2 or 4 PCs (either P4 Hyperthreading or Dual Core).

I'll report in a different post about the results but it seems that even on one single PC it might be worth running a parallel job with 2-4 process: this way I've got up to 30% improvement on both P4 and Dual Core (for 0.5M cells).

Attached here is a tar with all the patched files and a readme with installation instructions and a few comments.

Happy parallel computing !

Regards,
Luca

http://www.cfd-online.com/OpenFOAM_D...hment_icon.gif OpenFOAM-1.4_MPICH2_patch.tgz
http://www.cfd-online.com/OpenFOAM_D...s/mime_txt.gif README_MPICH2.txt

erazz December 17, 2007 09:15

Hello, I'm having trouble g
 
Hello,

I'm having trouble getting FoamX and paraFoam to run. I've run out of ideas so I'm hoping you could help me.

As far as I can tell there are a couple of things going wrong with the build:
1) Allwmake under OpenFOAM-1.4/src/malloc is not compiling properly. The error is:
fbsdmalloc.c:866: error: 'MADV_DONTNEED' undeclared (first use in this function)

2) later on mico-2.3.12 is not compiling. The configuration log lists a couple of definition files missing and only the first two libraries are being compiled. The third one exits with an error.

3) None of the FoamX binaries have been compiled and I'm guessing that it's because of this as well.

rsh works fine on my machine.
The solvers and blockmesh also work well. (I really appreciate this port since I do my cad work on Win and switching between OS's is not fun http://www.cfd-online.com/OpenFOAM_D...part/happy.gif)

All of this is on WinXP with a 686 processor.
OpenFOAM-1.4-3.cygwin.src.tar.bz2
gcc-4.1.2-cygwin.i686.tar.bz2
JAVA JDK 1.6.0_03
Cygwin 1.5.24-2

Any idea on what could be going wrong or how to check?
Thanks,
Erez

7islands December 17, 2007 10:09

Hi Erez, 1) It's a bit strang
 
Hi Erez,
1) It's a bit strange that src/malloc/Allwmake is being run since in src/Allwmake the corresponding line is commented out by an if-clause.
if ! [ "$WM_ARCH" = "cygwin" ]
then
(cd malloc ; ./Allwmake)
fi

Maybe WM_ARCH is not set properly?

2) I might (or might not) be able to give some suggestions if you post the log here.

3) Your guess is right, the FoamX binaries will not be built unless the MICO library is built.

Takuya

erazz December 17, 2007 10:45

Hi Takuya, My bad. Didn't
 
Hi Takuya,

My bad. Didn't see that ! sign http://www.cfd-online.com/OpenFOAM_D...part/happy.gif
That of course would explain why I couldn't compile it. (I tried to compile it myself)

But still I can't compile MICO.

Here's the error I get after running make:
../include/mico/os-misc.h:286: error: declaration of C function 'int gettimeofday(timeval*, timezone*)' conflicts with /usr/include/sys/time.h:73: error: previous declaration 'int gettimeofday(timeval*, void*)' here
make[1]: *** [os-unix.o] Error 1
make: *** [system] Error 1

Would it be possible to lift these libraries from another build? Either from a linux distro build of OpenFOAM or from the binaries of the 1.3 Cygwin build?

Thanks,
Erez

7islands December 17, 2007 19:13

Hi, Although I have never tri
 
Hi,
Although I have never tried, the 1.3 FoamX binaries might work with 1.4. The binaries can be downloaded from here.
Note that the binary distribution doesn't contain the MICO libraries since they are statically linked into the FoamX binaries.

Takuya


All times are GMT -4. The time now is 19:01.