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

fix: (IAC-1162) AWS warns of misconfigured EFS mounts #505

Merged
merged 4 commits into from
Dec 1, 2023

Conversation

dhoucgitter
Copy link
Member

Changes

  • Define the set of AWS EFS best practice NFS mount options to apply with nfs-subdir-external-provisioner baseline tasks
  • Use the EFS mount options when EFS storage is present with the aws provider, leave NFS mount options as is for all other storage options
  • Add setting fact for STORAGE_TYPE_BACKEND from tfstate when defined in order to select the EFS mount options

Tests

Scenario Provider storage_type_backend Cadence DAC NFS mount options include noresvport Notes
1 aws efs stable.2023.09 yes Successful deployment, all pods Running and stable
2 aws nfs n/a no DAC baseline verified to use existing NFS mount options
3 aws ontap n/a no DAC baseline verified to use existing NFS mount options
4 azure n/a n/a no DAC baseline verified to use existing NFS mount options, no unexpected behavior when STORAGE_TYPE_BACKEND is not defined and NOT using aws provider

@dhoucgitter dhoucgitter added the bug Something isn't working label Nov 28, 2023
@dhoucgitter dhoucgitter self-assigned this Nov 28, 2023
- noresvport
- rsize=1048576
- wsize=1048576
- hard
Copy link
Member

Choose a reason for hiding this comment

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

Is this one really required? As hard states that if the item being mount is not their it will wait forever until that mount point is available. Where soft will simply try and if it fails it'll continue and request the mount when its needed. Just making sure.

Copy link
Member Author

Choose a reason for hiding this comment

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

@thpang it doesn't seem like that one is mandatory. The list of options I included came from the AWS recommended NFS mount options for EFS https://docs.aws.amazon.com/efs/latest/ug/mounting-fs-nfs-mount-settings.html

The bullet for the hard option says:

hard – Sets the recovery behavior of the NFS client after an NFS request times out, so that NFS requests are retried indefinitely until the server replies. We recommend that you use the hard mount option (hard) to ensure data integrity. If you use a soft mount, set the timeo parameter to at least 150 deciseconds (15 seconds). Doing so helps minimize the risk of data corruption that is inherent with soft mounts.

Given that recommendation, it sounds like we should be OK using soft instead since we have timeo=600 already. I'll push a commit to use the soft mount option instead.

@dhoucgitter dhoucgitter requested a review from thpang November 29, 2023 18:35
@@ -0,0 +1,57 @@
# PostgreSQL
Copy link
Contributor

Choose a reason for hiding this comment

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

Changes look good, not sure why this is showing up again, but the content looks identical to what is in staging now.

@dhoucgitter dhoucgitter merged commit 38a115d into staging Dec 1, 2023
3 checks passed
@dhoucgitter dhoucgitter deleted the fix/iac-1162 branch December 1, 2023 16:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants