VitualBox Setup
CentOS as Server
Network Adapter 1(eth0) == Bridged Adater
Network Adapter 2(eth1) == Internal Network, Name: auth0, Promiscuous Mode: Allow All.
Ubuntu as Client
Network Adapter 1(eth0) == Internal Network, Name: auth0, Promiscuous Mode: Allow All.
DHCP server setup
yum -y install dhcp —> install DHCP packages
vim /etc/sysconfig/dhcpd
DHCPDARGS=eth1 —>add yr interface name for listen
cp /usr/share/doc/dhcp-4.1.1/dhcpd.conf.sample /etc/dhcp/dhcpd.conf —> cppy sample dhcpd config
vim /etc/dhcp/dhcpd.conf —> to edit dhcpd config file (I delete it all and insert as below according to yr need)
ddns-update-style none;
authoritative;
log-facility local7;
default-lease-time 600;
max-lease-time 7200;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.20.255;
option routers 172.16.10.1;
option domain-name-servers 192.168.20.1;
option domain-name “centos”;
subnet 192.168.20.0 netmask 255.255.255.0 {
range 192.168.20.10 192.168.20.100;
}
service dhcpd restart —> restart DHCP server
chkconfig dhcpd on —> make sure that will auto start