{"action":"created","issue":{"url":"https://api.github.com/repos/docker/machine/issues/1437","labels_url":"https://api.github.com/repos/docker/machine/issues/1437/labels{/name}","comments_url":"https://api.github.com/repos/docker/machine/issues/1437/comments","events_url":"https://api.github.com/repos/docker/machine/issues/1437/events","html_url":"https://github.com/docker/machine/issues/1437","id":91881367,"number":1437,"title":"EC2 deployment with machine keeps on looping through Testing TCP connection to: xxx.xxx.xxx.xxx:22","user":{"login":"sjwhyte","id":908232,"avatar_url":"https://avatars.githubusercontent.com/u/908232?v=3","gravatar_id":"","url":"https://api.github.com/users/sjwhyte","html_url":"https://github.com/sjwhyte","followers_url":"https://api.github.com/users/sjwhyte/followers","following_url":"https://api.github.com/users/sjwhyte/following{/other_user}","gists_url":"https://api.github.com/users/sjwhyte/gists{/gist_id}","starred_url":"https://api.github.com/users/sjwhyte/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjwhyte/subscriptions","organizations_url":"https://api.github.com/users/sjwhyte/orgs","repos_url":"https://api.github.com/users/sjwhyte/repos","events_url":"https://api.github.com/users/sjwhyte/events{/privacy}","received_events_url":"https://api.github.com/users/sjwhyte/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/docker/machine/labels/driver:ec2","name":"driver:ec2","color":"bfdadc"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":6,"created_at":"2015-06-29T18:58:43Z","updated_at":"2015-07-15T14:58:33Z","closed_at":"2015-07-07T21:22:10Z","body":"I run the following to provision a new ec2 instance in my VPC:\r\n\r\ndocker-machine --debug create --driver amazonec2 --amazonec2-access-key <aws key> --amazonec2-secret-key <aws secret key> --amazonec2-vpc-id vpc-12345678 --amazonec2-subnet-id subnet-12345678 --amazonec2-region us-east-1 --amazonec2-ssh-user <ssh-user> --amazonec2-zone a aws-mse-1;\r\n\r\nThe subnet and the vpc are in the same region and zone and I am running docker-machine 0.3.0\r\n\r\nHere is my output :\r\n\r\n```\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeKeyPairs\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeKeyPairs\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nLaunching instance...\r\ncreating key pair: aws-mse-1\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"ImportKeyPair\"\r\n    ],\r\n    \"KeyName\": [\r\n        \"aws-mse-1\"\r\n    ],\r\n    \"PublicKeyMaterial\": [\r\n        \"c3NoLXJzYSBBQUFBQjNOemFDMXljMkVBQUFBREFRQUJBQUFCQVFDaGo4NXo5S01URDVRYzJ5Kzh1OUY4a3VHRUMva2NUZnhWTzJDaVdjY0Y5ajhTYXl3eWRXeXVYQ2g1bnJ5TDBIYXJORlA2VnBVTFVBQVFzNWlSTHJWOFJNbmtrYUw0Mk8wK\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nconfiguring security group in vpc-5e949a3b\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeSecurityGroups\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nfound existing security group (docker-machine) in vpc-5e949a3b\r\nconfiguring security group authorization for 0.0.0.0/0\r\nlaunching instance in subnet subnet-e6fd98cd\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"RunInstances\"\r\n    ],\r\n    \"BlockDeviceMapping.0.DeviceName\": [\r\n        \"/dev/sda1\"\r\n    ],\r\n    \"BlockDeviceMapping.0.Ebs.DeleteOnTermination\": [\r\n        \"1\"\r\n    ],\r\n    \"BlockDeviceMapping.0.Ebs.VolumeSize\": [\r\n        \"16\"\r\n    ],\r\n    \"BlockDeviceMapping.0.Ebs.VolumeType\": [\r\n        \"gp2\"\r\n    ],\r\n    \"BlockDeviceMapping.0.VirtualName\": [\r\n        \"\"\r\n    ],\r\n    \"ImageId\": [\r\n        \"ami-5f709f34\"\r\n    ],\r\n    \"InstanceType\": [\r\n        \"t2.micro\"\r\n    ],\r\n    \"KeyName\": [\r\n        \"aws-mse-1\"\r\n    ],\r\n    \"MaxCount\": [\r\n        \"1\"\r\n    ],\r\n    \"MinCount\": [\r\n        \"1\"\r\n    ],\r\n    \"Monitoring.Enabled\": [\r\n        \"0\"\r\n    ],\r\n    \"NetworkInterface.0.AssociatePublicIpAddress\": [\r\n        \"1\"\r\n    ],\r\n    \"NetworkInterface.0.DeviceIndex\": [\r\n        \"0\"\r\n    ],\r\n    \"NetworkInterface.0.SecurityGroupId.0\": [\r\n        \"sg-12345678\"\r\n    ],\r\n    \"NetworkInterface.0.SubnetId\": [\r\n        \"subnet-12345678\"\r\n    ],\r\n    \"Placement.AvailabilityZone\": [\r\n        \"us-east-1a\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nwaiting for ip address to become available\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nGot the IP Address, it's \"54.XX.XX.XX\"\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0axxx\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\ncreated instance ID i-4fa0axxx, IP address 54.xx.xx.xx, Private IP address 10.10.1.221\r\nSettings tags for instance\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"CreateTags\"\r\n    ],\r\n    \"ResourceId.1\": [\r\n        \"i-4fa0axxx\"\r\n    ],\r\n    \"Tag.1.Key\": [\r\n        \"Name\"\r\n    ],\r\n    \"Tag.1.Value\": [\r\n        \"aws-mse-1\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0a9e6\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nGetting to WaitForSSH function...\r\nMaking AWS API call with values:\r\n{\r\n    \"Action\": [\r\n        \"DescribeInstances\"\r\n    ],\r\n    \"InstanceId.1\": [\r\n        \"i-4fa0axxx\"\r\n    ],\r\n    \"Version\": [\r\n        \"2014-06-15\"\r\n    ]\r\n}\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\nTesting TCP connection to: 54.175.59.46:22\r\n.\r\n.\r\n.\r\n.\r\n```"},"comment":{"url":"https://api.github.com/repos/docker/machine/issues/comments/121643627","html_url":"https://github.com/docker/machine/issues/1437#issuecomment-121643627","issue_url":"https://api.github.com/repos/docker/machine/issues/1437","id":121643627,"user":{"login":"jjperezaguinaga","id":1128312,"avatar_url":"https://avatars.githubusercontent.com/u/1128312?v=3","gravatar_id":"","url":"https://api.github.com/users/jjperezaguinaga","html_url":"https://github.com/jjperezaguinaga","followers_url":"https://api.github.com/users/jjperezaguinaga/followers","following_url":"https://api.github.com/users/jjperezaguinaga/following{/other_user}","gists_url":"https://api.github.com/users/jjperezaguinaga/gists{/gist_id}","starred_url":"https://api.github.com/users/jjperezaguinaga/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jjperezaguinaga/subscriptions","organizations_url":"https://api.github.com/users/jjperezaguinaga/orgs","repos_url":"https://api.github.com/users/jjperezaguinaga/repos","events_url":"https://api.github.com/users/jjperezaguinaga/events{/privacy}","received_events_url":"https://api.github.com/users/jjperezaguinaga/received_events","type":"User","site_admin":false},"created_at":"2015-07-15T14:58:33Z","updated_at":"2015-07-15T14:58:33Z","body":"So initially issue #1301 brought me here, and I thought as well that it was something related to our VPC or security groups... until the machines started to stop by themselves. A colleagued pointed this out and after fiddling we found out that an additional volume showed up in the EC2 dashboard (`sda1`, most likely from [here](https://github.com/docker/machine/blob/master/drivers/amazonec2/amazonec2.go#L329. Two volumes showed up in the dashboard: `xvda` and `sda1`). This might had been the case of the machine stopping, since we are using a debian distribution. After booting an EC2 instance with the default ubuntu image we had no issues whatsoever.\r\n\r\nWe are not sure why it's trying to add this volume on the VM, but detaching the volume manually in the EC2 panel allowed the `docker-machine` command to start and ssh into the machine.\r\n\r\n```\r\n➜  ~  docker --version\r\nDocker version 1.7.0, build 0baf609\r\n➜  ~  docker-machine --version\r\ndocker-machine version 0.3.0 (0a251fe)\r\n```"}}