Installing and Configuring DHCP Server (DHCPd) on FreeBSD התקנה והגדרת התצורה DHCP Server (DHCPd) on 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 ומידע רלוונטיים אחרים ברשת כגון netmask, נתב, ואת שרתי ה-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 Server (או 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 # Make install נקי

DHCPd is configured by using a configuration file, normally dhcpd.conf located at /usr/local/etc directory. DHCPd מוגדר באמצעות קובץ התצורה, בדרך כלל dhcpd.conf הממוקם usr / local / etc directory. 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 Server.

dhcpd.conf is comprised of declarations regarding subnets and hosts, and is perhaps most easily explained using an example : dhcpd.conf מורכב הצהרות בנוגע לרשתות משנה ואת המארחים, והוא אולי הכי בקלות הסביר באמצעות דוגמה:

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) ברירת המחדל-זמן החכירה-3600; (4)
max-lease-time 86400; (5) max-lease-86400 זמן; (5)
ddns-update-style none; (6) DDNS-עדכון-סגנון לא; (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) טווח 192.168.4.129 192.168.4.254; (7)
option routers 192.168.4.1; (8) נתבים אפשרות 192.168.4.1; (8)
} )

host mailhost { 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) netmask כי יסופקו ללקוחות.
(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. צריך בקשת הלקוח חכירה ארוך, חכירה יונפקו, אם כי זה יהיה רק תקף Max-החכירה-זמן שניות.
(6) This option specifies whether the DHCP server should attempt to update DNS when a lease is accepted or released. (6) אפשרות זו מציינת האם שרת DHCP צריכים לנסות לעדכן שליטת כאשר חכירה מקובל או שוחרר. 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) החומרה כתובות MAC של מחשב מארח (כך שרת DHCP יכול לזהות מארח כאשר זה גורם בקשה).
(10) Specifies that the host should always be given the same IP address. (10) מציין כי המארחת צריכה להיות תמיד נתון אותה כתובת IP. 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 / local / 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 אינו תוצאה בתצורת להיות מחדש, כפי שהיא עושה עם daemons ביותר. 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> <del 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 dhcpd FreeBSD dhcpd - -- freebsd dhcp DHCP FreeBSD - -- freebsd dhcp server שרת DHCP FreeBSD - -- dhcpd freebsd dhcpd FreeBSD - -- dhcp freebsd DHCP FreeBSD - -- freebsd restart dhcpd FreeBSD מחדש dhcpd - -- dhcp server freebsd שרת DHCP FreeBSD - -- freebsd dhcpd.conf dhcpd.conf FreeBSD - -- restart dhcpd freebsd מחדש dhcpd FreeBSD - -- dhcp on freebsd DHCP on FreeBSD - -- freebsd dhcpd restart FreeBSD dhcpd מחדש - -- dhcp server mysql MySQL שרת DHCP - -- freebsd dhcp restart DHCP FreeBSD מחדש - -- restart dhcp freebsd DHCP מחדש FreeBSD - -- dhcp mysql MySQL DHCP - -- dhcpd.conf freebsd dhcpd.conf FreeBSD - -- freebsd dhcp configuration תצורה DHCP FreeBSD - -- freebsd isc dhcp ISC DHCP FreeBSD - -- bsd dhcp server שרת DHCP BSD - -- freebsd dhcp server install שרת DHCP להתקין את FreeBSD - -- isc-dhcpd freebsd ISC dhcpd-FreeBSD - -- install dhcp server freebsd להתקין שרת DHCP FreeBSD - -- freebsd dhcp.conf dhcp.conf FreeBSD - -- bsd dhcpd BSD dhcpd - -- dhcpd bsd dhcpd BSD - -- dhcpd restart freebsd dhcpd מחדש FreeBSD - -- dhcpd on freebsd dhcpd on FreeBSD - -- dhcp+freebsd DHCP + FreeBSD - -- installing and configuring DHCP התקנה והגדרת התצורה של DHCP - -- freebsd isc-dhcpd FreeBSD-ISC dhcpd - -- install dhcpd freebsd התקנת FreeBSD dhcpd - -- dhcpcd freebsd dhcpcd FreeBSD - -- dhcp in freebsd DHCP ב-FreeBSD - -- freebsd dhcp config config-DHCP FreeBSD - -- install dhcp freebsd DHCP להתקין את FreeBSD - -- freebsd restart dhcp FreeBSD מחדש DHCP - -- isc dhcp freebsd ISC DHCP FreeBSD - -- FreeBSD setup DHCP FreeBSD ההתקנה DHCP - -- freebsd dhcpd server שרת dhcpd FreeBSD - -- dhcp di freebsd DHCP די FreeBSD - -- freebsd install dhcpd FreeBSD להתקין dhcpd - -- dhcp freebsd DHCP FreeBSD - -- setting dhcp on freebsd הגדרת DHCP ב FreeBSD - -- setting dhcp freebsd הגדרת DHCP FreeBSD - -- isc dhcpd freebsd ISC dhcpd FreeBSD - -- dhcp server on freebsd שרת DHCP על FreeBSD - -- installing dhcp on freebsd התקנת DHCP on FreeBSD - -- configure DHCP on freebsd להגדיר DHCP על FreeBSD - -- install dhcpd on freebsd להתקין dhcpd on FreeBSD - -- bsd restart dhcpd BSD מחדש dhcpd - --