EC2 Flashcards
EC2 Enhanced Networking
Uses advanced virtualisation (Single Route - IO Virtualisation) to deliver:
- Higher I/O
- Lower host CPU usage
- More bandwidth
- Higher packets per second (PPS)
- Consistent lower latency
Available for no charge on most EC2 types.
How many hosts does a EC2 instance run in?
ONE AZ. If a AZ faces major issue, it will impact EC2 instances. (No HA by default).
EC2 Charges at Stopped State
Still incur charges for EBS
Permission error when SSH into Linux instance. How do I fix it?
Key is missing permissions. Need to perform chmod 0400 command on the .pem key.
EC2 Status Checks
- System Status Checks: makes sure traffic can reach the hardware. Checks for loss of power, network connectivity, software and hardware issues.
- Instance Status Checks: makes sure instance OS is available and accepting traffic. Checks for corrupted file system, incorrect instance networking, and/or OS kernel issues.
Elastic IP’s
- Static IPv4 address
- can only attach to one instance at a time
- can mask a system/instance failure, by remapping to another working instance
- Max 5 EIP’s
User Data Key Limitations
- Opaque to EC2 instance, just a block of data
- NOT secure. Don’t use it for passwords
- Limited to 16KB in size
- Can be modified when instance stopped
- ONLY executed at launch
- Accessed via metadata IP: 169.254.169.254/latest/user-data
Cloudformation::init (cfn-init)
Used to maintain desired state of EC2 instance through a helper script. Can control packages, groups, users, sources, files, commands, and services.
Scheduled reserved instances
- Launch within time window you reserve
-
EC2 Status Checks Auto Recovery
Can create a CloudWatch alarm and auto recovery, which will try to fix the issue, including, moving to a new host (if required).
Types of spot requests
- One-time request: will launch instance if spot request is fulfilled.
- Persistent: will stay in queue as valid until request is value.
AMI regional/AZ?
AMI ID’s differ across regions
Dedicated Hosts limitation
- AMI Limits: No RHEL, SUSE Linux, and Windows AMIs are NOT supported.
- Amazon RDS instances are not supported
- Placement groups are NOT supported
Elastic Network Interfaces
- Secondary ENI + MAC is used for transfering licenses between multiple instances
- Multi homed (subnets) management can give multiple connections
- Different Security Groups
- OS: doesnt see public IPv4 address.
- Bound to specific AZ
Security Groups
Can reference other Security Groups (instead of IP).