CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Running, Solving & CFD

Error in pipleCyclic tutorial

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

Reply
 
LinkBack Thread Tools Display Modes
Old   July 31, 2013, 16:25
Default Error in pipleCyclic tutorial
  #1
New Member
 
Join Date: Jul 2013
Posts: 5
Rep Power: 3
elglanto is on a distinguished road
Hello,

I'm new with OpenFOAM so I'm running the different tutorials to have an understanding of it before using it for my own purpose.

I want to try the pipeCyclic exemple from the incompressibles simpleFoam cases.

After doing a blockMesh, a do a checkMesh to be sure everything is ok. But then, i get a:
Quote:
FOAM FATAL ERROR:
No times selected
Or course, if after i still try to run the case with the simpleFoam commande, i get an other error

As this is a exemple already in OpenFOAM, I assume there is no error in it so I'm doing something wrong there. An idea of what it ?
elglanto is offline   Reply With Quote

Old   July 31, 2013, 17:30
Default
  #2
Senior Member
 
Lieven
Join Date: Dec 2011
Location: Mol, Belgium
Posts: 295
Rep Power: 13
Lieven will become famous soon enough
Hi Elglanto,

You should have at least a '0'-folder in your case. I guess (don't have the tutorial on my pc here) that it has a 0.orig-folder instead. Simply run
Code:
cp -r 0.org 0
To solve the problem.

Cheers,

L

P.S.: If there is a Allrun script given in the case folder, it's best to use this to run the tutorial not to miss any essential steps.
Lieven is offline   Reply With Quote

Old   July 31, 2013, 18:58
Default
  #3
New Member
 
Join Date: Jul 2013
Posts: 5
Rep Power: 3
elglanto is on a distinguished road
Hello Lieven, thanks for your answer.

From what I understood, you mean that i should rename the 0.org folder to 0. Is that correct?

If it is, I already done that although I did it via the interface and not the terminal.

About the Allrun script, there is one which I tried after your message. From the clean case (keeping the 0.org) the Allrun script create the 0 file and a buch of others with similar names (log.blockMesh, log.simpleFoam, log.blabla etc.) but no directory at others times. Is that normal ? Because from what I understood, the Allrun script should run the entire case.
elglanto is offline   Reply With Quote

Old   August 1, 2013, 06:32
Default
  #4
Senior Member
 
Lieven
Join Date: Dec 2011
Location: Mol, Belgium
Posts: 295
Rep Power: 13
Lieven will become famous soon enough
Hi Elglanto,

It all depends on the settings in the controlDict. OF does not store every time step. The fact that it creates all the log-files proves that it is doing something. So open the log-files and try to understand what is happening. It can be two things:
1. The case runs perfectly but the settings in the controlDict do not ask to write the solution
2. An error occurred somewhere and then you will find a description of it in one of the log-files.

Could you maybe post the error you get when you run the simpleFoam command?

Cheers,

Lieven
Lieven is offline   Reply With Quote

Old   August 2, 2013, 16:38
Default
  #5
New Member
 
Join Date: Jul 2013
Posts: 5
Rep Power: 3
elglanto is on a distinguished road
Hello Lieven, here are the results of the tests I made. Between each tests, I delete the pipeCyclic folder case and copy a new one to start from fresh.

1st attempt

When i run a blockMesh command, I get the following error which I had previously:

Quote:
--> FOAM FATAL IO ERROR:
Loading a shared library using case-supplied code is not enabled by default
because of security issues. If you trust the code you can enable this
facility be adding to the InfoSwitches setting in the system controlDict:

allowSystemOperations 1

The system controlDict is either

~/.OpenFOAM/$WM_PROJECT_VERSION/controlDict

or

$WM_PROJECT_DIR/etc/controlDict



file: /home/xuv/OpenFOAM/xuv-2.2.1/run/pipeCyclic/constant/polyMesh/blockMeshDict from line 17 to line 23.

From function functionEntries::calcEntry::execute(..)
in file db/dynamicLibrary/dynamicCode/dynamicCode.C at line 81.

FOAM exiting
Thus, I change allowSystemOperations for 0 to 1 in the controlDict file located in /opt/openfoam221/etc

2nd attempt

Now, i don't see any errors when running the blockMesh command but if i run checkMesh, I get the following error:

Quote:
--> FOAM FATAL ERROR:
No times selected

From function checkMesh
in file db/Time/timeSelector.C at line 263.

FOAM exiting
And if I run the simpleFoam command, then it is the following error:

Quote:
--> FOAM FATAL IO ERROR:
cannot find file

file: /home/xuv/OpenFOAM/xuv-2.2.1/run/pipeCyclic/0/p at line 0.

From function regIOobject::readStream()
in file db/regIOobject/regIOobjectRead.C at line 73.

FOAM exiting
Thus, my guess is that this is normal since the time 0 folder is called 0.org, so i rename it 0

3rd attempt

With a clean case and 0.org renamed, I run the blockMesh command with no error, I check with checkMesh, no error so I run simpleFoam command and... it worked fine. Which means that on my very first attempt, before I opened the topic, I did something wrong. Now, i have three new time folders (100, 200, 229). But i still don't understand why the Allrun script didn't work.

But thanks a lot for your help.
elglanto is offline   Reply With Quote

Old   August 3, 2013, 08:00
Default
  #6
Senior Member
 
Nima Sam
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,123
Blog Entries: 1
Rep Power: 14
nimasam is on a distinguished road
Send a message via Yahoo to nimasam
well, you miss this command:
Quote:
cp -r 0.org 0
__________________
Training Course on OpenFOAM at (http://www.isme.ir/)
My Weblog (http://openfoam.blogfa.com/)
nimasam is offline   Reply With Quote

Old   August 3, 2013, 14:41
Default
  #7
New Member
 
Join Date: Jul 2013
Posts: 5
Rep Power: 3
elglanto is on a distinguished road
Hello,

actually, I did it by hand. I'm still not fully used to linux terminal.
elglanto is offline   Reply With Quote

Old   May 23, 2014, 00:27
Default
  #8
Member
 
Niu
Join Date: Apr 2014
Posts: 42
Rep Power: 3
Z.Q. Niu is on a distinguished road
Dear elglanto
Dear elglanto,
I want to test the pipeCyclic case, but when I run blockMesh, the error occurs:
Code:
 Creating block mesh from
    "/home/zq/desktop/tutorials/incompressible/simpleFoam/pipeCyclic/constant/polyMesh/blockMeshDict"
Using #calcEntry at line 26 in file "/home/zq/desktop/tutorials/incompressible/simpleFoam/pipeCyclic/constant/polyMesh/blockMeshDict"


--> FOAM FATAL IO ERROR: 
This code should not be executed by someone with administrator rights due to security reasons.
(it writes a shared library which then gets loaded using dlopen)

file: /home/zq/desktop/tutorials/incompressible/simpleFoam/pipeCyclic/constant/polyMesh/blockMeshDict from line 17 to line 23.
Did you have this problem?

Last edited by wyldckat; May 24, 2014 at 03:38. Reason: Added [CODE][/CODE]
Z.Q. Niu is offline   Reply With Quote

Old   May 24, 2014, 03:44
Default
  #9
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,253
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings Niu,

At first I was going to state that the problem was due to a missing flag, but then I re-read the error message and it clearly states that you're running with admin powers, i.e. running as root.
In other words, you probably used sudo or su to switch to root mode and this way you're taking the risk of accidentally damaging your system installation and loosing all of your work . You should use your normal user account to run the OpenFOAM cases.

I don't know why you're running as root, but this tutorial should work just fine if you run the script Allrun that should be present in that tutorial, which has all of the necessary steps for running that tutorial case. For more on the topic of "Allrun", please read this thread: What do the scripts Allrun do?

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   May 24, 2014, 09:29
Default
  #10
Member
 
Niu
Join Date: Apr 2014
Posts: 42
Rep Power: 3
Z.Q. Niu is on a distinguished road
Dear Bruno,
I can't execute any command of OF, because my OF2.2.0 was installed in root, so the "All run " didn't work, do you has any experience of running OF using normal account?

Best regards!

Z.Q. Niu
Z.Q. Niu is offline   Reply With Quote

Old   May 24, 2014, 13:07
Default
  #11
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,253
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Z.Q. Niu,

It's easier to help you if you can tell me which installation instructions you followed. Because this issue should be easily solved as soon as I know how you installed OpenFOAM.

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   May 24, 2014, 13:10
Default
  #12
Member
 
Niu
Join Date: Apr 2014
Posts: 42
Rep Power: 3
Z.Q. Niu is on a distinguished road
Dear Brunoi,
Thank you very much!I installed OF2.2.0 via a Deb package.
Z.Q. Niu is offline   Reply With Quote

Old   May 24, 2014, 13:27
Default
  #13
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,253
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Quote:
Originally Posted by Z.Q. Niu View Post
Thank you very much!I installed OF2.2.0 via a Deb package.
Try these steps:
  1. Start a new terminal as normal user.
  2. Run the following command:
    Code:
    source /opt/openfoam220/etc/bashrc
  3. If it didn't give an error, then run:
    Code:
    icoFoam -help
    which icoFoam
    It should give the help message for the icoFoam solver and also indicate where it was installed.
  4. If there was no error above, then run:
    Code:
    echo source /opt/openfoam220/etc/bashrc > ~/.bashrc
  5. Start a new terminal and run the commands in #3 again.
If at any point it gives you an error, let me know.




If there is no error, then you can restore the correct user permissions to the files located on your desktop folder, by following these steps:
  1. Switch to root mode:
    Code:
    sudo -s
  2. Change the ownership of the files and folders at "/home/zq/desktop" by running:
    Code:
    chown -R zq:zq /home/zq/desktop
    The first "zq" refers to your normal user name; the second "zq" refers to the group name. I believe that Ubuntu usually sets the group name to the same as the user name.
  3. Exit root mode:
    Code:
    exit
wyldckat is offline   Reply With Quote

Old   May 25, 2014, 07:35
Default
  #14
Member
 
Niu
Join Date: Apr 2014
Posts: 42
Rep Power: 3
Z.Q. Niu is on a distinguished road
Dear Bruno,
I followed your steps and finally got it! Thank you very much!

Best regards!

Z.Q. Niu
Z.Q. Niu is offline   Reply With Quote

Reply

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[ANSYS Meshing] I need tutorial files colorful ANSYS Meshing & Geometry 5 September 19, 2014 01:21
Tutorial for subcooled nucleate boiling Asghari FLUENT 34 September 27, 2013 04:58
Problem on Fluent Tutorial: Horizontal Film Boilig Feng FLUENT 2 April 13, 2013 05:34
[Virtualization] OpenFOAM oriented tutorial on using VMware Player - support thread wyldckat OpenFOAM Installation 2 July 11, 2012 16:01
Rotor/stator tutorial, and how to... gilberto CFX 5 January 21, 2002 10:41


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