• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

dhcp server?

Everytime I try to run Dhcpd, I get a message saying that I need to declare the subnet for my static ip address(192.168.1.83). The static ip address is for the server itself. Anyone know what I'm doing wrong?
 
dhcp3-server

I edited the dhcpd.conf like this


default-lease-time 600;
max-lease-time 7200;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.1.255;
option routers 192.168.1.1;
option domain-name-servers ;
option domain-name;

subnet 192.168.1.0 netmask 255.255.255.0 {
range 192.168.1.53 192.168.1.80;

}
 
AFAIK there is no reservation statement, you use a host definition with a fixed-address statement to declare a reserved address. And it shouldn't be inside subnet statement, or at least it doesn't have to be because it's outside and it works here.
 
Was that your entire, current dhcpd.conf file you posted above? If not, post it. If so, I don't see any problem with it (though the empty option lines are weird) and I'd guess the problem is somewhere else in your network configuration. Perhaps a rogue /etc/hosts entry or a DNS conflict or something. You shouldn't need to put anything in the config file about the DHCP server's IP address, because the server certainly isn't using itself to find its own IP. The message you mentioned in the OP isn't telling you to reserve the server's IP address - it's doing a sanity check. When dhcpd starts, it's checking to make sure that the address of the interface it's running on falls in the subnet declaration you provide. From what I can see of your config file that part is OK - 192.168.1.83 is inside the 192.168.1/24 subnet you provided. That's why I'm wondering if something else in your network configuration is inconsistent. Maybe dhcpd thinks the interface address is something other than 192.168.1.83 and is choking because of it.
 
eth0- is the interface for which I'm serving dhcp request on.
eth1- is set to static ip address

Every time I run dhcpd, It tells me to declare which subnet the interface eth1 is attached to. However, I made sure that the dhcp was set to listening to eth0.
 
Originally posted by: nonnormman
eth0- is the interface for which I'm serving dhcp request on.
eth1- is set to static ip address
Perhaps you're implying this, but both of those should be static IP addresses. The listening interface needs to be up and running with a static IP before dhcpd can listen on it.

Every time I run dhcpd, It tells me to declare which subnet the interface eth1 is attached to. However, I made sure that the dhcp was set to listening to eth0.
If eth0 has a static IP assigned (as stated above) then you're not indicating the listening interface correctly when you're starting dhcpd. Dhcpd doesn't care about interfaces other than the one(s) it's listening on. So double-check your dhcpd startup configuration (probably /etc/defaults/dhcpd) to make sure you're correctly listing the interfaces. Also make sure that the interfaces are actually numbered the way you say they are.

 
If I have two Nics, wouldn't I need both in order to use the system as a server. The first Nic would connect the server to internet and the second would give out the ip address'.
 
When you start dhcpd3 (assuming you're using v3 of the ISC DHCP daemon and the binary is called that) you should specify the interface to listen on, i.e. 'dhcpd3 -q eth0'.
 
Originally posted by: Nothinman
When you start dhcpd3 (assuming you're using v3 of the ISC DHCP daemon and the binary is called that) you should specify the interface to listen on, i.e. 'dhcpd3 -q eth0'.

I'm using Dhcpd, but I did specify which interface I was using in the /etc/default/dhcp directory. When I type touch /var/state/dhcp/dhcpd.leases to create a lease file, It says it doesn't exist. Should I use xemacs to create the file instead?
 
The file should be created by the daemon on startup (or at least when it gives out it's first lease) and it's in /var/lib/dhcp3 on my system.
 
Originally posted by: nonnormman
I'm using Dhcpd, but I did specify which interface I was using in the /etc/default/dhcp directory.
How precisely did you do that? What does it say in the file you edited or created? Post the details here exactly. From everything you've described, it sounds like you're not specifying the interface correctly despite your belief that you have.
When I type touch /var/state/dhcp/dhcpd.leases to create a lease file, It says it doesn't exist. Should I use xemacs to create the file instead?
You don't need to do anything with the leases file manually. The daemon will take care of that on its own.

Also, you still haven't said whether the config file you posted earlier is what you're currently using. Knowing what distribution this is might also be helpful.

 
Originally posted by: cleverhandle
Originally posted by: nonnormman
I'm using Dhcpd, but I did specify which interface I was using in the /etc/default/dhcp directory.
How precisely did you do that? What does it say in the file you edited or created? Post the details here exactly. From everything you've described, it sounds like you're not specifying the interface correctly despite your belief that you have.
When I type touch /var/state/dhcp/dhcpd.leases to create a lease file, It says it doesn't exist. Should I use xemacs to create the file instead?
You don't need to do anything with the leases file manually. The daemon will take care of that on its own.

Also, you still haven't said whether the config file you posted earlier is what you're currently using. Knowing what distribution this is might also be helpful.

INTERFACE="eth1" is what the file looks like and I'm using regular dhcpd with the dhcp-server.

Yes, I'm using the config file posted earlier. I'm using the debian distribution of linux.
 
Originally posted by: nonnormman
INTERFACE="eth1" is what the file looks like and I'm using regular dhcpd with the dhcp-server.
You said before that you wanted to serve requests on eth0. Which is it?
Yes, I'm using the config file posted earlier. I'm using the debian distribution of linux.
Thank you.

 
Originally posted by: cleverhandle
Originally posted by: nonnormman
INTERFACE="eth1" is what the file looks like and I'm using regular dhcpd with the dhcp-server.
You said before that you wanted to serve requests on eth0. Which is it?

I thought the interface with static address was only used to access the internet. Are you saying that I use that interface for dhcpd to listen to as well?
 
OK, let's go back a ways. I don't understand what you're trying to do here. I suspect that your interfaces are not configured correctly for what you want to accomplish, or that you only need a single interface. Here are two pieces that do not appear to fit together...

Originally posted by: nonnormman
...my static ip address(192.168.1.83)...
...option routers 192.168.1.1;
If I am understanding this correctly, this DHCP machine you're building is not doing the routing for the subnet. What machine is routing, and why is it not doing DHCP duties? Please describe your network, including which machines have which address ranges assigned and what their gateways are.
 
Back
Top