For private IP address:

aws ec2 describe-instances --instance-ids i-b78a096f | grep PrivateIpAddress  | head -1 | awk -F ":" '{print $2}' | sed 's/[",]//g'

  

For public IP address:

aws ec2 describe-instances --instance-ids i-b78a096f | grep PublicIpAddress | awk -F ":" '{print $2}' | sed 's/[",]//g'

  

Getting Private/Public IP address of EC2 instance using AWS-cli [closed]的更多相关文章

  1. Assign an Elastic IP Address to Your Instance

    By default, an instance in a nondefault VPC is not assigned a public IP address, and is private.You ...

  2. Windows Azure Virtual Machine (28) 使用Azure实例级别IP,Instance-Level Public IP Address (PIP)

    <Windows Azure Platform 系列文章目录> 本文介绍的是国内由世纪互联运维的Azure China 熟悉Azure平台的读者都知道,我们在使用Azure Virtual ...

  3. Azure PIP (Instance Level Public IP)

    微软的Azure平台已经支持Instance Level Public IP功能.当有复杂协议的情况下,需要开启多个端口的情况下,可以考虑开启PIP功能. 先介绍几个概念: VIP – virtual ...

  4. Azure VM Public IP设置

    Azure虚拟机的Public IP是用于客户端直连云中的虚拟机,可以认为是一个外网IP,一般我们为虚拟机设置终结点,例如HTTP的80端口,如果使用Public IP可以不使用Azure Porta ...

  5. Azure PowerShell (9) 使用PowerShell导出订阅下所有的Azure VM的Public IP和Private IP

    <Windows Azure Platform 系列文章目录> 笔者在之前的工作中,有客户提出想一次性查看Azure订阅下的所有Azure VM的Public IP和Private IP. ...

  6. Azure China (8) 使用Azure PowerShell创建虚拟机,并设置固定Virtual IP Address和Private IP

    <Windows Azure Platform 系列文章目录> 本文介绍的是由世纪互联运维的Windows Azure China. 相比于Global Azure (http://www ...

  7. 更改oracle RAC public ip,vip,scan ip和private ip

    更改oracle RAC public ip,vip,scan ip和private ip oifcfg - Oracle 接口配置工具 用法:  oifcfg iflist [-p [-n]]    ...

  8. Rejected request from RFC1918 IP to public server address

    Rejected request from RFC1918 IP to public server address

  9. 关于alertmanager报No private IP address found, and explicit IP not provided

    ./alertmanager --config.file=alertmanager.yml level=info ts=2021-11-22T05:53:11.195Z caller=main.go: ...

随机推荐

  1. Java程序员自我介绍

    有关Java程序员的面试自我介绍范文(一) 我叫XXX,今年21岁,毕业于XX解放军信息工程大学计算机科学与技术专业,拥有扎实的Core Java基础,良好的编程风格;熟悉JSP+Servlet+Ja ...

  2. Notes of the scrum meeting(12.11)

    meeting time:19:30~20:30p.m.,December 11th,2013 meeting place:3号公寓一层 attendees: 顾育豪                  ...

  3. Android 网络编程 API笔记 - java.net 包相关 接口 api

    Android 网络编程相关的包 : 9 包, 20 接口, 103 类, 6 枚举, 14异常; -- Java包 : java.net 包 (6接口, 34类, 2枚举, 12异常); -- An ...

  4. A+B 输入输出练习I

    while True: try: s=raw_input() a,b=s.split(' ') a,b=int(a),int(b) print a+b except EOFError: break A ...

  5. <Effective C++>读书摘要--Inheritance and Object-Oriented Design<一>

    1.Furthermore, I explain what the different features in C++ really mean — what you are really expres ...

  6. Android api level对照表

    转自:blog.csdn.net/lihenair/article/details/49869299 Platform Version API Level VERSION_CODE Notes And ...

  7. 在网页中浏览PDF文档

    刚开始找了好多插件,包括pdf.js,但都不理想,后来发现用iframe反而容易: <iframe src="test_pdf.pdf" width="800&qu ...

  8. f-measure[转]

    F-Measure又称为F-Score,是IP(信息检索)领域常用的一个评价标准,计算公式为: 其中β是参数,P是准确率(Precision),R是召回率(Recall). F1-Measure:当参 ...

  9. 在Ubuntu系统下编译arcsim仿真器

    首先,用tar zxvf arcsim-0.2.1.tar.gz 将软件包解压 然后,打开里面的INSTALL文件,按照里面的步骤一步一步安装库.Ubuntu13.04下 1.BLAS sudo ap ...

  10. bzoj3864-hdu4899-Hero meet devil

    题目 给出一个由AGTC组成的字符串\(S\),长度为\(n\),对于每个\(i\in [0,n]\),问有多少个长度为\(m\),仅含有AGTC的字符串\(T\)使得\(S\)与\(T\)的最长公共 ...