Error - '''unsupported architecture for instance type "t2.micro": i386''' while creating a Kubernetes Cluster on AWS

4/19/2021

I am new to this platform and this is my second question. For one month, I have been trying to set up a Kubernetes cluster using AWS unsuccessfully. But every day, I get a new error, but this time, I could not solve this error.

I am using Kali Linux in Virtual Box with Windows as a host. I am following a tutorial from Udemy for the setup.

1) I have installed Kops, Kubectl, and AWSCli successfully. 2) I have configured the keys correctly, using AWS configure (For learning purpose, I have given my user full administrator rights) 3) I created the S3 bucket (Gave it public access) 4) Now to create the hosted zone, I used AWS Route 53. Here are specs of my hosted zone

5) Since, I do not have a domain, I bought a free subdomain from freenom.com and configured the nameservers correctly. Free domain configuration

6) After that, I created a pair of keys using ssh-keygen for logging in to the cluster. 7) In the end, I am running this command,

kops create cluster --name=kubernetes.hellaswell.ml --state=s3://kops-state-crap --zones=eu-west-1a --node-count=2 --node-size=t2.micro --master-size=t2.micro --dns-zone=kubernetes.hellaswell.ml                                   1I0418 22:49:10.855151   12216 new_cluster.go:238] Inferred "aws" cloud provider from zone "eu-west-1a"
I0418 22:49:10.855313   12216 new_cluster.go:962]  Cloud Provider ID = aws
I0418 22:49:12.604015   12216 subnets.go:180] Assigned CIDR 172.20.32.0/19 to subnet eu-west-1a

unable to determine machine architecture for InstanceGroup "master-eu-west-1a": unsupported architecture for instance type "t2.micro": i386
-- yousuf
amazon-web-services
aws-cli
kops
kubectl
kubernetes

3 Answers

4/20/2021

Thankyou, https://stackoverflow.com/users/4523789/ole-markus-with , Your suggestion of using t3.medium was indeed helpful.

┌──(kali㉿kali)-[~]
└─$ kops create cluster --name=kube.hellaswell.ml --state=s3://kops-state-crap --zones=eu-west-1a --node-count=2 --node-size=t2.small --master-size=t2.small --dns-zone=kube.hellaswell.ml
I0419 20:18:36.700942    2086 new_cluster.go:238] Inferred "aws" cloud provider from zone "eu-west-1a"
I0419 20:18:36.700999    2086 new_cluster.go:962]  Cloud Provider ID = aws
I0419 20:18:37.938892    2086 subnets.go:180] Assigned CIDR 172.20.32.0/19 to subnet eu-west-1a

unable to determine machine architecture for InstanceGroup "master-eu-west-1a": unsupported architecture for instance type "t2.small": i386
                                                                                                                                                                                                                                             
┌──(kali㉿kali)-[~]
└─$ kops create cluster --name=kube.hellaswell.ml --state=s3://kops-state-crap --zones=eu-west-1a --node-count=2 --node-size=t2.medium --master-size=t2.medium --dns-zone=kube.hellaswell.ml                                             1I0419 20:18:58.255708    2094 new_cluster.go:238] Inferred "aws" cloud provider from zone "eu-west-1a"
I0419 20:18:58.255834    2094 new_cluster.go:962]  Cloud Provider ID = aws
I0419 20:18:59.282307    2094 subnets.go:180] Assigned CIDR 172.20.32.0/19 to subnet eu-west-1a

unable to determine machine architecture for InstanceGroup "master-eu-west-1a": unsupported architecture for instance type "t2.medium": i386
                                                                                                                                                                                                                                             
┌──(kali㉿kali)-[~]
└─$ kops create cluster --name=kube.hellaswell.ml --state=s3://kops-state-crap --zones=eu-west-1a --node-count=2 --node-size=t3.medium --master-size=t3.medium --dns-zone=kube.hellaswell.ml                                             1I0419 20:20:47.323068    2103 new_cluster.go:238] Inferred "aws" cloud provider from zone "eu-west-1a"
I0419 20:20:47.323286    2103 new_cluster.go:962]  Cloud Provider ID = aws
I0419 20:20:49.012132    2103 subnets.go:180] Assigned CIDR 172.20.32.0/19 to subnet eu-west-1a
I0419 20:20:51.943459    2103 create_cluster.go:726] Using SSH public key: /home/kali/.ssh/id_rsa.pub
Previewing changes that will be made:

I0419 20:21:03.446344    2103 executor.go:111] Tasks: 0 done / 77 total; 43 can run
W0419 20:21:05.094898    2103 vfs_castore.go:604] CA private key was not found
I0419 20:21:05.095112    2103 executor.go:111] Tasks: 43 done / 77 total; 16 can run
I0419 20:21:06.137672    2103 executor.go:111] Tasks: 59 done / 77 total; 16 can run
I0419 20:21:07.358255    2103 executor.go:111] Tasks: 75 done / 77 total; 2 can run
I0419 20:21:08.538778    2103 executor.go:111] Tasks: 77 done / 77 total; 0 can run
Will create resources:
  AutoscalingGroup/master-eu-west-1a.masters.kube.hellaswell.ml

I am new to AWS and Kubernetes, Pardon my curiosity, But I wanted to know, How do others are able to create clusters with t2.micro. I have seen tutorials on Udemy and this blog too https://www.scottyfullstack.com/blog/setting-up-a-free-tier-kubernetes-cluster-with-kop/

-- yousuf
Source: StackOverflow

6/20/2021

These instance types should now be supported by kOps if there are 64-bit variabts available.

The fix can be found here: https://github.com/kubernetes/kops/pull/11463

-- Ole Markus With
Source: StackOverflow

4/19/2021

unsupported architecture for instance type "t2.micro": i386

Some EC2 t2.micro instances are actually 32-bit machines. See How to find if my Amazon EC2 instance is 32 bit or 64 bit?.

Your Kubernetes container probably contains a binary that is compiled for 64-bit machines. I suggest that you choose a different EC2 instance type, e.g. t3.small.

-- Jonas
Source: StackOverflow