<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>OpenBSD and FreeBSD resources &#187; DHCP</title>
	<atom:link href="http://purebsd.com/tag/dhcp/feed" rel="self" type="application/rss+xml" />
	<link>http://purebsd.com</link>
	<description></description>
	<lastBuildDate>Tue, 01 Jun 2010 06:01:11 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
		<item>
		<title>Setting up a DHCP server</title>
		<link>http://purebsd.com/setting-up-a-dhcp-server.html</link>
		<comments>http://purebsd.com/setting-up-a-dhcp-server.html#comments</comments>
		<pubDate>Tue, 01 Jun 2010 05:05:29 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Daemons]]></category>
		<category><![CDATA[OpenBSD]]></category>
		<category><![CDATA[DHCP]]></category>
		<category><![CDATA[server]]></category>
		<category><![CDATA[Setting up]]></category>

		<guid isPermaLink="false">http://purebsd.com/?p=39</guid>
		<description><![CDATA[This is a guide to the (hopefully) succesful configuration and usage of the DHCP server distributed with the OpenBSD base install. Follow these pointers: Edit /etc/rc.conf.local to start the DHCP server automatically: dhcpd_flags="-q" # for normal use: "-q" Create/edit the file /etc/dhcpd.conf to configure dhcpd: # $OpenBSD: dhcpd.conf,v 1.1 1998/08/19 04:25:45 form Exp $ # # DHCP server [...]]]></description>
			<content:encoded><![CDATA[<p>This is a guide to the (hopefully) succesful configuration and usage of the DHCP server distributed with the OpenBSD base install.</p>
<p>Follow these pointers:</p>
<ol type="1">
<li>Edit <code>/etc/rc.conf.local</code> to start the DHCP server automatically:
<p><code> dhcpd_flags="-q" # for normal use: "-q"<br />
</code></li>
<li>Create/edit the file <code>/etc/dhcpd.conf</code> to configure <code>dhcpd</code>:
<p><code> # $OpenBSD: dhcpd.conf,v 1.1 1998/08/19 04:25:45 form Exp $<br />
#<br />
# DHCP server options.<br />
# See dhcpd.conf(5) and dhcpd(8) for more information.</p>
<p>shared-network LOCAL-NET {<br />
option routers 10.0.0.3;<br />
option domain-name "intranet.atomicvoid.net";<br />
option domain-name-servers 10.0.0.3;</p>
<p>subnet 10.0.0.0 netmask 255.255.255.0 {<br />
range 10.0.0.100 10.0.0.200;<br />
}</p>
<p>host miranda {<br />
hardware ethernet 00:00:39:3b:68:0d;<br />
fixed-address miranda.intranet.atomicvoid.net;<br />
}</p>
<p>host andromeda {<br />
hardware ethernet 00:50:fc:0c:3e:32;<br />
fixed-address andromeda.intranet.atomicvoid.net;<br />
}<br />
}<br />
</code><br />
For a more detailed working example, see my <a href="hhttp://www.purebsd.com/dhcpd.conf.txt">dhcpd.conf file</a>.</p>
<p>The &#8220;host&#8221; directives inform the DHCP server to allocate a &#8220;fixed-address&#8221; to requests with a MAC address equal to the one listed by &#8220;hardware ethernet&#8221;.<br />
The &#8220;subnet&#8221; directive informs the DHCP server that all DHCP requests result in a allocation of an IP address in the range of [10.0.0.100 - 10.0.0.200] if a client&#8217;s MAC address is not listed by one of the &#8220;host&#8221; directives.</li>
<li>Create/edit the file <code>/etc/dhcpd.interfaces</code> to list the interfaces <code>dhcpd</code> should listen on for DHCP requests:
<p><code> # $OpenBSD: dhcpd.interfaces,v 1.1 1998/08/19 04:25:45 form Exp $<br />
#<br />
# List of network interfaces served by dhcpd(8).<br />
#<br />
# ep0<br />
# ed0 le0<br />
# de1<br />
xl0<br />
</code><br />
In this case, only DHCP request entering via the interface <code>xl0</code> will be seen and handled by the DHCP daemon.</li>
<li>Reboot the system to have the changes take effect. Alternately, you can execute
<p><code> /usr/sbin/dhcpd -q xl0<br />
</code><br />
to start the DHCP server. Option &#8220;-q&#8221; quiets the chatter of the DHCP server and &#8220;xl0&#8243; is the interface on which the DHCP server should listen for requests.</li>
<li>Check <code>/var/log/daemon</code> if the DHCP server was started succesfully.</li>
</ol>
]]></content:encoded>
			<wfw:commentRss>http://purebsd.com/setting-up-a-dhcp-server.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

