UBuntu 系统下 按Ctrl+Alt+T 唤出终端

在终端输入: ifconfig 命令

点击回车 就可以看到自己电脑在局域网的IP地址了

图中第二行 inet 地址:192.168.1.101 就是你的电脑在局域网的IP地址了

如果输入 ifconfig 提示 找不到命令

那就在终端输入:sudo apt-get install net-tools 安装网络工具

安装完成后输入: sudo apt-get update 更新软件包

完成之后 再次输入 ifconfig 命令 就不会出现错误了

用Linux命令行获取本机外网IP地址

  

$ curl ifconfig.me

[root@localhost ~]# curl ifconfig.me

14.23.92.186

$ curl icanhazip.com

[root@localhost ~]# curl icanhazip.com

14.23.92.186

$ curl ident.me

[root@localhost ~]# curl ident.me

14.23.92.186

$ curl ipecho.net/plain

[root@localhost ~]# curl ipecho.net/plain

14.23.92.186

$ curl whatismyip.akamai.com

[root@localhost ~]# curl whatismyip.akamai.com

14.23.92.186

$ curl tnx.nl/ip

[root@localhost ~]# curl tnx.nl/ip

14.23.92.186

$ curl myip.dnsomatic.com

[root@localhost ~]# curl myip.dnsomatic.com

14.23.92.186

$ curl ip.appspot.com

[root@localhost ~]# curl ip.appspot.com

curl: (7) couldn't connect to host

$ curl -s checkip.dyndns.org | sed 's/.*IP Address: [0−9\.]∗[0−9\.]∗.*/\1/g'

[root@localhost ~]# curl -s checkip.dyndns.org | sed 's/.*IP Address: [0−9\.]∗[0−9\.]∗.*/\1/g'

14.23.92.186

Linux 查看IP的更多相关文章

  1. linux 查看ip地址

    1.先要打开linux服务器,然后在linux桌面的空白处点击右键 2.在弹出的选项里,点击[打开终端] 3.打开linux服务器的命令终端后,输入查询linux的ip地址的命令:ifconfig - ...

  2. linux -- 查看ip,路由,dns

    查看ip地址:ifconfig 查看gateway:route 查看dns:nm-tool

  3. Linux查看IP 网关 DNS

    ifconfig查看IP: watermark/2/text/aHR0cDovL2Jsb2cuY3Nkbi5uZXQv/font/5a6L5L2T/fontsize/400/fill/I0JBQkFC ...

  4. linux 查看ip、用户、时间对应执行的命令

    这个需要使用到history命令.可以加数字,返回最近执行的几条命令.如果不加数字会返回所有的历史命令. [root@localhost ~]# history 20 1015 rm stdin.lo ...

  5. linux查看IP

    1:输入 ifconfig,出现如下信息,找到eno16777736(网卡ip信息的配置文件名) 2:输入 cd /etc/sysconfig/network-scripts 找到网卡ip信息的配置文 ...

  6. linux查看出口ip 及w3m字符浏览器

    Linux 查看服务器出口IP    字符浏览器: http://wiki.ubuntu.org.cn/W3m

  7. Linux查看访问IP

    Linux查看访问IP https://blog.csdn.net/tojohnonly/article/details/82772323

  8. linux查看是否能访问外网及拥有的公网IP

    linux查看是否能访问外网及拥有的公网IP linux查看是否能访问外网及拥有的公网IP: 1,测访问外网能力:curl -l http://www.baidu.com 2,测访问外网能力:wget ...

  9. Linux & Windows 查看 ip 地址

    Windows 查看本机 IP 打开 cmd,输入 ipconfig,回车,找到IPv4地址 或者通过以下方式查看 点击Win10系统的右下角的宽带连接图标,如下图所示.        点击弹出菜单的 ...

随机推荐

  1. spring jdbc学习1

    1.queryForObject - 其中的 RowMapper 指定如何去映射结果集的行, 常用的实现类为 BeanPropertyRowMapper - 使用 SQL 中列的别名完成列名和类的属性 ...

  2. <thinkphp51>如何安装cpmposer和tp51

    进入网站之后点击 进入入门指南后点击 进入安装阶段: 1.直接next 2.选择自己的PHP文件路径 3.然后下一步下一步即可. 第二部分: 下载thinkphp51 点击安装包列表 搜索:think ...

  3. CSS样式学习-3、轮廓、伪类/元素、display-flex布局

    一.轮廓 outline绘制于元素周围的一条线,位于边框边缘外围. 属性规定元素轮廓的样式.颜色.宽度. outline-width轮廓宽度,属性:thin细轮廓.medium中等(默认值).thic ...

  4. java后台解析前端传来的json

    @RequestMapping(value = {"save"}) @ResponseBody public Result save(TBaseInterventionPlan m ...

  5. ios中设置input为readonly后,解决弹起软键盘的问题

    可以在input中添加unselectable="on" onfocus="this.blur()",可以解决软键盘弹起问题 <input type=&q ...

  6. Android TextView 跑马灯效果 - 2018年6月19日

    第一步在布局中添加加粗部分代码: <TextView android:id="@+id/tv_company" android:layout_width="0dp& ...

  7. html5移动端查找

    用form包裹住input,修改input的类型为seach,然后给input绑定seach事件,当输入状态是输入键盘上会出现搜索,点击搜索就可以查找了 <form action="& ...

  8. centos7 安装php5.6

    1.查看centos 版本 lsb_release -a LSB Version: :base-4.0-amd64:base-4.0-noarch:core-4.0-amd64:core-4.0-no ...

  9. cdnbest如何让用户访问走最近最快的线路(分组线路)

    用户访问网站有时网络有互通的问题,cdnbest的分组解析可以细分线路,让用户访问自动走最优线路,线路不细分都加默认里,访问的节点是随机分配的 下面我们讲下如何设置: 比如你有电信,移动,和国外的节点 ...

  10. 247. Strobogrammatic Number II输出所有对称数字

    [抄题]: A strobogrammatic number is a number that looks the same when rotated 180 degrees (looked at u ...