Search code examples
amazon-web-servicesamazon-ec2apache-sparkspark-ec2

Apache Spark EC2 c4.2xlarge not launching


When attempting to launch an EC2 cluster (c4.2xlarge) using the Apache Spark EC2 script I get the following error:

Don't recognize c4.2xlarge, assuming type is pvm
Spark AMI: ami-9a6e0daa
Launching instances...
ERROR:boto:400 Bad Request
ERROR:boto:<?xml version="1.0" encoding="UTF-8"?>
<Response><Errors><Error><Code>InvalidParameterCombination</Code><Message>Virtualization type 'hvm' is required for instances of type 'c4.2xlarge'.</Message></Error></Errors

Any fixes?


Solution

  • The instance type you are using isn't supported in the spark-ec2 script.

    This is the list of the EC2 types you can use :

    c1.medium, c1.xlarge,c3.2xlarge c3.4xlarge c3.8xlarge c3.large c3.xlarge cc1.4xlarge, cc2.8xlarge, cg1.4xlarge , cr1.8xlarge, hi1.4xlarge, hs1.8xlarge, i2.2xlarge, i2.4xlarge, i2.8xlarge, i2.xlarge, m1.large, m1.medium, m1.small, m1.xlarge, m2.2xlarge, m2.4xlarge, m2.xlarge, m3.2xlarge, m3.large, m3.medium, m3.xlarge, r3.2xlarge, r3.4xlarge, r3.8xlarge, r3.large, r3.xlarge, t1.micro, t2.medium, t2.micro, t2.small

    I invite you to read the script source code here.