Reference
clear map
On this page
Delete all entries from a Map file.
Description Jump to heading
A Map file contains a list of key-value pairs. You can reference the file on an acl
line by using the -M
and -f /path/to/file
flags. Use clear map
to remove all entries from a Map file. Note that this only removes them from the load balancer’s runtime memory and not from the file on disk.
Examples Jump to heading
In this example, we delete all entries from the Map file /etc/hapee-2.8/maps/hosts.map
:
bash
echo "clear map /etc/hapee-2.8/maps/hosts.map" | \sudo socat stdio tcp4-connect:127.0.0.1:9999
bash
echo "clear map /etc/hapee-2.8/maps/hosts.map" | \sudo socat stdio tcp4-connect:127.0.0.1:9999
Available since
- HAProxy 2.4
- HAProxy Enterprise 2.4r1
In this example, we delete all entries from version 3 of the map file indicated by ID 2:
bash
echo "clear map @3 #2" | \sudo socat stdio tcp4-connect:127.0.0.1:9999
bash
echo "clear map @3 #2" | \sudo socat stdio tcp4-connect:127.0.0.1:9999
See also Jump to heading
If this page was useful, please, Leave the feedback.