Validating Network Address Configuration

To verify the configuration of the network address, you need to use the  ip  utility. The  ip  utility is a modern utility that can consider advanced networking features that have been introduced recently. With the  ip  utility, many aspects of networking can be monitored:    
■   Use  ip addr  to configure and monitor network addresses    
■   Use  ip route  to configure and monitor routing information    
■   Use  ip link  to configure and monitor network link state
To show current network settings, you can use the  ip addr show  command (which can be abbreviated as  ip a s  or even as  ip a ). The  ip  command is relatively smart and does not always require you to type the complete option.--RHEL7.0版本以上查看网络配置命令使用ip addr show,以前的命令ifconfig -a不再使用了。

[root@rhel7 ~]# ifconfig -a
-bash: ifconfig: command not found
[root@rhel7 ~]# ip addr show
: lo: <LOOPBACK,UP,LOWER_UP> mtu qdisc noqueue state UNKNOWN
link/loopback ::::: brd :::::
inet 127.0.0.1/ scope host lo
valid_lft forever preferred_lft forever
inet6 ::/ scope host
valid_lft forever preferred_lft forever
: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu qdisc pfifo_fast state UP qlen
link/ether :::d8::0a brd ff:ff:ff:ff:ff:ff
inet 192.168.1.111/ brd 192.168.1.255 scope global enp0s3
valid_lft forever preferred_lft forever
inet6 fe80::a00:27ff:fed8:650a/ scope link
valid_lft forever preferred_lft forever
[root@rhel7 ~]# ip a
: lo: <LOOPBACK,UP,LOWER_UP> mtu qdisc noqueue state UNKNOWN
link/loopback ::::: brd :::::
inet 127.0.0.1/ scope host lo
valid_lft forever preferred_lft forever
inet6 ::/ scope host
valid_lft forever preferred_lft forever
: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu qdisc pfifo_fast state UP qlen
link/ether :::d8::0a brd ff:ff:ff:ff:ff:ff
inet 192.168.1.111/ brd 192.168.1.255 scope global enp0s3
valid_lft forever preferred_lft forever
inet6 fe80::a00:27ff:fed8:650a/ scope link
valid_lft forever preferred_lft forever
[root@rhel7 ~]# ip route
default via 192.168.1.100 dev enp0s3 proto static metric
192.168.1.0/ dev enp0s3 proto kernel scope link src 192.168.1.111 metric
[root@rhel7 ~]# ip link
: lo: <LOOPBACK,UP,LOWER_UP> mtu qdisc noqueue state UNKNOWN mode DEFAULT
link/loopback ::::: brd :::::
: enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu qdisc pfifo_fast state UP mode DEFAULT qlen
link/ether :::d8::0a brd ff:ff:ff:ff:ff:ff
[root@rhel7 ~]#

ip -s link:  This shows all existing network connections, in addition to statistics about the number of packets that have been sent and associated error messages.

[root@rhel7 ~]# ip -s link
: lo: <LOOPBACK,UP,LOWER_UP> mtu qdisc noqueue state UNKNOWN mode DEFAULT
link/loopback ::::: brd :::::
RX: bytes packets errors dropped overrun mcast TX: bytes packets errors dropped carrier collsns : enp0s3: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu qdisc pfifo_fast state UP mode DEFAULT qlen
link/ether :::d8::0a brd ff:ff:ff:ff:ff:ff
RX: bytes packets errors dropped overrun mcast TX: bytes packets errors dropped carrier collsns [root@rhel7 ~]#

RHEL7查看网卡配置命令ip addr show的更多相关文章

  1. LINUX查看硬件配置命令

    LINUX查看硬件配置命令   系统 # uname -a # 查看内核/操作系统/CPU信息 # head -n 1 /etc/issue # 查看操作系统版本 # cat /proc/cpuinf ...

  2. Ubuntu 为网卡配置静态IP地址

    为网卡配置静态IP地址编辑文件/etc/network/interfaces:sudo vi /etc/network/interfaces并用下面的行来替换有关eth0的行:# The primar ...

  3. Linux命令 — 设置或查看网络配置命令ifconfig

    ifconfig命令用于设置或查看网络配置,包括IP地址.网络掩码.广播地址等.它是linux系统中,使用频率最高的关于网络方面的命令. 1. 命令介绍 命令格式: ifconfig [interfa ...

  4. centos6 网卡配置,多IP设置

    ##云服务器 centos6网卡配置 #设置出口IP vim /etc/sysconfig/network-scripts/ifcfg-eth0DEVICE=seth0 #网卡名称 BOOTPROTO ...

  5. Centos7网卡配置命令nmcli

    在配置Centos6时,大家第一想到的就是把networkManager这个服务关掉,让它消失,这个服务台太鸡肋了,不该起作用的时候经常起作用,给管理带来了不便,但是在Centos7当中network ...

  6. Linux命令ip addr详解

    熟悉Linux操作系统的同学对于ip addr命令应该不陌生,知道它是用来查看本地IP地址的,除了IP地址,其它额外的信息有必要了解一下. root@test:~# ip addr1: lo: < ...

  7. GetAdaptersInfo获取网卡配置和Ip地址信息

    一台机器上可能不只有一个网卡,但每一个网卡只有一个MAC地址,而每一个网卡可能配置有多个IP地址:如平常的笔记本电脑中,就会有无线网卡和有线网卡(网线接口)两种:因此,如果要获得本机所有网卡的IP和M ...

  8. Linux下,查看网络配置(IP,Gateway,DNS)

    查看IP [root@localhost ~]# ifconfigem1       Link encap:Ethernet  HWaddr F0:1F:AF:D6:17:DD            ...

  9. android如何查看网卡名和ip

    我们知道,在windows下查看ip地址用ipconfig,在Linux下查看ip地址用ifconfig.今天在使用android查看的时候ifconfig却不管用: 查找网上资料发现,原来默认ifc ...

随机推荐

  1. VBox UUID already exists 问题处理

    问题说明: 在win7系统下使用vbox时,有时候需要多台相同操作系统和开发环境的虚拟电脑时,如果重复安装,会比较麻烦.那么可以在vbox中创建一个新的虚拟电脑B,但不创建虚拟硬盘,然后拷贝虚拟电脑A ...

  2. ajax+XMLHttpRequest里的FormData实现图片异步上传

    发这篇博客的时候我是自己在研究这个XMLHttpRequest请求,在别人的博客上面知道XMLHttpRequest新加了一个FormData的东西,好像现在APP请求后台也有用这种方式的吧. 别的不 ...

  3. ActiveX相关

    ActiveX 1.创建ActiveXhttp://blog.csdn.net/fww330666557/article/details/6533118 继承IObjectSafety接口http:/ ...

  4. ES5数组方法

    先标明参考出处: http://blog.csdn.net/codebistu/article/details/8049705 本来写过一篇有关数组新方法的(详见: [转]JavaScript函数和数 ...

  5. 编程规范之 if 语句的简单规则

    原文: http://www.oschina.net/translate/basic-rules-for-code-readability-and-the-if-statement 代码应该是可阅读就 ...

  6. 机器学习(1)之梯度下降(gradient descent)

    机器学习(1)之梯度下降(gradient descent) 题记:最近零碎的时间都在学习Andrew Ng的machine learning,因此就有了这些笔记. 梯度下降是线性回归的一种(Line ...

  7. 『Python』 多线程 端口扫描器

    0x 00 Before Coding 当端口打开时,向端口发送 TCP SYN 请求,会返回一个 ACK 响应: 当端口关闭,返回的是 RST 响应: 0x 01 Coding  可以用 socke ...

  8. CentOS 6.4 64位 源码编译hadoop 2.2.0

    搭建环境:Centos 6.4 64bit 1.安装JDK 参考这里2.安装mavenmaven官方下载地址,可以选择源码编码安装,这里就直接下载编译好的wget http://mirror.bit. ...

  9. System.Web.Http.Tracing 在webapi里面应用

    最近想写log.再接口里面 所以就想到了.net 4.0提供的这个类. 整好.配合asp.net api好使用 ,而且 本地调试会在 vs Output 里面输出. 1.开启这个Tracing con ...

  10. android.support.design.widget.AppBarLayout 在android5.0+底部显示空白条问题

    在最外层使用 RelativeLayout作为根节点,同时设置 android:fitsSystemWindows="true"问题解决. <?xml version=&qu ...