Skip to content

Wordpress on EKS

0

I am trying to run wordpress with EKS but my msql pod is stuck and is unable to get a pv

NAME STATUS VOLUME CAPACITY ACCESS MODES STORAGECLASS VOLUMEATTRIBUTESCLASS AGE mysql-pv-claim Pending efs-sc <unset>

https://aws.amazon.com/blogs/storage/running-wordpress-on-amazon-eks-with-amazon-efs-intelligent-tiering/

1 Answer
1

It appears that your MySQL pod is unable to obtain a Persistent Volume (PV) for storage, which is causing it to remain in a pending state. This issue is likely related to the EFS (Elastic File System) storage class configuration in your EKS cluster.

To resolve this, you should check the following:

  1. Ensure that the EFS CSI (Container Storage Interface) driver is properly installed and configured in your EKS cluster. This driver is necessary for your cluster to interact with EFS volumes.

  2. Verify that you have created an EFS file system and that it's accessible from your EKS cluster's VPC.

  3. Check your StorageClass definition. Make sure you have a StorageClass named "efs-sc" that is correctly configured to use the EFS CSI driver.

  4. Examine your PersistentVolumeClaim (PVC) configuration. Ensure it's requesting storage from the "efs-sc" StorageClass and that the access modes are compatible with EFS (ReadWriteMany is typically used for EFS).

  5. Look at the events and logs related to your PVC and the CSI driver for any error messages that might provide more details about the provisioning failure.

  6. If you're using Fargate, be aware that there are some limitations when it comes to using EFS with EKS on Fargate. Ensure your setup is compatible with Fargate if you're using it.

If after checking these points you're still encountering issues, you may need to manually create a PersistentVolume that references your EFS file system, and then bind your PVC to this PV.

Remember, when using EFS with EKS, it's crucial to have the proper IAM roles and security group settings to allow your nodes to access the EFS file system.
Sources
Failing to mount EFS volume on EKS Fargate | AWS re:Post
Trident dynamic provisioning and FSx... | AWS re:Post

answered 2 years ago

EXPERT

reviewed 2 years ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.