Home > Operation and Maintenance > CentOS > How to check ip on centos

How to check ip on centos

Release: 2020-03-18 16:49:42
Original
18468 people have browsed it

How to check ip on centos

Use the ip addr command in centos to view the current IP address of the system. You can see that the current IP address is 10.0.0.3.

How to check ip on centos

Recommendation: "centos usage tutorial"

ip addr is another command to check ip in Linux besides ifconfig. You can first take a look at the output of this command:

[root@localhost ~]# ip addr
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN 
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host 
       valid_lft forever preferred_lft forever
2: eno16777736: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000
    link/ether 00:0c:29:e7:d7:08 brd ff:ff:ff:ff:ff:ff
    inet 192.168.3.9/24 brd 192.168.3.255 scope global eno16777736
       valid_lft forever preferred_lft forever
    inet6 fe80::20c:29ff:fee7:d708/64 scope link 
       valid_lft forever preferred_lft forever
Copy after login

The command result on my machine displays two parts, lo and eth0. If there are multiple network cards, each network card will display one part.

lo: The full name is loopback, which is the loopback address. It is often assigned to the 127.0.0.1 address and is used for local communication. It returns directly after kernel processing and will not appear on any network.

eth0: Network card name. If there are multiple network cards, there will be multiple eth or other names.

Recommended learning: Linux video tutorial

The above is the detailed content of How to check ip on centos. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template