-
Notifications
You must be signed in to change notification settings - Fork 510
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pmemobj_open failing to open file after it has been copied? #5886
Comments
Hi Matthieu (@mdorier) , |
After executing the program,
Is it possible that EDIT: for the version of PMDK, I'm using 1.12.1. I can't attach the code as it's embedded in a large codebase with lots of dependencies, but I can try to write a small reproducer if needed. |
Here is a reproducer:
I can confirm that if I call |
Please start your application with env |
Is there a way to change the UUID of a file? |
None of the PMDK tools and libraries support this directly. |
I have a tool that copies a PMEM pool from a server to another. In typical scenarios it doesn't pose any problem as the copy is received by a different process, but in the unit tests of the tool, the copy is received by the process that sends it and this is where the problem appears. I was just wondering if there was a way I could make that test work without having to fork a new process (which is often difficult in unit tests). In practice though I don't think I have a use for opening the copy on the same process. |
@mdorier , the best way would be to build some logic to copy data from one pool to another as part of the test setup. |
QUESTION: pmemobj_open fails to open file after it has been copied to another path?
Details
I have a code that creates a pmem pool using
pmemobj_create
, then writes and persists some data in it. It then copies the file to another path and usepmemobj_open
to open the file at its new path. I can confirm that, before the call topmemobj_open
, the copy has exactly the same content as the original, and the same file permissions. The only thing that changes is its path. The call topmemobj_open
to open the copied file fails, withpmemobj_errormsg()
returning "pool initialization failed". Additionally, after the call topmemobj_open
, the content of the file is different (some bytes have been changed). Any idea what the problem is?The text was updated successfully, but these errors were encountered: