Amazon EC2
EC2 is one of the most popular of AWS' offfering
EC2는 AWS가 제공하는 가장 인기 있는 서비스 중 하나입니다.
EC2 = Elastic Compute Cloud = Ingrastructure as a service
EC2 = Elastic Compute Cloud = 서비스형 인프라
mainly onsists in the capability of :
- Renting virtual machines (EC2) 가상의 장치(컴퓨터)를 빌려주는것.
- Storing data on Virtual drives (EBS) 가상의 드라이브에 데이터를 저장
- Distributing load across machines (ELB) 가상의 장치들 사이의 부담을 나누는 기능 (로드 밸런스) ( Elastic Load Balancer)
- Scaling the services using an auto-scaling group (ASG) 자동 확장 그룹(ASG)을 사용하여 서비스 확장 //Amazon EC2 Auto Scaling(ASG)
Knowing EC2 is fundamental to understand how the Cloud works.
EC2 를 알며면 클라우드 서비스가 어떻게 작동하는지 이해 할수 있습니다.
EC2 sizing & configuration options
EC2 크기&기본 설정 종류
- OS : linux, Windows , Mac
- CPU , Compute power & cores 컴퓨팅 파워, CPU 코어 갯수 등등
- RAM : 램 크기
- Storage space (저장 공간 크기):
- Network-attached EBS & EFS ( )
- hardware ( EC2 Instance Store )
- Network card : speed of the card, Public IP address , 네크워크 카드 설정, 카드 속도, 퍼블릭 IP 주소
- Firewall rules : security group 방화벽 룰 설정, 보안 구룹
- Bootstrap script (configure at first launch) : EC2 User Data. 부트스트랩 스크립트 (첫 실행 시 구성) : EC2 사용자 데이터
EC2 User Data?
Bootstrapping means lauching commands when a machines starts
it is possible to bootstrap our instances using an EC2 User data script.
부트 스트랩핑 이란 장치가 시작할때 실행되는 커맨드 를 만듭니다.
유저 데이터 스크립트 를 사용하여 설정 할수 있습니다.
Script is only run once at the instance start
EC2 user data is used to automate boot task such as :
스크립트는 실행시 한번만 실행되며, 스크립트가 하는 역할은 주로
1. Installing updates 업데이트 설치
2. Installing software 소프트웨어 설치
3. Downloading common files from the internet 필요한 파일을 다운로드 (네트워크 사용)
4. Anything you can think of .. 실행시 필요한 작업들 등등
The EC2 User Data Script tuns with the root user
스크립트는 루트 계정권한드로 작동합니다.
e.g