Skip to content

Conversation

@janekmi
Copy link
Contributor

@janekmi janekmi commented Feb 9, 2026

... PMEMOBJ pools

PMEMOBJ maintains its own metadata. Copy-on-Write prevents these changes from taking effect so read-only mode will be truly read-only.

Steps for the author:

  • Commit message follows the guidelines.
  • Appropriate Features or Test-tag pragmas were used.
  • Appropriate Functional Test Stages were run.
  • At least two positive code reviews including at least one code owner from each category referenced in the PR.
  • Testing is complete. If necessary, forced-landing label added and a reason added in a comment.

After all prior steps are complete:

  • Gatekeeper requested (daos-gatekeeper added as a reviewer).

…EMOBJ pools

PMEMOBJ maintains its own metadata. Copy-on-Write prevents these changes from
taking effect so read-only mode will be truly read-only.

Signed-off-by: Jan Michalski <jan-marian.michalski@hpe.com>
@github-actions
Copy link

github-actions bot commented Feb 9, 2026

Ticket title is 'Opening a VOS file in read only mode with DDB is not safe'
Status is 'In Review'
Labels: 'scrubbed_2.8'
https://daosio.atlassian.net/browse/DAOS-16964

@knard38
Copy link
Contributor

knard38 commented Feb 10, 2026

LGTM.

This patch was manually tested and the vos file are indeed not updated any more when opened in read only.
image

Without this patch, the md5sum is not the same with the same use case.
image

Copy link
Contributor

@knard38 knard38 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

/* Open and close a pool for a ddb_ctx */
int
dv_pool_open(const char *path, const char *db_path, daos_handle_t *poh, uint32_t flags);
dv_pool_open(const char *path, const char *db_path, daos_handle_t *poh, uint32_t flags, bool cow);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does "cow" mean?

dv_pool_open(const char *path, const char *db_path, daos_handle_t *poh, uint32_t flags, bool read_only);

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants