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

[OpenFOAM.com] RPM installation OpenFOAM-v1812 on OpenSUSE 15.0

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 25, 2019, 20:37
Default RPM installation OpenFOAM-v1812 on OpenSUSE 15.0
  #1
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Hello, dear visitors of the forum. My question is about installing OpenFOAM-v1812 on OpenSUSE 15.0. On the page https://www.openfoam.com/download/in...nary-linux.php brief instructions for installing from RPM packages. With YaST, the installation went to the / opt / openfoam-1812 directory. What's next? How does the program run? I did not find the startOpenFOAM script at / opt / openfoam-1812 / ... Maybe the program is not installed and need additional settings?
Tell me please. For me, this is all for the first time (both OpenFOAM and Linux)
RoPr is offline   Reply With Quote

Old   February 26, 2019, 18:15
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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: How did they forget to write that on the instructions page...

OK, if the path you've reported is correct, then you can add the following line to your "~/.bashrc" file:
Code:
source /opt/openfoam-1812/etc/bashrc
edit: I've reported this issue here: https://develop.openfoam.com/Develop...us/issues/1218
__________________

Last edited by wyldckat; February 26, 2019 at 18:18. Reason: see "edit:"
wyldckat is offline   Reply With Quote

Old   February 26, 2019, 20:51
Default
  #3
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Hello, dear wyldckat. Thanks for your reply. I inserted this line at the end of the contents of the file opt/openfoam/etc/bashrc:
.

.

.

# Finalize setup of OpenFOAM environment for POSIX shell
if [ -d "$WM_PROJECT_DIR" ]
then
if [ -n "$FOAM_VERBOSE" ] && [ -n "$PS1" ]
then
echo "source $WM_PROJECT_DIR/etc/config.sh/setup" 1>&2
fi
. "$WM_PROJECT_DIR/etc/config.sh/setup" "$@"
else
echo "Error: did not locate installation path for $WM_PROJECT-$WM_PROJECT_VERSION" 1>&2
echo "No directory: $WM_PROJECT_DIR" 1>&2
fi

# Cleanup variables (done as final statement for a clean exit code)
unset foamOldDirs projectDir

#------------------------------------------------------------------------------
source /opt/openfoam-1812/etc/bashrc


Then press save. Then I switch to the terminal, enter the "simpleFoam -help", but nothing happens:


roman@linux-ijwm:~> simpleFoam -help
If 'simpleFoam' is not a typo you can use command-not-found to lookup the package that contains it, like this:
cnf simpleFoam



You also write "~/.bashrc". It means that the file bashrc needs to be copied from the directory /opt to the /home directory? I tried it, but it also doesn't help
How does the environment OpenFOAM run in general (from Console)?
RoPr is offline   Reply With Quote

Old   February 27, 2019, 18:50
Default
  #4
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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 answers:
Quote:
Originally Posted by RoPr View Post
I inserted this line at the end of the contents of the file opt/openfoam/etc/bashrc:
No, no, no, no... I indicated that you have to add the line to "~/.bashrc"... what you did was add the line to the file you were meant to source... I should have pointed you to some reading material, so that you could learn what the "source" command does...

Please read the following wiki page for more details: https://openfoamwiki.net/index.php/I...with_the_Shell

Quote:
Originally Posted by RoPr View Post
You also write "~/.bashrc". It means that the file bashrc needs to be copied from the directory /opt to the /home directory? I tried it, but it also doesn't help
How does the environment OpenFOAM run in general (from Console)?
No...

Please edit the file "/opt/openfoam-1812/etc/bashrc" and remove the line you added at the bottom of it.


Then follow these steps and instructions:
  1. The "~" is a short hand denomination for your personal home folder. If you run this command in the terminal:
    Code:
    cd ~
    it will go into your own home folder.
    You can confirm this by running:
    Code:
    pwd
  2. In there you can find the file ".bashrc". You can see it by running this command:
    Code:
    ls -la .bashrc
    this is because the files that start with a dot "." are interpreted as hidden files on Linux.
  3. Therefore, the idea is that you should edit the file "~/.bashrc" and add the source command in there. So, if you run this command:
    Code:
    gedit ~/.bashrc
    assuming that gedit is a text editor that is installed in your system, it will open the file "~/.bashrc" in the text editor.
  4. Then at the end of the file that is opened in the text editor, add this line:
    Code:
    source /opt/openfoam-1812/etc/bashrc
  5. Next, save and close the file.
  6. Now, whenever you start a new terminal, it will load the OpenFOAM shell environment automatically. This is because the "~/.bashrc" file is sourced by Bash automatically, which will in turn source OpenFOAM's "/opt/openfoam-1812/etc/bashrc" file.
  7. Uh... I forgot to explain before, but the "source" command will run automatically in the current terminal, all of the lines that are inside the script we give it. That is why it's called "source", in the sense that:
    Quote:
    please use the following script as the source code for all of the commands that I want to run next
__________________
wyldckat is offline   Reply With Quote

Old   February 28, 2019, 02:29
Default
  #5
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
I used a text editor Kate, i.e.:


kate ~/.bashrc

This .bashrc file content:


# Sample .bashrc for SuSE Linux
# Copyright (c) SuSE GmbH Nuernberg

# There are 3 different types of shells in bash: the login shell, normal shell
# and interactive shell. Login shells read ~/.profile and interactive shells
# read ~/.bashrc; in our setup, /etc/profile sources ~/.bashrc - thus all
# settings made here will also take effect in a login shell.
#
# NOTE: It is recommended to make language settings in ~/.profile rather than
# here, since multilingual X sessions would not work properly if LANG is over-
# ridden in every subshell.

# Some applications read the EDITOR variable to determine your favourite text
# editor. So uncomment the line below and enter the editor of your choice :-)
#export EDITOR=/usr/bin/vim
#export EDITOR=/usr/bin/mcedit

# For some news readers it makes sense to specify the NEWSSERVER variable here
#export NEWSSERVER=your.news.server

# If you want to use a Palm device with Linux, uncomment the two lines below.
# For some (older) Palm Pilots, you might need to set a lower baud rate
# e.g. 57600 or 38400; lowest is 9600 (very slow!)
#
#export PILOTPORT=/dev/pilot
#export PILOTRATE=115200

test -s ~/.alias && . ~/.alias || true
source /opt/openfoam-1812/etc/bashrc


Then I run a new terminal window and see:

mpicc: command not found
roman@linux-ijwm:~>


Testing with the "simpleFoam -help" command doesn't work:


mpicc: command not found
roman@linux-ijwm:~> simpleFoam -help
simpleFoam: error while loading shared libraries: libmpi.so.12: cannot open shared object file: No such file or directory
roman@linux-ijwm:~>
RoPr is offline   Reply With Quote

Old   February 28, 2019, 05:52
Default
  #6
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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: OK, you're close to having it work. Please run the following commands:
Code:
mpi-selector --set openmpi
source /etc/profile.d/mpi-selector.sh
source ~/.bashrc
simpleFoam -help

If the last command now gives you a help list instead of complaining about missing MPI, then edit the "~/.bashrc" file and change the last line to this:
Code:
source /etc/profile.d/mpi-selector.sh
source /opt/openfoam-1812/etc/bashrc
This way it will load in the Open-MPI into the shell environment, so that OpenFOAM can then use it.
wyldckat is offline   Reply With Quote

Old   February 28, 2019, 23:02
Default
  #7
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Hello, dear Bruno Santos. I did everything as you said. But the situation repeats.
This is the end of the file .bashrc now:

.
.

test -s ~/.alias && . ~/.alias || true
source /etc/profile.d/mpi-selector.sh
source /opt/openfoam-1812/etc/bashrc


This is a new terminal window:


mpicc: command not found
roman@linux-ijwm:~> mpi-selector --set openmpi (this is a repeat of my actions)
Defaults already exist; overwrite them? (y/N) y
roman@linux-ijwm:~> source /etc/profile.d/mpi-selector.sh
roman@linux-ijwm:~> source ~/.bashrc
mpicc: command not found
roman@linux-ijwm:~> simpleFoam -help

Usage: simpleFoam [OPTIONS]
Options:
-case <dir> Specify case directory to use (instead of the cwd)
-decomposeParDict <file>
Use specified file for decomposePar dictionary
-dry-run Check case set-up only using a single time step
-dry-run-write Check case set-up and write only using a single time step
-noFunctionObjects
Do not execute function objects
-parallel Run in parallel
-postProcess Execute functionObjects only
-doc Display documentation in browser
-doc-source Display source code in browser
-help Display short help and exit
-help-full Display full help and exit

Steady-state solver for incompressible, turbulent flows.

Using: OpenFOAM-1812 (1812) (see www.OpenFOAM.com)
Build: 1812
Arch: LSB;label=32;scalar=64

roman@linux-ijwm:~> kate ~/.bashrc
roman@linux-ijwm:~>exit



New terminal:
mpicc: command not found
roman@linux-ijwm:~>



... and so on
RoPr is offline   Reply With Quote

Old   March 1, 2019, 20:05
Default
  #8
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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: As root, run the following command:
Code:
zypper install openmpi-devel
It's the package that is missing and is necessary for mpicc to be installed.
wyldckat is offline   Reply With Quote

Old   March 3, 2019, 21:26
Default
  #9
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Hello, dear Bruno Santos. Thanks for your help. I did everything as you said.

Terminal:

Code:
mpicc: command not found
roman@linux-ijwm:~> sudo -s
[sudo] пароль для root: 
linux-ijwm:/home/roman # zypper install openmpi-devel
Retrieving repository 'openSUSE:Leap:15.0:Ports' metadata ...............................................................................................................................[error]
Repository 'openSUSE:Leap:15.0:Ports' is invalid.
[http-download.opensuse.org-96515465|http://download.opensuse.org/reposit.../Ports/ports/] Valid metadata not found at specified URL
Please check if the URIs defined for this repository are pointing to a valid repository.
Warning: Skipping repository 'openSUSE:Leap:15.0:Ports' because of the above error.
Some of the repositories have not been refreshed because of an error.
Loading repository data...
Reading installed packages...
Resolving package dependencies...

The following 8 NEW packages are going to be installed:
  glibc-devel libibumad3 libstdc++-devel libstdc++6-devel-gcc7 linux-glibc-devel openmpi-devel rdma-core-devel rsocket

8 new packages to install.
Overall download size: 13.6 MiB. Already cached: 0 B. After the operation, additional 53.1 MiB will be used.
Continue? [y/n/...? shows all options] (y): y
.
.
.
In general, the package "openmpi-devel-1.10.7-lp150.9.3.1.x86_64" was installed.
New terminal:

Code:
roman@linux-ijwm:~> icoFoam -help

Usage: icoFoam [OPTIONS]
Options:
  -case <dir>       Specify case directory to use (instead of the cwd)
  -decomposeParDict <file>
                    Use specified file for decomposePar dictionary
  -dry-run          Check case set-up only using a single time step
  -dry-run-write    Check case set-up and write only using a single time step
  -noFunctionObjects
                    Do not execute function objects
  -parallel         Run in parallel
  -doc              Display documentation in browser
  -doc-source       Display source code in browser
  -help             Display short help and exit
  -help-full        Display full help and exit

Transient solver for incompressible, laminar flow of Newtonian fluids.

Using: OpenFOAM-1812 (1812) (see www.OpenFOAM.com)
Build: 1812
Arch:  LSB;label=32;scalar=64
It's all good, but others post-compillation steps didn't work:

Code:
roman@linux-ijwm:~> foamInstallationTest
Executing /opt/openfoam-1812/bin/foamInstallationTest:


Basic setup :
-------------------------------------------------------------------------------

FATAL ERROR: OpenFOAM environment not configured.

    Please follow the download and installation link in README.html:
    <OpenFOAM installation dir>/OpenFOAM-1812/README.html
    for information on setting-up the OpenFOAM environment.
Code:
 roman@linux-ijwm:~> mkdir -p $FOAM_RUN
(Test the installation with a simple tutorial)
Code:
 roman@linux-ijwm:~> run
roman@linux-ijwm:~/OpenFOAM/roman-1812/run> cp -r $FOAM_TUTORIALS/incompressible/simpleFoam/pitzDaily ./
cp: failed to perform stat for '/opt/openfoam-1812/tutorials/incompressible/simpleFoam/pitzDaily': There is no such file or directory.
roman@linux-ijwm:~/OpenFOAM/roman-1812/run> cd pitzDaily
bash: cd: pitzDaily: There is no such file or directory.
roman@linux-ijwm:~/OpenFOAM/roman-1812/run> blockMesh
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  1812                                  |
|   \\  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : 1812 OPENFOAM=1812
Arch   : "LSB;label=32;scalar=64"
Exec   : blockMesh
Date   : Mar 04 2019
Time   : 09:38:43
Host   : linux-ijwm
PID    : 6092
I/O    : uncollated
Case   : /home/roman/OpenFOAM/roman-1812/run
nProcs : 1
trapFpe: Floating point exception trapping enabled (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster (fileModificationSkew 10)
allowSystemOperations : Allowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time



--> FOAM FATAL ERROR: 
cannot find file "/home/roman/OpenFOAM/roman-1812/run/system/controlDict"

    From function virtual Foam::autoPtr<Foam::ISstream> Foam::fileOperations::uncollatedFileOperation::readStream(Foam::regIOobject&, const Foam::fileName&, const Foam::word&, bool) const
    in file global/fileOperations/uncollatedFileOperation/uncollatedFileOperation.C at line 532.

FOAM exiting
Code:
roman@linux-ijwm:~/OpenFOAM/roman-1812/run> simpleFoam
/*---------------------------------------------------------------------------*\
| =========                 |                                                 |
| \\      /  F ield         | OpenFOAM: The Open Source CFD Toolbox           |
|  \\    /   O peration     | Version:  1812                                  |
|   \\  /    A nd           | Web:      www.OpenFOAM.com                      |
|    \\/     M anipulation  |                                                 |
\*---------------------------------------------------------------------------*/
Build  : 1812 OPENFOAM=1812
Arch   : "LSB;label=32;scalar=64"
Exec   : simpleFoam
Date   : Mar 04 2019
Time   : 09:39:05
Host   : linux-ijwm
PID    : 6094
I/O    : uncollated
Case   : /home/roman/OpenFOAM/roman-1812/run
nProcs : 1
trapFpe: Floating point exception trapping enabled (FOAM_SIGFPE).
fileModificationChecking : Monitoring run-time modified files using timeStampMaster (fileModificationSkew 10)
allowSystemOperations : Allowing user-supplied system call operations

// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
Create time



--> FOAM FATAL ERROR: 
cannot find file "/home/roman/OpenFOAM/roman-1812/run/system/controlDict"

    From function virtual Foam::autoPtr<Foam::ISstream> Foam::fileOperations::uncollatedFileOperation::readStream(Foam::regIOobject&, const Foam::fileName&, const Foam::word&, bool) const
    in file global/fileOperations/uncollatedFileOperation/uncollatedFileOperation.C at line 532.

FOAM exiting
Paraview:


Code:
roman@linux-ijwm:~/OpenFOAM/roman-1812/run> paraFoam
Cannot use ParaView reader module library (PVFoamReader)
The PV_PLUGIN_PATH environment value is not set

Continuing with builtin reader:  paraFoam -vtk

Created temporary 'run.foam'
/opt/openfoam-1812/bin/paraFoam: line 324: paraview: command not found
roman@linux-ijwm:~/OpenFOAM/roman-1812/run>
"Paraview" is also not installed, although I thought it was included.

Last edited by wyldckat; March 4, 2019 at 17:13. Reason: Added [CODE][/CODE] markers
RoPr is offline   Reply With Quote

Old   March 4, 2019, 18:00
Default
  #10
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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 answers:
  1. I believe you can ignore what foamInstallationTest states, given that this was an RPM based installation, which should be fully operational and no further testing should be needed.
  2. Now I see mixed results in what you've gotten... Oh, I see, the problem is that there are additional packages that need to be installed... Here is a list of the packages to be installed to get everything from OpenFOAM:
    Code:
    zypper install openfoam1812 openfoam1812-doc openfoam1812-examples openfoam1812-modules openfoam-selector
    In your case, you are missing the package "openfoam1812-examples".
wyldckat is offline   Reply With Quote

Old   March 4, 2019, 20:10
Default
  #11
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Thank you very much! OpenFOAM works. In spite of the fact that in the /opt directory there are files associated with ParaVIEW, it doesn't start from the shell:
Code:
.
.
.
SIMPLE solution converged in 283 iterations

streamLine streamlines write:
    seeded 10 particles
    Tracks:10
    Total samples:10885
    Writing data to "/home/roman/OpenFOAM/roman-1812/run/pitzDaily/postProcessing/sets/streamlines/283"
End

roman@linux-ijwm:~/OpenFOAM/roman-1812/run/pitzDaily> paraFoam
Cannot use ParaView reader module library (PVFoamReader)
The PV_PLUGIN_PATH environment value is not set

Continuing with builtin reader:  paraFoam -vtk

Created temporary 'pitzDaily.foam'
/opt/openfoam-1812/bin/paraFoam: line 324: paraview: command not found
roman@linux-ijwm:~/OpenFOAM/roman-1812/run/pitzDaily>

Last edited by wyldckat; March 5, 2019 at 18:09. Reason: Added [CODE][/CODE] markers
RoPr is offline   Reply With Quote

Old   March 5, 2019, 18:12
Default
  #12
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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
As mentioned in the original page you pointed to, the idea is to use the Scotch and ParaView RPM packages that already exist in the Science repository.
Since Scotch is installed automatically along with OpenFOAM (I think it is...), then you just need to install ParaView manually:
Code:
zypper install paraview
However, this also means that it will not have OpenFOAM's own reader and will instead rely on ParaView's builtin reader.
wyldckat is offline   Reply With Quote

Old   March 5, 2019, 21:46
Default
  #13
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Thank you very much. ParaVIEW has been successfully installed, but it run with the following comments:


roman@linux-ijwm:~/OpenFOAM/roman-1812/run/pitzDaily> paraFoam
Cannot use ParaView reader module library (PVFoamReader)
The PV_PLUGIN_PATH environment value is not set

Continuing with builtin reader: paraFoam -vtk

Created temporary 'pitzDaily.foam'

It's important? Because the visualization of tutorial simple calculations was successful. If I run the program with the help of the paraview command, the calculation results cannot be read:


roman@linux-ijwm:~/OpenFOAM/roman-1812/run/pitzDaily> paraview
File ' "/home/roman/OpenFOAM/roman-1812/run/pitzDaily/pitzDaily.foam" ' cannot be read.
ERROR: In /home/abuild/rpmbuild/BUILD/ParaView-v5.6.0/VTK/Common/ExecutionModel/vtkExecutive.cxx, line 782
vtkPVCompositeDataPipeline (0x562dc76ef160): Algorithm vtkAMReXParticlesReader(0x562dc7543ff0) returned failure for request: vtkInformation (0x562dc76f7e40)
Debug: Off
Modified Time: 220506
Reference Count: 1
Registered Events: (none)
Request: REQUEST_INFORMATION
ALGORITHM_AFTER_FORWARD: 1
FORWARD_DIRECTION: 0



Can I ask any questions on this forum about settings of interaction between OpenFOAM and external pre- and post-processors (for example, SALOME, which include ParaVIEW)?
RoPr is offline   Reply With Quote

Old   March 6, 2019, 19:30
Default
  #14
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,962
Blog Entries: 45
Rep Power: 125
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 answers:
  1. ParaView can only open a file that exists. From the error message that you posted, I guess that the file didn't exist when you tried to open it in ParaView?
    1. If you run:
      Code:
      paraFoam -help
      you'll get additional information.
    2. If you run:
      Code:
      paraFoam -vtk -touch
      it will create the ".foam" file for your case, which you can then open manually in ParaView.
  2. Where to ask questions related to OpenFOAM is explained here, which outlines the map of the forum: Map of the OpenFOAM Forum - Understanding where to post your questions!
wyldckat is offline   Reply With Quote

Old   March 6, 2019, 20:48
Default
  #15
New Member
 
Presnyakov Roman
Join Date: Feb 2019
Posts: 10
Rep Power: 4
RoPr is on a distinguished road
Thank you very much!
RoPr is offline   Reply With Quote

Old   June 26, 2019, 08:54
Default
  #16
New Member
 
Frédéric MR
Join Date: Jun 2019
Posts: 18
Rep Power: 4
FM_Stiral is on a distinguished road
Hello everybody,
This thread is very interesting, I had the same problems as RoPr.

Unfortunately, I have still problem when I want to install openfoam doc, examples, modules and selector. It seems the deposit 'openSUSE:LEAP:15.1:ARM' is not valid.


Does everyone know if there is a problem on servers? Is it due to the openSUSE version (15.1 instead of 15.0 in this thread). I don't have found a specific user guide to install openfoam on openSUSE15.1.


Thank you for your help.
FM_Stiral is offline   Reply With Quote

Old   June 27, 2019, 09:19
Default
  #17
New Member
 
Hafiz Ahmad
Join Date: May 2019
Location: Brunei
Posts: 17
Rep Power: 4
mdhfiz is on a distinguished road
Hello Stiral!

There’s probably nothing wrong with your repos. the rsync server is down as indicated by opensuse in their website. you can wait till it is fixed.

The science repo is working for me though, you should able to install the openfoam-xxxx
mdhfiz is offline   Reply With Quote

Old   May 17, 2021, 09:07
Default
  #18
New Member
 
Ashuthosh PS
Join Date: Apr 2020
Posts: 2
Rep Power: 0
Ashuthosh is on a distinguished road
Quote:
Originally Posted by RoPr View Post
I used a text editor Kate, i.e.:


kate ~/.bashrc

This .bashrc file content:


# Sample .bashrc for SuSE Linux
# Copyright (c) SuSE GmbH Nuernberg

# There are 3 different types of shells in bash: the login shell, normal shell
# and interactive shell. Login shells read ~/.profile and interactive shells
# read ~/.bashrc; in our setup, /etc/profile sources ~/.bashrc - thus all
# settings made here will also take effect in a login shell.
#
# NOTE: It is recommended to make language settings in ~/.profile rather than
# here, since multilingual X sessions would not work properly if LANG is over-
# ridden in every subshell.

# Some applications read the EDITOR variable to determine your favourite text
# editor. So uncomment the line below and enter the editor of your choice :-)
#export EDITOR=/usr/bin/vim
#export EDITOR=/usr/bin/mcedit

# For some news readers it makes sense to specify the NEWSSERVER variable here
#export NEWSSERVER=your.news.server

# If you want to use a Palm device with Linux, uncomment the two lines below.
# For some (older) Palm Pilots, you might need to set a lower baud rate
# e.g. 57600 or 38400; lowest is 9600 (very slow!)
#
#export PILOTPORT=/dev/pilot
#export PILOTRATE=115200

test -s ~/.alias && . ~/.alias || true
source /opt/openfoam-1812/etc/bashrc


Then I run a new terminal window and see:

mpicc: command not found
roman@linux-ijwm:~>


Testing with the "simpleFoam -help" command doesn't work:


mpicc: command not found
roman@linux-ijwm:~> simpleFoam -help
simpleFoam: error while loading shared libraries: libmpi.so.12: cannot open shared object file: No such file or directory
Quote:
Originally Posted by RoPr View Post
roman@linux-ijwm:~>





Just leaving another solution for anyone else that comes across the same problem. So basically I continued getting the mpicc: command not found even after installing the recommended mpi packages. So I ended up making the following changes to the bashrc file located at $WM_PROJECT_DIR/etc/bashrc


export WM_MPLIB=SYSOPENMPI
to

export WM_MPLIB=OPENMPI
This enables Openfoam to use the built in libraries as oposed to the one installed in the system.


OpenFoam2012 (from the science repository) on openSUSE Tumbleweed.
Ashuthosh is offline   Reply With Quote

Old   May 18, 2021, 06:48
Default
  #19
Senior Member
 
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,279
Rep Power: 31
olesen will become famous soon enougholesen will become famous soon enough
Quote:
Originally Posted by Ashuthosh View Post
export WM_MPLIB=SYSOPENMPI
to


export WM_MPLIB=OPENMPI
This enables Openfoam to use the built in libraries as oposed to the one installed in the system.

OpenFoam2012 (from the science repository) on openSUSE Tumbleweed.

This is not only pretty strange, it is also not what I would recommend changing at all.
I don't know how exactly you have sourced things but normally, the mpicc command will not even be needed. During the RPM build, an additional file (etc/config.sh/prefs.sys-openmpi) is generated. It will have this type of content:


Code:
# etc/config.sh/prefs.sys-openmpi
#
# Packaging configured value for sys-openmpi
export MPI_ARCH_PATH="/usr/lib64/mpi/gcc/openmpi2"
#----
The exact location pointed to by MPI_ARCH_PATH will vary, depending on the opensuse version (older versions had ..../gcc/openmpi - ie, openmpi version1).


If this path is missing, or incorrect that could explain your problem. Only in that case does it actually use the mpicc command to determine paths. If mpicc is actually setup for you will depend on what you have done (or not) with the mpi-selector command in opensuse.


It is worth taking a further dig to see what has gone wrong. Simply changing the entry to "OPENMPI" like you have done indicates that you expect to be using openmpi from a ThirdParty installation that doesn't exist.
While your quick solution does remove the warning about not finding mpicc, you are unlikely to have much joy if you try to run anything in parallel. You will get the dummy stubs that all essentially emit error messages only.
olesen is offline   Reply With Quote

Old   May 19, 2021, 00:28
Default
  #20
New Member
 
Ashuthosh PS
Join Date: Apr 2020
Posts: 2
Rep Power: 0
Ashuthosh is on a distinguished road
You are right. Although I was able to remove the error message, it didn't actually solve the problem. I verified this by running a test parallel case.
What I did initially was based off of what I read here. (pg. 10)


I reverted the changes I made and used the mpi-selector to choose openmpi2. My prefs.sys-openmpi file is identical to yours. But now when I run this case I get the following error:


[hal9000:03673] *** An error occurred in MPI_Init_thread
[hal9000:03673] *** on a NULL communicator
[hal9000:03673] *** MPI_ERRORS_ARE_FATAL (processes in this communicator will now abort,
[hal9000:03673] *** and potentially your MPI job)
[hal9000:03674] *** An error occurred in MPI_Init_thread
[hal9000:03674] *** on a NULL communicator
[hal9000:03674] *** MPI_ERRORS_ARE_FATAL (processes in this communicator will now abort,
[hal9000:03674] *** and potentially your MPI job)
[hal9000:03675] *** An error occurred in MPI_Init_thread
[hal9000:03675] *** on a NULL communicator
[hal9000:03675] *** MPI_ERRORS_ARE_FATAL (processes in this communicator will now abort,
[hal9000:03675] *** and potentially your MPI job)
[hal9000:03672] *** An error occurred in MPI_Init_thread
[hal9000:03672] *** on a NULL communicator
[hal9000:03672] *** MPI_ERRORS_ARE_FATAL (processes in this communicator will now abort,
[hal9000:03672] *** and potentially your MPI job)
[hal9000:03672] Local abort before MPI_INIT completed completed successfully, but am not able to aggregate error messages, and not able to guarantee that all other processes were killed!
[hal9000:03673] Local abort before MPI_INIT completed completed successfully, but am not able to aggregate error messages, and not able to guarantee that all other processes were killed!
[hal9000:03674] Local abort before MPI_INIT completed completed successfully, but am not able to aggregate error messages, and not able to guarantee that all other processes were killed!
[hal9000:03675] Local abort before MPI_INIT completed completed successfully, but am not able to aggregate error messages, and not able to guarantee that all other processes were killed!
^C
[1]+ Exit 1 mpirun -np 4 interFoam -parallel > log.interFoam




I would really appreciate some help.


Edit: After a bit of tinkering, I've switched to a Debian based distribution and everything just works at the moment. I'll get back to this thread when I go back to tumbleweed in the future.

Last edited by Ashuthosh; May 20, 2021 at 01:51.
Ashuthosh 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
Map of the OpenFOAM Forum - Understanding where to post your questions! wyldckat OpenFOAM 10 September 2, 2021 05:29
[OpenFOAM.org] OpenFoam installation V6 on opensuse leap 15 sjohn2 OpenFOAM Installation 20 February 21, 2020 19:08
Walkthrough: Installation of OpenFOAM-1.6-ext on openSUSE 12.2 64-bit wenterodt OpenFOAM Installation 4 January 10, 2013 10:18
New OpenFOAM Forum Structure jola OpenFOAM 2 October 19, 2011 06:55
OpenFOAM 1.7.0 on OpenSUSE 11.1 Bufacchi OpenFOAM Installation 8 August 6, 2010 09:57


All times are GMT -4. The time now is 05:49.