How can I get more than 3 DHCP leases on KVM (Cent OS 7)

Good Morning,

I can’t remember how I configured my dedicated Server with KVM. In this very moment I am not able to assign more than 3 static IP-Adresses over the kvm-dnsmasq. I used to use this script
GitHub-Link in order to assign IPs to the MAC, which really worked well.

But after I reinstalled my Server, all the tips and tricks in order to assign a static IP to a Mac doesn’t work at all anymore.

So here is my question? Could you help me please?

Sorry for my english:
OS: Cent OS 7

tail -f /var/log/messages | grep -i dhcp

dnsmasq-dhcp[355]: DHCPOFFER(virbr0) 192.168.122.20 52:54:00:12:20:20
dnsmasq-dhcp[355]: DHCPREQUEST(virbr0) 192.168.122.20 52:54:00:12:20:20
dnsmasq-dhcp[355]: DHCPNAK(virbr0) 192.168.122.20 52:54:00:12:20:20 no leases left

Mapping IP to Mac

<network>
  <name>default</name>
  <uuid>xxxxxxxxxxxxxxxx</uuid>
  <forward dev='virbr0' mode='nat'>
    <interface dev='virbr0'/>
  </forward>
  <bridge name='virbr0' stp='on' delay='0'/>
  <mac address='52:54:00:12:20:01'/>
  <ip address='192.168.122.1' netmask='255.255.255.0'>
    <dhcp>
      <range start='192.168.122.2' end='192.168.122.4'/>
      <host mac='52:54:00:12:20:10' name='keepass' ip='192.168.122.10'/>
      <host mac='52:54:00:12:20:20' name='ansible' ip='192.168.122.20'/>
      <host mac='52:54:00:12:20:25' name='nagios' ip='192.168.122.25'/>
      <host mac='52:54:00:12:20:30' name='icinga2' ip='192.168.122.30'/>
      <host mac='52:54:00:12:22:00' name='spielwiese' ip='192.168.122.200'/>
    </dhcp>
  </ip>
</network>

iptables

#!/bin/bash
########## POLICY - Default ##########
# Flush all current rules from iptables
iptables -F
iptables -t nat -F

# Set default policies for INPUT, FORWARD and OUTPUT chains
iptables -P INPUT DROP
iptables -P FORWARD DROP
iptables -P OUTPUT ACCEPT

# Accept packets belonging to established and related connections
iptables -A INPUT -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A FORWARD -m state --state ESTABLISHED,RELATED -j ACCEPT
iptables -A OUTPUT -m state --state ESTABLISHED,RELATED -j ACCEPT

# Allow SSH
iptables -A INPUT -p tcp --dport 22 -j ACCEPT

# Allow loopback
iptables -A INPUT -i lo -j ACCEPT

# Allow Ping
iptables -A INPUT -p icmp -j ACCEPT

# VM's stuff
iptables -A INPUT -s 192.178.122.0/24 -i virbr0 -j ACCEPT
iptables -A FORWARD -d 192.168.122.0/24 -o virbr0 -j ACCEPT
iptables -A FORWARD -s 192.168.122.0/24 -d 192.168.122.0/24 -o virbr0 -j ACCEPT

# Generally NAT traffic for the outside
iptables -t nat -A POSTROUTING -s 192.168.122.0/24 ! -d 192.168.122.0/24 -p tcp -j MASQUERADE --to-ports 1024-65535
iptables -t nat -A POSTROUTING -s 192.168.122.0/24 ! -d 192.168.122.0/24 -p udp -j MASQUERADE --to-ports 1024-65535
iptables -t nat -A POSTROUTING -s 192.168.122.0/24 ! -d 192.168.122.0/24 -j MASQUERADE
iptables -t nat -A POSTROUTING -s 192.168.122.0/24 -o eth0 -j SNAT --to-source xxx.xxx.xxx.xxx

# Logging
iptables -A INPUT -j LOG --log-level 4 -m limit --limit 10/min --log-prefix "iptables INPUT: "
iptables -A FORWARD -j LOG --log-level 4 -m limit --limit 10/min --log-prefix "iptables FORWARD: "
#iptables -A OUTPUT -j LOG --log-level 4 -m limit --limit 10/min --log-prefix "iptables OUTPUT: "
#iptables -A nat -j LOG --log-level 4 --m limit --limit 10/min--log-prefix "iptables NAT: "

########## FINAL ##########
# Save settings
/sbin/service iptables save

Linux sysadmin blog - Linux/Unix Howtos and Tutorials - Linux bash shell scripting wiki