CentOS 5.7 dhclient-eth0.conf declaration not working

Issues related to configuring your network
Post Reply
hawkmage
Posts: 162
Joined: 2011/12/17 00:00:11

CentOS 5.7 dhclient-eth0.conf declaration not working

Post by hawkmage » 2011/12/23 00:43:35

On a CentOS 5.7 VM running under VirtualBox I have created the file /etc/dhclient-eth0.conf I have the line:
append domain-search "mysub.domain.com";

The version of DHCP client is: isc-dhclient-V3.0.5-RedHat

In /var/log/messages it shows an error that "domain-search" is not recognized. This works on CentOS 6.X but that is running ISC DHCP 4.X instead of 3.X.

I have not been able to find if this declaration is supported in ISC DHCP 3.x. If not does anyone have a suggestion other than building and installing ISC DHCP 4.x.

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

CentOS 5.7 dhclient-eth0.conf declaration not working

Post by TrevorH » 2011/12/23 00:48:28

The example in `man dhclient.conf` on a CentOS 5.7 system uses

[code]
supersede domain-name "fugue.com rc.vix.com home.vix.com";
[/code]

but I suspect that append should work too.

hawkmage
Posts: 162
Joined: 2011/12/17 00:00:11

Re: CentOS 5.7 dhclient-eth0.conf declaration not working

Post by hawkmage » 2011/12/23 01:09:37

I thought that the domain-search directive was for setting the resolv.conf search entry and domain-name directive was for setting the domain entry. I will give it a try.

hawkmage
Posts: 162
Joined: 2011/12/17 00:00:11

[Solved] Re: CentOS 5.7 dhclient-eth0.conf declaration not working

Post by hawkmage » 2011/12/23 01:16:30

OK, that worked. I guess in DHCP 4 they separated out the domain-search from the domain-name directive.

Thanks!

User avatar
TrevorH
Site Admin
Posts: 33202
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: CentOS 5.7 dhclient-eth0.conf declaration not working

Post by TrevorH » 2011/12/23 01:16:37

I'm only guessing from the list of entries in the example that this is what it's for so let us know if it works :-)

hawkmage
Posts: 162
Joined: 2011/12/17 00:00:11

Re: CentOS 5.7 dhclient-eth0.conf declaration not working

Post by hawkmage » 2011/12/23 02:26:56

Looking at the release notes for ISC DHCP it looks like the domain-search directive has be in the code since at least 3.1

Post Reply