Use of ifconfig commands in linux

Source: Internet
Author: User
Use of the ifconfig command in linux-Linux Enterprise Application-Linux server application information. The following is a detailed description. You can use the ifconfig command to view network configurations in linux to display the basic configurations of the current Nic.

Input ifconfig on the terminal displays the following content:

Eth0
Link encap: Ethernet HWaddr 00: 0C: 29: 0C: 4B: 0F
Inet addr: 192.168.37.128 Bcast: 192.168.37.255 Mask: 255.255.255.0
Up broadcast running multicast mtu: 1500 Metric: 1
RX packets: 33 errors: 0 dropped: 0 overruns: 0 frame: 0
TX packets: 17 errors: 0 dropped: 0 overruns: 0 carrier: 0
Collisions: 0 FIG: 100
RX bytes: 2823 (2.7 Kb)
TX bytes: 2722 (2.6 Kb)
Interrupt: 10 Base address: 0x1080

This is the configuration information of my linux Nic. They indicate:
Eth0: Network Interface
Link encap: Network Type
HWaddr: physical address of the NIC
Inet addr: IP Address
Bcast: broadcast address
Mask: Subnet Mask
UP: Network Interface in use
Number of packets received and transmitted by RX packets and TX packets
RX byte, TX byte indicates the specific number of connected searches and transmissions
Interrupt: terminal information
Base address: Memory address

You can also enable or disable NICs and add IP addresses.
Ifconfig eth0 down \ up disable and start the network interface
Ifconfig basic syntax
Ifconfig Nic id ip address subnet mask address broadcast address

For example:
Ifconfig eth0 192.168.1.101 netmask 255.255.255.0 broadcast 192.168.1.111
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.