This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
howto:general:dhcp:multiple_dhcp [2015/05/10 13:29] admin [Troubleshooting] |
howto:general:dhcp:multiple_dhcp [2018/05/24 09:05] (current) |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Multiple DHCP-Server instances ====== | ====== Multiple DHCP-Server instances ====== | ||
| - | It ist possible to run multiple instances of the dhcp server listening on different interfaces. | + | Having multiple DHCP-Servers running is very useful if you're dealing with [[documentation:general:network:vlan_support|VLAN's]], [[howto:use_cases:wireless:guest_ap|Guest AP]] or any kind of separating networks from another. To give each Network a different configuration of IP-Addresses, Netmasks or any settings which are provided to the clients by the DHCP-Server.\\ |
| - | + | ||
| ===== Overview ===== | ===== Overview ===== | ||
| Line 8: | Line 7: | ||
| ==== Level of difficulty === | ==== Level of difficulty === | ||
| - | Easy | + | Medium |
| ==== Related topics ==== | ==== Related topics ==== | ||
| - | * [[documentation:configuration:uci]] | + | * [[documentation:configuration:UCI]] |
| * [[documentation:configuration:config_files:config_dhcp|/etc/config/dhcp]] | * [[documentation:configuration:config_files:config_dhcp|/etc/config/dhcp]] | ||
| | | ||
| Line 25: | Line 24: | ||
| * **Add DHCP instance** | * **Add DHCP instance** | ||
| <code> | <code> | ||
| - | uci delete dhcp.guest | + | uci add dhcp dhcp |
| - | uci set dhcp.guest=dhcp | + | uci set dhcp.@dhcp[-1].interface=guest |
| - | uci set dhcp.guest.interface=guest | + | uci set dhcp.@dhcp[-1].start=62 |
| - | uci set dhcp.guest.start=62 | + | uci set dhcp.@dhcp[-1].limit=192 |
| - | uci set dhcp.guest.limit=192 | + | uci set dhcp.@dhcp[-1].leasetime=600h |
| - | uci set dhcp.guest.leasetime=600h | + | |
| </code> | </code> | ||
| + | __Note:__ The option interface defines on which interface the dhcp-server is listening for dhcp-requests. | ||
| * **Store changes** | * **Store changes** | ||
| Line 55: | Line 54: | ||
| option 'leasetime' '600h' | option 'leasetime' '600h' | ||
| </code> | </code> | ||
| + | __Note:__ The option interface defines on which interface the dhcp-server is listening for dhcp-requests. | ||
| * **Apply changes** | * **Apply changes** | ||
| - | * | ||
| <code> | <code> | ||
| /etc/init.d/dnsmasq restart | /etc/init.d/dnsmasq restart | ||