System Operations - Lab 5: Managing Resources Using Tagging (Linux) - 2.5
================================================================================================================== Using this command reference. ================================================================================================================== 1. Locate the section you need. Each section in this file matches a section in the lab instructions. 2. Replace items in angle brackets - < > - with appropriate values. For example, in this command you would replace the value - <JobFlowID> - (including the brackets) with the parameter indicated in the lab instructions: elastic-mapreduce --list <JobFlowID>. You can also use find and replace to change bracketed parameters in bulk. 3. Do NOT enable the Word Wrap feature in Windows Notepad or the text editor you use to view this file. ++++1. Managing Resources Using Tags++++ ==================================================================================================================
1.2 Find Development Instances for Project
================================================================================================================== 1.2.1 Find all instances in account with a tag named Project, and a value of ERPSystem aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" 1.2.2 Limit output of above command to InstanceId aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" --query 'Reservations[*].Instances[*].InstanceId' 1.2.3 Include multiple selected values in command output aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" --query 'Reservations[*].Instances[*].{ID:InstanceId,AZ:Placement.AvailabilityZone}' 1.2.4 Include the Project tag in the output aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" --query 'Reservations[*].Instances[*].{ID:InstanceId,AZ:Placement.AvailabilityZone,Project:Tags[?Key==`Project`] | [0].Value}' 1.2.5 Include the Environment and Version tags in the output aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" --query 'Reservations[*].Instances[*].{ID:InstanceId,AZ:Placement.AvailabilityZone,Project:Tags[?Key==`Project`] | [0].Value,Environment:Tags[?Key==`Environment`] | [0].Value,Version:Tags[?Key==`Version`] | [0].Value}' 1.2.6 Add an additional filter to restrict the return results to instances whose Environment tag is set to development: aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" "Name=tag:Environment,Values=development" --query 'Reservations[*].Instances[*].{ID:InstanceId,AZ:Placement.AvailabilityZone,Project:Tags[?Key==`Project`] | [0].Value,Environment:Tags[?Key==`Environment`] | [0].Value,Version:Tags[?Key==`Version`] | [0].Value}' ==================================================================================================================
1.3 Change Version Tag for Development Instances
================================================================================================================== 1.3.3 Run shell script to change Version tag on select instances ./change-resource-tags.sh 1.3.4 Verify changes aws ec2 describe-instances --filter "Name=tag:Project,Values=ERPSystem" --query 'Reservations[*].Instances[*].{ID:InstanceId,AZ:Placement.AvailabilityZone,Project:Tags[?Key==`Project`] | [0].Value,Environment:Tags[?Key==`Environment`] | [0].Value,Version:Tags[?Key==`Version`] | [0].Value}' ++++2. Stop and Start Resources by Tag++++ ==================================================================================================================
2.2. Stop and Restart ERPProject Development Instances
================================================================================================================== 2.2.1 Stop all development instances for the ERPSystem project ./stopinator.php -t"Project=ERPSystem;Environment=development" 2.2.5 Restart the development instances for the ERPSystem project ./stopinator.php -t"Project=ERPSystem;Environment=development" -s ++++3. Challenge 1 Solution - Terminate Non-Compliant Instances++++ ==================================================================================================================
3.3. Run the Script
================================================================================================================== 3.3.4 Run the terminate-instance.php script ./terminate-instances.php -region <region> -subnetid <subnet-id> 漏 2016 Amazon Web Services, Inc. or its affiliates. All rights reserved.

Lab_5_SysOps_Resources_Linux_v2.5的更多相关文章

随机推荐

  1. Octopus系列之价格计算公式

    百分比:在原价的基础上优惠5%,相当于95%折销售实际价格:最后实际销售的价格[基准价格:如果有特价就基于特价,没有特价基于原价]优惠金额:减少的金额 批量优惠 百分比: 原价*(1-5%)的算法实际 ...

  2. Java小bug

    1.使用split函数,将字符串按"."分开,写法如下: String str = "a.b.c"; String[] items = str.split(&q ...

  3. 【jQuery】serializeArray()与serialize()的区别

    serialize()序列化表单元素为字符串,用于 Ajax 请求. serializeArray()序列化表单元素为JSON数据. 具体实例如下: 1 <!DOCTYPE html PUBLI ...

  4. Regsvr32.exe 用法

    RegSvr32.exe 具有以下命令行选项:  Regsvr32 [/u] [/n] [/i[:cmdline]] dllname /u - 取消注册服务器 /i - 调用 DllInstall,为 ...

  5. NetworkReachable学习笔记

    一.基本知识 在需要联网的iPhone程序中,我们首先需要检查网络的状态,如果不能连接网络则告诉用户程序不能使用的原因是没有网络连接.在iPhone的SystemConfiguration框架里有提供 ...

  6. uboot 链接地址与运行地址的区别

    对于ARM架构的CPU,上电后PC寄存器是指向0地址处的,从这个地址开始运行程序,那么运行了启动代码后会把程序搬移到内存中去运行,这样就是产生程序会在运行时有个两地址,而由源码编译为可执行文件时只会指 ...

  7. python 程序构架

    http://blog.csdn.net/heyabo/article/details/8806176

  8. good books

  9. 数组第K小数问题 及其对于 快排和堆排 的相关优化比较

    题目描述 给定一个整数数组a[0,...,n-1],求数组中第k小数 输入描述 首先输入数组长度n和k,其中1<=n<=5000, 1<=k<=n 然后输出n个整形元素,每个数 ...

  10. Qt Creator提示"Qt没有被正确安装,请运行make install"的解决办法

    笔者最近使用Qt在开发一些小程序,觉得这个框架设计确实很好,使用了信号和槽解决了组件之间的通讯问题,可以说是基于C++语言上一个非常大的创新,大大提高了开发人员的编码效率,也使整个C++语言更加抽象. ...