ARP Table Management Address Resolution Protocol ARP stands for Address Resolution Protocol. ARP is used to monitor and modify the MAC address and IP address mapping table .
Summary
[ hide ]
- 1 Operation
- 2 ARP table management
- 3 Internal links
- 4 Source
Functioning
ARP uses a cache that consists of a table that stores the mappings between the data link level and the network level IP addresses . The data link layer is responsible for managing MAC addresses and the network layer for IP addresses. ARP associates IP addresses with MAC addresses. To reduce the number of ARP requests, each operating system that implements the ARP protocol keeps a cache in RAM of all recent allocations.
ARP table management
Taking into account that the ARP table is lost when the system is shut down and in many cases it is necessary to maintain it in some servers , this procedure can be implemented with which we always maintain the same ARP table in the server. In order to fill the table according to the needs of each user and for the entries in the ARP table to be static, it is necessary first of all to have all the MACs of the LAN workstations related to the IP assigned by the DHCP server. With these MACs and the IP addresses, a file is created, in this case we will call it ip_mac.bat with the following structure:
- IP MAC command
arp -s 172.27.20.10 50-e5-49-89-42-0e
example :
- @echo Made ARP table
- @echo on
- arp -s 172.27.20.10 50-e5-49-89-42-0e
- arp -s 172.27.20.11 90-2b-34-70-1c-19
- arp -s 172.27.20.12 50-e5-49-89-70-7f
- arp -s 172.27.20.13 90-2b-34-70-1a-22
A line must be defined for each workstation. Once the file ip_mac.bat is created it must be executed so that the entries in the ARP table are static.
If you want no other PC to connect to the server, fill in all the IPs up to 172.27.x.255, linking 00-00-00-00-00-00 for those IP addresses that are not assigned by the DHCP service, In this way, if someone tries to configure a manual IP and tries to connect to this server, when checking the ARP table it sees that said IP has another MAC assigned, even if it is 00-00-00-00-00-00, so it denies the connection.




