Got error when use fork and exec to start up python executable inside gramine #1595
-
In my workflow, I need to use fork and execv in C++ code to create a gramine instance that runs a Python script, as shown in the code below:
There may be multiple (about 5) gramine instances running concurrently, and occasionally (maybe ten forks) there may be errors that cause the fork to fail, resulting in the following error report:
After diving into the source code in libos_vma.c:245:_vma_bkeep_remove, I found that the code that triggered the error is as follows:
I wonder how this happened and how to fix it. Any more detailed information will be provided if needed. Thanks a lot. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
It looks like a problem with the enclave size (I assume you're talking about Can you try to increase the Also, can you show your manifest file? |
Beta Was this translation helpful? Give feedback.
I think the randomness is because ASLR (Address Space Layout Randomization) is enabled in Gramine by default. Try
loader.insecure__disable_aslr = false
, and you'll see more consistent behavior.