Linux ARP command

Source: Internet
Author: User

First, Introduction

The ARP command is used to manipulate the host's ARP buffer, which can be used to display all entries in the ARP buffer, delete the specified entry, or add a static IP address corresponding to the MAC address.

Second, the grammar

-a< host >: Displays all entries for the ARP buffer,-h< address type >: Specifies the type of address used by the ARP directive;-d< host >  : Removes the ARP entry for the specified host from the ARP buffer;-D: Uses the hardware address of the specified interface;-E: Displays entries in the ARP buffer in the Linux display style;-i< interface >  : Specifies the network interface to operate the ARP buffer;-s< host ><mac address >: Sets the static mapping of the IP address and MAC address of the specified host;-N: Displays the entries in the ARP buffer numerically; -V: Displays detailed ARP buffer entries, including statistics for buffer entries;-f< file: Sets the static mapping of the host's IP address to the MAC address.

Third, examples

1) View ARP cache

Arp-nv

2) Add ARP cache entry

10.1. 1.1 xx:All:: £º::

3) Delete the ARP cache entry

10.1. 10.118

4) Specify the MAC address of the reply

10.0. 0.2 eth1 Pub
Tip: When eth0 receives an IP address of 10. 0.0. 2 request, reply with eth1 MAC address

Reference: http://blog.chinaunix.net/uid-9525959-id-3318814.html

Linux ARP command

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.