Installing and Configuring DHCP Server (DHCPd) on FreeBSD Установка та настройка DHCP-сервера (DHCPd) на FreeBSD

DHCP, the Dynamic Host Configuration Protocol, describes the means by which a system can connect to a network and obtain the necessary information for communication upon that network. DHCP, Dynamic Host Configuration Protocol, описуються за допомогою якого система може підключитися до мережі і отримати необхідну інформацію для роботи з цієї мережі.

When dhclient, the DHCP client, is executed on the client machine, it begins broadcasting requests for configuration information. Коли dhclient, клієнт DHCP, виконується на клієнтської машині, то він починає мовлення прохання про конфігурацію. By default, these requests are on UDP port 68. За замовчуванням ці запити робляться на UDP-порту 68. The server replies on UDP 67, giving the client an IP address and other relevant network information such as netmask, router, and DNS servers. Сервер відповідає на UDP 67, видаючи клієнту IP адреса та іншу відповідну інформацію мережі, такі, як маска, маршрутизатор і DNS-сервери. All of this information comes in the form of a DHCP ?lease? Вся ця інформація надходить у вигляді DHCP? Оренди? and is only valid for a certain time (configured by the DHCP server maintainer). і дійсні лише протягом певного часу (налаштовується адміністратором сервера DHCP). In this manner, stale IP addresses for clients no longer connected to the network can be automatically reclaimed. Таким чином, застарілі адреси IP для клієнтів, не підключених до мережі можуть бути автоматично відновлено.

DHCP Server (or DHCPd) is the server that provides the DHCP client the information it needed, and it's the server portion of the suite is not provided as part of FreeBSD, and so it needs to install from the net/isc-dhcp3-server port to provide this service. DHCP-сервер (або DHCPd) є сервером, який надає клієнту DHCP необхідну йому інформацію, і це серверна частина пакета є не передбачені в рамках FreeBSD, і тому необхідно встановити з net/isc-dhcp3-server Порт надавати цю послугу.

FreeBSD comes with ISC DHCP, and it comes with FreeBSD as ports net/isc-dhcp3-server. FreeBSD поставляється з ISC DHCP, і він приходить з FreeBSD як net/isc-dhcp3-server порти.

To install it, change to ports net/isc-dhcp3-server directory and execute the following command: Щоб встановити його, перейдіть у каталог з портами net/isc-dhcp3-server і виконати наступну команду:

# make install clean # Зробити нове встановлення системи

DHCPd is configured by using a configuration file, normally dhcpd.conf located at /usr/local/etc directory. DHCPd налаштовується за допомогою файлу конфігурації, як правило, розташовані в dhcpd.conf / USR / місцеві / i т.д. каталогу. Normally there is an example configuration file which is dhcpd.conf.example at the directory. Звичайно є приклад файлу конфігурації, яка є dhcpd.conf.example в каталозі. Copy dhcpd.conf.example to dhcpd.conf or create a new dhcpd.conf before proceeding to make changes on DHCP Server. Копія dhcpd.conf.example в dhcpd.conf або створити нову dhcpd.conf перед тим як продовжити вносити зміни в DHCP-сервер.

dhcpd.conf is comprised of declarations regarding subnets and hosts, and is perhaps most easily explained using an example :

option domain-name “example.com”; (1) опції доменних імен "example.com"; (1)
option domain-name-servers 192.168.4.100; (2) опції доменних імен сервера 192.168.4.100; (2)
option subnet-mask 255.255.255.0; (3) опцією-маска підмережі 255.255.255.0; (3)

default-lease-time 3600; (4) Default-оренда часу 3600; (4)
max-lease-time 86400; (5) Макс-ліз часу 86400; (5)
ddns-update-style none; (6) DDNS-Update-стилю немає; (6)

subnet 192.168.4.0 netmask 255.255.255.0 { 192.168.4.0 маска підмережі 255.255.255.0 (
range 192.168.4.129 192.168.4.254; (7) Діапазон 192.168.4.129 192.168.4.254; (7)
option routers 192.168.4.1; (8) опції маршрутизатори 192.168.4.1; (8)
} )

host mailhost { приймає поштовий сервер (
hardware ethernet 02:03:04:05:06:07; (9) апаратного Ethernet 02:03:04:05:06:07; (9)
fixed-address mailhost.example.com; (10) фіксованого адреси mailhost.example.com, (10)
} )

(1) This option specifies the domain that will be provided to clients as the default search domain. (1) Цей параметр задає домен, який буде надаватися клієнтам як домену пошуку за замовчуванням.
(2) This option specifies a comma separated list of DNS servers that the client should use. (2) Цей параметр задає список розділених комами серверів DNS, що клієнт повинен використовувати.
(3) The netmask that will be provided to clients. (3) маска, які будуть надаватися клієнтам.
(4) A client may request a specific length of time that a lease will be valid. (4) клієнт може вимагати певного часу, що оренда буде дійсним. Otherwise the server will assign a lease with this expiry value (in seconds). В іншому випадку сервер буде призначити оренди із закінченням цього значення (в секундах).
(5) This is the maximum length of time that the server will lease for. (5) Це максимальне час, що сервер буде оренду. Should a client request a longer lease, a lease will be issued, although it will only be valid for max-lease-time seconds. Якщо клієнтський запит про продовження терміну оренди, оренди буде опублікований, хоча він буде мати сенс тільки для макс-лізинг-секундного.
(6) This option specifies whether the DHCP server should attempt to update DNS when a lease is accepted or released. (6) Цей параметр визначає, чи буде сервер DHCP повинен намагатися оновити DNS при оренді приймається або звільнені. In the ISC implementation, this option is required. В реалізації ISC, необхідно цей параметр.
(7) This denotes which IP addresses should be used in the pool reserved for allocating to clients. (7) Це означає Які IP адреси не повинні використовуватися в басейні, відведені для виділення клієнтам. IP addresses between, and including, the ones stated are handed out to clients. IP адрес між ними, і в тому числі, ті заявили, видаються клієнтам.
(8) Declares the default gateway that will be provided to clients. (8) заявляє, шлюз за замовчуванням, які будуть надаватися клієнтам.
(9) The hardware MAC address of a host (so that the DHCP server can recognize a host when it makes a request). (9) апаратна адреса МАС-хоста (щоб сервер DHCP може розпізнавати господаря коли він робить запит).
(10) Specifies that the host should always be given the same IP address. (10) вказує, що хост повинен завжди мати ту ж адресу. Note that using a hostname is correct here, since the DHCP server will resolve the hostname itself before returning the lease information. Зауважимо, що використання хоста є правильним тут, оскільки сервер DHCP буде дозволити ім'я хоста сама, перш ніж повернутися відомостей про оренду.

Once you have finished writing your dhcpd.conf, you can proceed to start the server by issuing the following command: Після того як ви закінчили написання dhcpd.conf, ви можете приступити до запуску сервера, видаючи наступну команду:

# /usr/local/etc/rc.d/isc-dhcpd.sh start # / USR / місцеві / ETC / rc.d / ISC-dhcpd.sh початок

Should you need to make changes to the configuration of your server in the future, it is important to note that sending a SIGHUP signal to dhcpd does not result in the configuration being reloaded, as it does with most daemons. Якщо Вам необхідно внести зміни в конфігурацію сервера в майбутньому, важливо зазначити, що передача сигналу SIGHUP для DHCPd не приводить в конфігурації час Reloaded, як це відбувається з більшістю демонів. A SIGTERM signal to stop the process, and then restart it using the command above. Сигнал SIGTERM для зупинки процесу, а потім запустити його за допомогою команди вище. For example: Наприклад:

# ps wax | grep dhcpd # PS віск | Grep DHCPd
pid of dhcpd will be shown PID з DHCPd буде показаний

# kill -15 (pid of dhcpd) # Вбити -15 (PID з DHCPd)

IMPORTANT : The page is machine translated and provided "as is" without warranty. ВАЖЛИВО: Сторінка машина переведена і надаються "як є" без гарантії. Machine translation may be difficult to understand. Машинний переклад може бути важким для розуміння. Please refer to Будь ласка, зверніться до original English article оригінальний англійська статтю whenever possible. коли це можливо.


Leave a Reply Написати відповідь

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> Ви можете використовувати ці теги: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <справі DateTime = ""> <em> <i> <q Cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. Підписатися на коментарі функція була відключена. To receive notification of latest comments posted, subscribe to Щоб отримувати повідомлення про останні коментарях, підписатися My Digital Life Comments RSS feed Моя Цифрова життя Коментарі RSS Feed or або register to receive Увійдіть, щоб отримувати new comments in daily email digest. нові коментарі в щоденній електронній пошті.
Custom Search

New Articles Нові статті

Incoming Search Terms for the Article Вхідні терміни пошуку для статті

freebsd dhcp server FreeBSD сервера DHCP - -- dhcp server freebsd DHCP-сервер FreeBSD - -- freebsd restart dhcpd перезапустити DHCPd FreeBSD - -- freebsd dhcpd FreeBSD DHCPd - -- freebsd dhcp FreeBSD DHCP - -- bsd restart dhcpd перезапустити DHCPd BSD - -- restart dhcpd on bsd перезапустити DHCPd на BSD - -- dhcpd freebsd DHCPd FreeBSD - -- openbsd reload dhcpd.conf OpenBSD dhcpd.conf Reload - -- dhcp freebsd DHCP FreeBSD - -- dhcpd freebsd assign mac DHCPd FreeBSD призначити Mac - -- dhcp on freebsd DHCP на FreeBSD - -- FreeBSD + dhcp.conf FreeBSD + dhcp.conf - -- dhcp server mysql MySQL сервером DHCP - -- dhcpd.conf configure windows vista dhcpd.conf налаштувати Windows Vista - -- disable dhcp in freebsd відключити DHCP в FreeBSD - -- freebsd dhcpd.conf FreeBSD dhcpd.conf - -- freebsd configuring dhcp FreeBSD Конфігурування DHCP - -- freebsd +dhcp FreeBSD + DHCP - -- removing and reconfiguring dhcp afresh видалення і реконфігурації DHCP-новому - -- vmware esx server dhcpd VMware ESX сервер DHCPd - -- dhcpd restart freebsd FreeBSD перезапустити DHCPd - -- DHCP sig hup DHCP SIG HUP - -- freebsd configure dhcp FreeBSD DHCP налаштувати - -- freebsd dhcp server install ports FreeBSD сервера DHCP установка портів - -- freebsd install dhcpd-pools Встановити DHCPd FreeBSD-басейни - -- freebsd dhcp mac FreeBSD, Mac DHCP - -- reload dhcpd.conf without stopping dhcp Reload dhcpd.conf без зупинки DHCP - -- turn on dhcp on bsd Включити DHCP на BSD - -- рестарт dhcp freebsd рестарт DHCP FreeBSD - -- change dhcp server freebsd Зміна сервера DHCP FreeBSD - -- configure dhcp server freebsd Налаштування DHCP сервера FreeBSD - -- dhcp server setup freebsd Налаштування DHCP сервера FreeBSD - -- dhcpd freebsd port DHCPd портів FreeBSD - -- freebsd dhcp ports Портів FreeBSD DHCP - -- freebsd ports: dhcp портів FreeBSD: DHCP - -- freebsd dhcpd log not rotating FreeBSD DHCPd журналу не обертається - -- freebsd "isc-dhcpd" FreeBSD "ISC-DHCPd" - -- freebsd dhcpd port DHCPd портів FreeBSD - -- free bsd restartowanie dhcp Free BSD DHCP restartowanie - -- how to install dhcp server freeBSD Як встановити DHCP-сервера FreeBSD - -- install dhcpd freebsd Встановити DHCPd FreeBSD - -- vmware dhcpd.conf default gateway VMware dhcpd.conf шлюз за замовчуванням - -- dhcp freebsd example DHCP FreeBSD приклад - -- freebsd isc-dhcpd FreeBSD ISC-DHCPd - -- freebsd dhcp client command FreeBSD команди клієнт DHCP - -- freebsd 7 reconfigure dhcpd FreeBSD 7 переналаштувати DHCPd - -- freebsd isc-dhcpd.sh start FreeBSD ISC-dhcpd.sh початок - -- freebsd isc dhcp server FreeBSD ISC DHCP сервера - -- how to install dhcp3-server in freebsd Як встановити dhcp3-сервера в FreeBSD - --