Skip to content
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

Ensuring File Completeness Post-fsync with Shared CephFS Volume #10885

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

OdedViner
Copy link
Contributor

@OdedViner OdedViner commented Nov 18, 2024

@OdedViner OdedViner requested a review from a team as a code owner November 18, 2024 16:17
@pull-request-size pull-request-size bot added the size/M PR that changes 30-99 lines label Nov 18, 2024
Signed-off-by: Oded Viner <[email protected]>
Signed-off-by: Oded Viner <[email protected]>
@OdedViner OdedViner changed the title WIP: Ensuring File Completeness Post-fsync with Shared CephFS Volume Ensuring File Completeness Post-fsync with Shared CephFS Volume Nov 18, 2024
@PrasadDesala PrasadDesala added team/e2e E2E team related issues/PRs Customer defects Defects automated aspart of GSS closed loop labels Nov 19, 2024
pod_name = "cephfs-rwx-pod"
project_obj = helpers.create_project(project_name=project_name)
worker_node_names = get_worker_nodes()
teardown_project_factory(project_obj)

Choose a reason for hiding this comment

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

why is teardown called here?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is the method in our framework. After creating the namespace, we will delete all objects within the namespace and the namespace itself.

project_obj = helpers.create_project(project_name=project_name)
worker_node_names = get_worker_nodes()
teardown_project_factory(project_obj)
logger.info(

Choose a reason for hiding this comment

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

shouldn't this be printed after helpers.create_pvc succeds?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

changed the log:)

teardown_project_factory(project_obj)
logger.info(
f"Created new pvc sc_name={constants.CEPHFILESYSTEM_SC} namespace={project_name}, "
f"size=6Gi, access_mode={constants.ACCESS_MODE_RWO}"
Copy link
Contributor

Choose a reason for hiding this comment

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

This log message mentions the access mode constants.ACCESS_MODE_RWO, but the PVC is created with constants.ACCESS_MODE_RWX. Was this intentional?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed

pod_obj_client = helpers.create_pod(
pvc_name=pvc_obj.name,
namespace=project_obj.namespace,
interface_type=constants.CEPHBLOCKPOOL,
Copy link
Contributor

Choose a reason for hiding this comment

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

The PVC is created with constants.CEPHFILESYSTEM_SC, which refers to CephFS, but the pods are being created with constants.CEPHBLOCKPOOL as the interface_type, does it works?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed

$ oc get pvc -n cephfs-rwx-ns
NAME                                       STATUS   VOLUME                                     CAPACITY   ACCESS MODES   STORAGECLASS                VOLUMEATTRIBUTESCLASS   AGE
pvc-test-6c5c86da89904beeb412eecd9502073   Bound    pvc-7a67273a-7977-470a-b60b-36604ecb48cb   6Gi        RWX            ocs-storagecluster-cephfs   <unset>                 94s


$ oc get pods client -o yaml | grep -i pvc-test-6c5c86da89904beeb412eecd9502073 -A 1 -B 3
  volumes:
  - name: mypvc
    persistentVolumeClaim:
      claimName: pvc-test-6c5c86da89904beeb412eecd9502073

$ oc get pods server -o yaml | grep -i pvc-test-6c5c86da89904beeb412eecd9502073 -A 1 -B 3
  volumes:
  - name: mypvc
    persistentVolumeClaim:
      claimName: pvc-test-6c5c86da89904beeb412eecd9502073

Signed-off-by: Oded Viner <[email protected]>
Copy link

openshift-ci bot commented Dec 19, 2024

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: OdedViner, paraggit

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Customer defects Defects automated aspart of GSS closed loop lgtm size/M PR that changes 30-99 lines team/e2e E2E team related issues/PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants