{
  "id": "cloud/aws-lambda-efs-mount-timeout-cross-account",
  "signature": "Task timed out after 3.00 seconds while mounting EFS file system. Ensure that the VPC is configured correctly and the EFS mount target is in the same subnet as the Lambda function.",
  "signature_zh": "任务在 3.00 秒后超时，同时挂载 EFS 文件系统。请确保 VPC 配置正确，并且 EFS 挂载目标与 Lambda 函数位于同一子网中。",
  "regex": "Task timed out after \\d+\\.\\d+ seconds while mounting EFS file system",
  "domain": "cloud",
  "category": "network_error",
  "subcategory": null,
  "root_cause": "Lambda cannot mount EFS when the EFS file system is in a different VPC or account, even if VPC peering exists, because Lambda requires the mount target to be in the same VPC and subnet as the function's execution role.",
  "root_cause_type": "generic",
  "root_cause_zh": "当 EFS 文件系统位于不同的 VPC 或账户中时，即使存在 VPC 对等连接，Lambda 也无法挂载 EFS，因为 Lambda 要求挂载目标与函数的执行角色位于同一 VPC 和子网中。",
  "versions": [
    {
      "version": "AWS Lambda (Python 3.12 runtime)",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "Amazon EFS (NFSv4.1)",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    },
    {
      "version": "AWS RAM (Resource Access Manager)",
      "introduced": null,
      "deprecated": null,
      "removed": null,
      "behavior_change": null,
      "status": "active"
    }
  ],
  "os_specific": {},
  "dead_ends": [
    {
      "action": "",
      "why_fails": "Security group rules are necessary but if the mount target is in a different VPC, Lambda's ENI cannot reach it even with open rules.",
      "fail_rate": 0.8,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "VPC peering connects networks but Lambda's hyperplane ENI does not support cross-VPC EFS mounting; the mount target must be in the same VPC.",
      "fail_rate": 0.95,
      "condition": "",
      "sources": []
    },
    {
      "action": "",
      "why_fails": "Increasing Lambda timeout does not fix the fundamental connectivity issue; the mount attempt will still fail at the network layer.",
      "fail_rate": 0.9,
      "condition": "",
      "sources": []
    }
  ],
  "workarounds": [
    {
      "action": "Create an EFS mount target in the same VPC and subnets as the Lambda function, even if the EFS file system is in another account, by using cross-account mount target creation via AWS Resource Access Manager (RAM) sharing.",
      "success_rate": 0.9,
      "how": "Create an EFS mount target in the same VPC and subnets as the Lambda function, even if the EFS file system is in another account, by using cross-account mount target creation via AWS Resource Access Manager (RAM) sharing.",
      "condition": "",
      "sources": []
    },
    {
      "action": "If cross-account is unavoidable, use an EFS replication or sync to a file system in the same account and VPC, or use an NFS proxy (e.g., an EC2 instance with a reverse proxy) in the Lambda VPC.",
      "success_rate": 0.75,
      "how": "If cross-account is unavoidable, use an EFS replication or sync to a file system in the same account and VPC, or use an NFS proxy (e.g., an EC2 instance with a reverse proxy) in the Lambda VPC.",
      "condition": "",
      "sources": []
    }
  ],
  "workarounds_zh": [
    "Create an EFS mount target in the same VPC and subnets as the Lambda function, even if the EFS file system is in another account, by using cross-account mount target creation via AWS Resource Access Manager (RAM) sharing.",
    "If cross-account is unavoidable, use an EFS replication or sync to a file system in the same account and VPC, or use an NFS proxy (e.g., an EC2 instance with a reverse proxy) in the Lambda VPC."
  ],
  "transition_graph": {
    "leads_to": [],
    "preceded_by": [],
    "frequently_confused_with": []
  },
  "official_doc_url": "https://docs.aws.amazon.com/lambda/latest/dg/services-efs.html",
  "official_doc_section": null,
  "error_code": null,
  "verification_tier": "ai_generated",
  "confidence": 0.85,
  "fix_success_rate": 0.85,
  "resolvable": "true",
  "first_seen": "2024-01-20",
  "last_confirmed": "2024-06-01",
  "last_updated": "2024-06-01",
  "evidence_count": 1,
  "tags": [],
  "locale": "en",
  "aliases": []
}