Installing and Configuring DHCP Server (DHCPd) on FreeBSD Diegimas ir konfigūravimas DHCP serveris (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, aprašo priemones, kurios sistemos gali prisijungti prie tinklo ir gauti reikiamą informaciją, bendrauti, kai šio tinklo.
When dhclient, the DHCP client, is executed on the client machine, it begins broadcasting requests for configuration information. Kai dhclient, DHCP klientas, yra įvykdyti kliento kompiuteryje, jis pradeda transliuoti prašymus dėl informacijos apie konfigūracijos. By default, these requests are on UDP port 68. Numatyta, kad šie prašymai dėl UDP prievadas 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. Serverio atsakymai UDP 67, nurodant kliento IP adresą ir kitas atitinkamas tinklo informaciją, pavyzdžiui, tinklo kaukę, maršrutizatorius ir DNS serverius. All of this information comes in the form of a DHCP ?lease? Visos šios informacijos dalis yra DHCP? Nuomos forma? and is only valid for a certain time (configured by the DHCP server maintainer). ir galioja tik tam tikrą laiką (sukonfigūruotas DHCP serverio lydi). In this manner, stale IP addresses for clients no longer connected to the network can be automatically reclaimed. Tokiu būdu, pasenusi IP adresus klientams jau prijungtas prie tinklo automatiškai gali būti perdirbtos.
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 serverio (ar dhcpd) iš serverio, kuris teikia DHCP kliento informacijos, kuri reikalinga, ir tai serverio dalis, komplekte nėra numatytas kaip dalis FreeBSD, ir todėl ją reikia įdiegti iš net/isc-dhcp3-server uosto teikti šią paslaugą.
FreeBSD comes with ISC DHCP, and it comes with FreeBSD as ports net/isc-dhcp3-server. FreeBSD ateina su ISC DHCP, ir ji ateina su FreeBSD uostai net/isc-dhcp3-server.
To install it, change to ports net/isc-dhcp3-server directory and execute the following command: Norėdami įdiegti, pakeisti uostų net/isc-dhcp3-server katalogą ir įvykdykite šią komandą:
# make install clean # Make install švarus
DHCPd is configured by using a configuration file, normally dhcpd.conf located at /usr/local/etc directory. Dhcpd yra sukonfigūruotas naudojant konfigūracijos failas, paprastai dhcpd.conf įsikūręs / usr / local / etc kataloge. Normally there is an example configuration file which is dhcpd.conf.example at the directory. Paprastai yra pavyzdys konfigūracijos failas, kuris yra dhcpd.conf.example į katalogą. Copy dhcpd.conf.example to dhcpd.conf or create a new dhcpd.conf before proceeding to make changes on DHCP Server. Kopijuoti dhcpd.conf.example į dhcpd.conf arba sukurkite naują dhcpd.conf prieš pradedant keisti DHCP serverio.
dhcpd.conf is comprised of declarations regarding subnets and hosts, and is perhaps most easily explained using an example : dhcpd.conf sudaro pareiškimai apie antrinis ir šeimininkai, ir turbūt lengviausiai aiškinama, naudojant, pavyzdžiui:
option domain-name “example.com”; (1) option domain-name "example.com"; (1)
option domain-name-servers 192.168.4.100; (2) option domain-name-servers 192.168.4.100; (2)
option subnet-mask 255.255.255.0; (3) option subnet-mask 255.255.255.0; (3)
default-lease-time 3600; (4) default-lease-time 3.600; (4)
max-lease-time 86400; (5) max-lease-time 86400; (5)
ddns-update-style none; (6) DDNS-update-style none; (6)
subnet 192.168.4.0 netmask 255.255.255.0 { subnet 192.168.4.0 netmask 255.255.255.0 (
range 192.168.4.129 192.168.4.254; (7) iki 192.168.4.129 192.168.4.254; (7)
option routers 192.168.4.1; (8) option routers 192.168.4.1; (8)
} )
host mailhost { priimančiosios mailhost (
hardware ethernet 02:03:04:05:06:07; (9) hardware ethernet 02:03:04:05:06:07; (9)
fixed-address mailhost.example.com; (10) fixed-address mailhost.example.com; (10)
} )
(1) This option specifies the domain that will be provided to clients as the default search domain. (1) Šis parametras nurodo sritis, kurios bus teikiamos klientams kaip numatytoji paieškos sritis.
(2) This option specifies a comma separated list of DNS servers that the client should use. (2) Ši parinktis nurodo kableliais atskirtą sąrašą DNS serverius, kad klientas turi naudoti.
(3) The netmask that will be provided to clients. (3) tinklo kaukę, kuri bus teikiama klientams.
(4) A client may request a specific length of time that a lease will be valid. (4) klientas gali prašyti konkrečios trukmės laikotarpį, kad nuoma bus galiojantis. Otherwise the server will assign a lease with this expiry value (in seconds). Priešingu atveju serveris bus priskirti nuoma su priemonių galiojimo pabaigos vertė (sekundėmis).
(5) This is the maximum length of time that the server will lease for. (5) Tai yra didžiausias ilgis laiko, kad serverio nuomos. Should a client request a longer lease, a lease will be issued, although it will only be valid for max-lease-time seconds. Jei klientas prašo ilgesnio nuomos, nuomos, bus išleistos, nors tai bus tik galioja max-lease-time sekundės.
(6) This option specifies whether the DHCP server should attempt to update DNS when a lease is accepted or released. (6) Šis parametras nurodo, ar DHCP serveris turi bandyti atnaujinti DNS, kai nuoma yra priimama, ar paleistas. In the ISC implementation, this option is required. Visų ISC įgyvendinimą, šis variantas yra privalomi.
(7) This denotes which IP addresses should be used in the pool reserved for allocating to clients. (7) Tai reiškia kurių IP adresai turėtų būti naudojami baseinas saugomos paskirstymo klientams. IP addresses between, and including, the ones stated are handed out to clients. IP adresai nuo ir įskaitant tuos, kurie pareiškė, yra įteikė klientams.
(8) Declares the default gateway that will be provided to clients. (8) pareiškia, kad default gateway bus teikiama klientams.
(9) The hardware MAC address of a host (so that the DHCP server can recognize a host when it makes a request). (9) aparatūros MAC adresą priimančiojoje (kad DHCP serveris gali atpažinti priimančiosios kada ji prašymą).
(10) Specifies that the host should always be given the same IP address. (10) Nurodoma, kad priimančiosios visada turėtų būti suteiktas toks pat IP adresas. Note that using a hostname is correct here, since the DHCP server will resolve the hostname itself before returning the lease information. Atkreipkite dėmesį, kad pavadinimas yra teisingas čia, nes DHCP serveris bus išspręsti prieglobos pati prieš grįžtant nuomos informacija.
Once you have finished writing your dhcpd.conf, you can proceed to start the server by issuing the following command: Baigę rašyti dhcpd.conf, galite tęsti paleisti serverio išleidžiant šią komandą:
# /usr/local/etc/rc.d/isc-dhcpd.sh start # / Usr / local / etc / rc.d / isc-dhcpd.sh pradžia
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. Jeigu jums reikia pakeisti savo serverio konfigūravimo ateityje, svarbu atkreipti dėmesį, kad siunčiant SIGHUP signalas dhcpd nesukelia konfigūracija yra perkrauta, nes ji veikia su dauguma demonai. A SIGTERM signal to stop the process, and then restart it using the command above. SIGTERM signalą sustabdyti procesą, tada paleiskite jį naudodami komandą, nurodytą aukščiau. For example: Pavyzdžiui
# ps wax | grep dhcpd # Ps vaškas | grep dhcpd
pid of dhcpd will be shown PID iš dhcpd bus rodomas
# kill -15 (pid of dhcpd) # Nužudyti -15 (PID iš dhcpd)
IMPORTANT : The page is machine translated and provided "as is" without warranty. DĖMESIO: Šis puslapis yra mašina išvertė ir pateikiama "kaip yra" be garantijų. Machine translation may be difficult to understand. Automatinis vertimas gali būti sunku suprasti. Please refer to Remkitės original English article originalas anglų straipsnis whenever possible. jei įmanoma.
Related Articles Susiję straipsniai
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 2 Diegimas web serveris FreeBSD 6,0 su Apache 2.2, MySQL 5.0, PHP 5 - 2 dalis
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 5 Diegimas web serveris FreeBSD 6,0 su Apache 2.2, MySQL 5.0, PHP 5 - 5 dalis
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 3 Diegimas web serveris FreeBSD 6,0 su Apache 2.2, MySQL 5.0, PHP 5 - 3 dalis
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 4 Diegimas web serveris FreeBSD 6,0 su Apache 2.2, MySQL 5.0, PHP 5 - 4 dalis
- Installing Web Server in FreeBSD 6.0 with Apache 2.2, MySQL 5.0 and PHP 5 – Part 1 Diegimas web serveris FreeBSD 6,0 su Apache 2.2, MySQL 5.0, PHP 5 - 1 dalis
- Tips of How to Switch between DHCP and Static IP Network Automatically in Windows Patarimai, kaip persijungti tarp DHCP ir statinio IP Network Automatiškai Windows
- FreeBSD 6.0 on VMware Server Time and Clock Slow Down Ant VMware serverio laikas ir laikrodžių 6,0 FreeBSD Slow Down
- Could Not Find Valid System Volume Error When Installing Windows Server 2008 (R2) Nepavyko rasti galiojanti sistema tomas Klaida Diegiant "Windows Server 2008 (R2)
- Missing CD/DVD Device Driver Problem While Installing Vista on VMWare Server/ESX Trūksta CD / DVD įrenginių tvarkyklės problema, kai diegimas Vista VMware Server / ESX
- Checking Free Disk Space on FreeBSD Server Tikrinimas laisvos vietos diske, FreeBSD serverio









































