Difference between revisions of "Dhcp"

From CBLFS
Jump to navigationJump to search
 
(14 intermediate revisions by 8 users not shown)
Line 2: Line 2:
 
|-
 
|-
 
!Download Source:
 
!Download Source:
| http://gd.tuwien.ac.at/infosys/servers/isc/dhcp/dhcp-3.0.4.tar.gz
+
| http://ftp.isc.org/isc/dhcp/dhcp-{{Dhcp-Version}}.tar.gz
 
|}
 
|}
 
{| style="text-align: left; background-color: AliceBlue;"
 
{| style="text-align: left; background-color: AliceBlue;"
 
|-
 
|-
 
!Download Patch:  
 
!Download Patch:  
| http://svn.cross-lfs.org/svn/repos/patches/dhcp/dhcp-3.0.4-iproute2-1.patch
+
| http://svn.cross-lfs.org/svn/repos/patches/dhcp/dhcp-{{Dhcp-Version}}-iproute2-1.patch
 
|}
 
|}
  
 +
----
  
----
+
{{Package-Introduction|The DHCP package contains both the client and server programs for DHCP. '''dhclient''' (the client) is useful for connecting your computer to a network which uses DHCP to assign network addresses. '''dhcpd''' (the server) is useful for assigning network addresses on your private network.|http://www.isc.org/software/dhcp}}
  
 
== Dependencies ==
 
== Dependencies ==
  
 +
=== Required (If not using the iproute2 patch) ===
 +
* [[NetTools]]
  
 
== Non-Multilib ==
 
== Non-Multilib ==
Line 20: Line 23:
 
Compile the package:
 
Compile the package:
  
  patch -Np1 -i ../dhcp-3.0.4-iproute2-1.patch &&
+
  patch -Np1 -i ../dhcp-{{Dhcp-Version}}-iproute2-1.patch &&
  ./configure &&
+
  ./configure --prefix=/usr --sysconfdir=/etc \
 +
    --localstatedir=/var &&
 
  make
 
  make
  
 
Install the package
 
Install the package
  
  make LIBDIR=/usr/lib INCDIR=/usr/include install
+
  make install &&
 +
touch /var/db/dhcpd.leases
  
 
== Multilib ==
 
== Multilib ==
Line 34: Line 39:
 
Compile the package:
 
Compile the package:
  
  patch -Np1 -i ../dhcp-3.0.4-iproute2-1.patch &&
+
  patch -Np1 -i ../dhcp-{{Dhcp-Version}}-iproute2-1.patch &&
 
  ./configure &&
 
  ./configure &&
 
  make CC="gcc ${BUILD32}" &&
 
  make CC="gcc ${BUILD32}" &&
Line 44: Line 49:
 
=== N32 ===
 
=== N32 ===
  
TO BE DONE
+
Compile the package
 +
 
 +
patch -Np1 -i ../dhcp-{{Dhcp-Version}}-iproute2-1.patch
 +
./configure &&
 +
make CC="gcc ${BUILDN32}"
 +
 
 +
Install the package
 +
 
 +
make LIBDIR=/usr/lib32 INCDIR=/usr/include install
  
 
=== 64Bit ===
 
=== 64Bit ===
Line 50: Line 63:
 
Compile the package
 
Compile the package
  
  patch -Np1 -i ../dhcp-3.0.4-iproute2-1.patch
+
  patch -Np1 -i ../dhcp-{{Dhcp-Version}}-iproute2-1.patch
 
  ./configure &&
 
  ./configure &&
 
  make CC="gcc ${BUILD64}"
 
  make CC="gcc ${BUILD64}"
Line 81: Line 94:
 
=== BootScript ===
 
=== BootScript ===
  
Install the init script included in the [[blfs-bootscripts]] package.
+
Install the init script included in the [[bootscripts]] package.
  
 
  make install-dhcp
 
  make install-dhcp
 +
 +
{{Note|Make sure to change the adapter for dhcp in the bootscript}}
 +
 +
[[Category:Servers]]

Latest revision as of 21:08, 2 December 2010

Download Source: http://ftp.isc.org/isc/dhcp/dhcp-4.2.0-P1.tar.gz
Download Patch: http://svn.cross-lfs.org/svn/repos/patches/dhcp/dhcp-4.2.0-P1-iproute2-1.patch

Introduction to Dhcp

The DHCP package contains both the client and server programs for DHCP. dhclient (the client) is useful for connecting your computer to a network which uses DHCP to assign network addresses. dhcpd (the server) is useful for assigning network addresses on your private network.

Project Homepage: http://www.isc.org/software/dhcp

Dependencies

Required (If not using the iproute2 patch)

Non-Multilib

Compile the package:

patch -Np1 -i ../dhcp-4.2.0-P1-iproute2-1.patch &&
./configure --prefix=/usr --sysconfdir=/etc \
    --localstatedir=/var &&
make

Install the package

make install &&
touch /var/db/dhcpd.leases

Multilib

32Bit

Compile the package:

patch -Np1 -i ../dhcp-4.2.0-P1-iproute2-1.patch &&
./configure &&
make CC="gcc ${BUILD32}" &&

Install the package

make LIBDIR=/usr/lib INCDIR=/usr/include install

N32

Compile the package

patch -Np1 -i ../dhcp-4.2.0-P1-iproute2-1.patch
./configure &&
make CC="gcc ${BUILDN32}"

Install the package

make LIBDIR=/usr/lib32 INCDIR=/usr/include install

64Bit

Compile the package

patch -Np1 -i ../dhcp-4.2.0-P1-iproute2-1.patch
./configure &&
make CC="gcc ${BUILD64}"

Install the package

make LIBDIR=/usr/lib64 INCDIR=/usr/include install

Configuring

touch /var/state/dhcp/dhcpd.leases

cat > /etc/dhcpd.conf << "EOF"
allow unknown-clients;
server-identifier 192.168.1.254;
ddns-update-style interim;

subnet 192.168.1.0 netmask 255.255.255.0 {
option broadcast-address 192.168.1.255;
range 192.168.1.100 192.168.1.200;
default-lease-time 86400;
max-lease-time 86400;
option subnet-mask 255.255.255.0;
option domain-name-servers DNS_SERVER_NAMES;
option routers 192.168.1.254;
}
EOF


BootScript

Install the init script included in the bootscripts package.

make install-dhcp
Caution.png

Note

Make sure to change the adapter for dhcp in the bootscript
Retrieved from "?title=Dhcp&oldid=20705"