option host-name "foo.foo.com" The hostname needs to be in quotes. Change this up in your dhcp.template to have quotes around them.
On Thu, May 7, 2009 at 9:08 AM, Jeff Schroeder <[email protected]>wrote: > On Thu, May 7, 2009 at 2:10 AM, Gareth Armstrong > <[email protected]> wrote: > > Hello Folks, > > > > first off a big thanks for this very fine piece of software that is > > cobbler. I am currently playing with it as part of an investigation for > my > > team and it impresses me more and more. That said, I think I may have a > bug > > for you. > > > > In summary dhcpd chokes after a cobbler sync when you add a system with a > > full domain name using the "--hostname" option of cobbler system add. > This > > is because "option host-name" in dhcpd only takes the machine name. > > > > Below is a transcript of the commands used to illustrate the bug and a > patch > > that corrects the behavior. > > > > Many thanks in-advance, > > > > Gareth > > > > cobbler system add --name=donkey11 --mac=XX:XX:XX:XX:XX:XX --ip=1.2.3.4 \ > > --hostname=donkey11.somewhere.com \ > > --dns-name=donkey11.somewhere.com --profile=hocoe-rhel5.3-i386 > > --dhcp-tag=subnet2 > > > > cobbler sync > > > > /usr/sbin/dhcpd -t failed > > cobbler trigger failed: cobbler.modules.sync_post_restart_services > > > > May 6 22:15:25 repoman dhcpd: Internet Systems Consortium DHCP Server > > V3.0.5-RedHat > > May 6 22:15:25 repoman dhcpd: Copyright 2004-2006 Internet Systems > > Consortium. > > May 6 22:15:25 repoman dhcpd: All rights reserved. > > May 6 22:15:25 repoman dhcpd: For info, please visit > > http://www.isc.org/sw/dhcp/ > > May 6 22:16:18 repoman dhcpd: Internet Systems Consortium DHCP Server > > V3.0.5-RedHat > > May 6 22:16:18 repoman dhcpd: Copyright 2004-2006 Internet Systems > > Consortium. > > May 6 22:16:18 repoman dhcpd: All rights reserved. > > May 6 22:16:18 repoman dhcpd: For info, please visit > > http://www.isc.org/sw/dhcp/ > > May 6 22:18:38 repoman dhcpd: /etc/dhcpd.conf line 66: semicolon > expected. > > May 6 22:18:38 repoman dhcpd: option host-name donkey11. > > May 6 22:18:38 repoman dhcpd: ^ > > May 6 22:18:38 repoman dhcpd: Configuration file errors encountered -- > > exiting > > May 6 22:18:38 repoman dhcpd: > > May 6 22:18:38 repoman dhcpd: If you did not get this software from > > ftp.isc.org, please > > May 6 22:18:38 repoman dhcpd: get the latest from ftp.isc.org and > install > > that before > > May 6 22:18:38 repoman dhcpd: requesting help. > > May 6 22:18:38 repoman dhcpd: > > May 6 22:18:38 repoman dhcpd: If you did get this software from > ftp.isc.org > > and have not > > May 6 22:18:38 repoman dhcpd: yet read the README, please read it before > > requesting help. > > May 6 22:18:38 repoman dhcpd: If you intend to request help from the > > [email protected] > > May 6 22:18:38 repoman dhcpd: mailing list, please read the section on > the > > README about > > May 6 22:18:38 repoman dhcpd: submitting bug reports and requests for > help. > > May 6 22:18:38 repoman dhcpd: > > May 6 22:18:38 repoman dhcpd: Please do not under any circumstances send > > requests for > > May 6 22:18:38 repoman dhcpd: help directly to the authors of this > software > > - please > > May 6 22:18:38 repoman dhcpd: send them to the appropriate mailing list > as > > described in > > May 6 22:18:38 repoman dhcpd: the README file. > > May 6 22:18:38 repoman dhcpd: > > May 6 22:18:38 repoman dhcpd: exiting. > > > > cobbler system remove --name=donkey11 > > > > cobbler system add --name=donkey11 --mac=XX:XX:XX:XX:XX:XX --ip=1.2.3.4 \ > > --hostname=donkey11 \ > > --dns-name=donkey11.somewhere.com --profile=hocoe-rhel5.3-i386 > > --dhcp-tag=subnet2 > > > > cobbler sync > > Shutting down dhcpd: [ OK ] > > Starting dhcpd: [ OK ] > > > > [r...@repoman modules]# hg qdiff > > diff -r 00e6c2050399 manage_isc.py > > --- a/manage_isc.py Wed May 06 23:03:47 2009 +0200 > > +++ b/manage_isc.py Wed May 06 23:06:17 2009 +0200 > > @@ -230,7 +230,7 @@ > > > > interface["next_server"] = blended_system["server"] > > interface["netboot_enabled"] = > > blended_system["netboot_enabled"] > > - interface["hostname"] = blended_system["hostname"] > > + interface["hostname"] = > > blended_system["hostname"].split('.')[0] > > > > interface["filename"] = "/pxelinux.0" > > # can't use pxelinux.0 anymore > > > > cobbler system remove --name=donkey11 > > > > cobbler system add --name=donkey11 --mac=XX:XX:XX:XX:XX:XX --ip=1.2.3.4 \ > > --hostname=donkey11.somewhere.com \ > > --dns-name=donkey11.somewhere.com --profile=hocoe-rhel5.3-i386 > > --dhcp-tag=subnet2 > > > > cobbler sync > > Shutting down dhcpd: [ OK ] > > Starting dhcpd: [ OK ] > > Something else seems to be wrong. I don't think that patch solves the > root of the problem. Say you have donkey11.site1.int, > donkey11.site2.int, and donkey11.site3.int, etc... Your patch breaks > that type of setup. We use system name and hostname == fully qualified > domain name and it works like a champ. > > Out of curiosity, without your patch, does this work: > cobbler system rename --name donkey11 --newname donkey11.somewhere.com > && cobbler sync > > Are you using the default /etc/cobbler/dhcp.template? It looks like > the template is doing something it shouldn't and generating a bogus > dhcpd.conf. If you're not using a default template, can you paste it > somewhere that we could see it? > > -- > Jeff Schroeder > > Don't drink and derive, alcohol and analysis don't mix. > http://www.digitalprognosis.com > _______________________________________________ > cobbler mailing list > [email protected] > https://fedorahosted.org/mailman/listinfo/cobbler >
_______________________________________________ cobbler mailing list [email protected] https://fedorahosted.org/mailman/listinfo/cobbler
