DHCP configuration


Im sorry for this dummy question but Ive tried everything and nothing worked - I`ve obviously missed something.

I`ve a computer running opensuse 11.0. It has two ethernet cards. One was configured for outside world and uses fixed IP - ex. It has DNS servers - and, and a gateway -

Now I want to configure the second card for DHCP in small internal network.
Ive set the fixed ip - Then Ive made some DHCP configuration. My dhcpd.conf looks like this

option domain-name “abs”;
option domain-name-servers;
option routers;
ddns-update-style none;
default-lease-time 345600;
subnet netmask {
default-lease-time 345600;
max-lease-time 172800;
host leiden {
hardware ethernet 00:1F:C6:B4:CA:E4;

As you might have guessed - IT DOES NOT WORK!
That means when I connect a computer to this server and type
ifdown eth0
ifup eth0
it aquires a correct ip - - but I still can not connect neither to my server, nor to outside world.

I`ve deep conserns about the following lines:

1/ option domain-name-servers;
I`ve no DNS software installed on my computer. Should I specify here the outworld DNS of the first card - and ? ( I actually tried that already and it did work either)

2/ option routers; ???

So I guess that my problem is somewere here. Could you please give me a tip.

Thanks. I appreciate your time.

In a subnet, the first address is the network address and should never be assigned to any host. The last address is the broadcast address and also should never be assigned to any host.

You have assigned the network address .0 to your SUSE box. Change it to .1. Also shrink the dynamic range and save some static addresses for later, do you really need 253 other hosts getting an address by DHCP on the LAN?

If you are not running a DNS proxy then you can use the external DNS servers, provided your SUSE gateway masquerades the connections.

The router is the SUSE box itself and it should be set to masquerade the LAN to the outside world.

You might want to consult the Wiki for a document on setting up SUSE as a router.

Thank you. I`ve finally figured out the problem.

So for the record for those who might experience the same trouble I am writing a quick howto.

AIM: to incorporate several computers into a small local network with the ability to connect to global internet

1/ “server” computer with two network cards - one for internal network and one for external
2/ dhcp-server package - any distribution you like. I used ISC distribution of dhcp. It may be installed from yast directly, with zypper (execute in bash shell: >zypper in dhcp-server), or you might download the latest source version from the official internet site directly.
3/ “client” computers for the local network

1/ Configure network cards. Open yast -> network devices -> network settings. Pick a card you like - now we will configure it for internal network. Press EDIT, on address tab choose “Statically assigned IP Address” and type “anynameyoulike” accordingly for all the three field.
Now press NEXT and choose the second ethernet card. You should configure in considering your global network connection plan. Consult your network administrator or ISP representative.

2/ Configure DHCP server
Open yast -> Network services -> DHCP Server
If you do not see this button then you do not have dhcp server yast plugin installed. Use yast or zypper for this purpose.
I will not give any direct instructions on that stage because the interface might differ in case of different versions, though generaly it has the following steps:

  • choose the network card for dhcp - choose the one you configured as
  • specify configuration options
    Eventually dhcp configuration file /etc/dhcpd.conf should look like this:

option domain-name “abs.cmm.msu.ru”; #Your domain name
ddns-update-style none; #If you do not use dns automatic update
default-lease-time 14400;

#Now configure your subnetwork
#This is for the C-class network with possible ip range 192.168.168.[1-254]
subnet netmask {
default-lease-time 14400;
max-lease-time 172800;

#These are the ips for the first network card you have #configured for internal networking
option routers;
server-name “”;

#This is the most difficult part
#I used outside DNS of my institution. For that purpose I had to #set masquerading option in the firewall
#You might want to install DNS instead

option domain-name-servers,;

#I do not want dynamic ips in my network so I set them accordingly to their MAC hardware address

host leiden {
hardware ethernet 00:1F:C6:B4:CA:E4;

Now you are done

services dhcpd restart (or may want to start dhcp directly from yast).

To check if dhcpd is running type

ps -C dhcpd