HOW TO SCHEDULE AN EC2 INSTANCE ?
Step 1 :- Login to AWS and open cloud formation console, Start new stack with click on create new stack button. Here to you need to select below option. AWS is providing cloud formation template to schedule an instance. You can download from this link . Or you can launch template remotely from this this link .
Step 2 :- In this step, you need to specify some details as per your requirement. So start with giving your stack name, most of the details we are not going to change and leave as it is. Below are some of the details.
- Instance Scheduler tag name :- this is use for tag an EC2 or RDS instances.
- Service(s) to schedule :- choose EC2 or RDS, or Both to apply as per you need
- Region(s) :- leave blank for your current region.
- Default time zone :- default value is UTC, you can change if you require but I suggest you to choose UTC time zone.
- Cross-account role :- leave blank for current account.
- This account, pick Yes for current account.
- Frequency :- It is frequency time when lambda will triggered for schedule instance
- Memory size :- size of Lambda function that run the scheduler. if you deal with large number of instance, make sure to increase memory size.
- Enable cloud watch logs for troubleshooting
- started tags :- state= started
- stopped tags :- state=stopped
Step 3 :- Now click on next and leave all other option as it is. Review your parameter and and create stack. It will take some time to create stack.
Step 4 :- Now, Scheduler stack is created. You need to assign tag to instance.But before open DynamoDB.Here config, scheduler and maintenance table are created by cloud formation stack. In config table you can change timezone, time of schedule etc.. . You can scale up and down also by tagging an instance.
Step 5 :- If you want to schedule instance as per uk-office hour ( you can find time by clicking on period) time, you need to give tag name to Instance which we need to schedule.







Comments
Post a Comment