This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
сервис_dhcp [2024/04/30 14:02] val [isc-kea] |
сервис_dhcp [2024/11/30 16:33] (current) val [Мониторинг выданных адресов] |
||
---|---|---|---|
Line 40: | Line 40: | ||
option domain-name "corpX.un"; | option domain-name "corpX.un"; | ||
+ | #option domain-search "jet.msk.su","service.jet.msk.su","jetinf.jet.msk.su"; | ||
option domain-name-servers 192.168.X.10; | option domain-name-servers 192.168.X.10; | ||
#option domain-name-servers 192.168.X.12; | #option domain-name-servers 192.168.X.12; | ||
Line 109: | Line 110: | ||
max-lease-time 7200; | max-lease-time 7200; | ||
} | } | ||
+ | |||
+ | #host node3 {hardware ethernet 08:00:27:12:34:53;fixed-address 192.168.X.3;} | ||
+ | #host node4 {hardware ethernet 08:00:27:12:34:54;fixed-address 192.168.X.4;} | ||
+ | #host node5 {hardware ethernet 08:00:27:12:34:55;fixed-address 192.168.X.5;} | ||
+ | #host node6 {hardware ethernet 08:00:27:12:34:56;fixed-address 192.168.X.6;} | ||
+ | #host node7 {hardware ethernet 08:00:27:12:34:57;fixed-address 192.168.X.7;} | ||
</code> | </code> | ||
Line 190: | Line 197: | ||
===== Мониторинг выданных адресов ===== | ===== Мониторинг выданных адресов ===== | ||
+ | * [[https://stackoverflow.com/questions/2142824/parse-a-dhcpd-lease-file-with-bash|Parse a dhcpd.lease File with Bash]] | ||
==== Debian/Ubuntu ==== | ==== Debian/Ubuntu ==== | ||
<code> | <code> | ||
Line 276: | Line 284: | ||
{ | { | ||
"name": "domain-name-servers", | "name": "domain-name-servers", | ||
- | "data": "192.168.13.10" | + | "data": "192.168.X.10" |
}, | }, | ||
+ | # not work in windows | ||
{ | { | ||
"name": "domain-search", | "name": "domain-search", | ||
- | "data": "corp13.un" | + | "data": "corpX.un,isp.un" |
+ | }, | ||
+ | { | ||
+ | "name": "domain-name", | ||
+ | "data": "corpX.un" | ||
} | } | ||
- | |||
], | ], | ||
"subnet4": [ | "subnet4": [ | ||
{ | { | ||
- | "subnet": "192.168.113.0/24", | + | "id": 1, |
- | "pools": [ { "pool": "192.168.113.100 - 192.168.113.109" } ], | + | "subnet": "192.168.100+X.0/24", |
+ | "pools": [ { "pool": "192.168.100+X.100 - 192.168.100+X.109" } ], | ||
"option-data": [ | "option-data": [ | ||
{ | { | ||
"name": "routers", | "name": "routers", | ||
- | "data": "192.168.113.1" | + | "data": "192.168.100+X.1" |
} | } | ||
] | ] | ||
Line 319: | Line 331: | ||
# service kea-dhcp4-server status | # service kea-dhcp4-server status | ||
+ | |||
+ | # cat /var/lib/kea/kea-leases4.csv | ||
</code> | </code> | ||