FAQ
Hi all =)

Does anyone know of a module that can configure the DNS on Ubuntu 12.04
clients?

This module works for CentOS and Ubuntu < 12.04

http://forge.puppetlabs.com/saz/resolv_conf

but in Ubuntu 12.04 you can't just overwrite the /etc/resolv.conf anymore.
DNS have to be set in /etc/network/interfaces

Does anyone know how to do this in puppet?

Hugs,
Sandra =)

--
You received this message because you are subscribed to the Google Groups "Puppet Users" group.
To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/2d9sQYbru9sJ.
To post to this group, send email to puppet-users@googlegroups.com.
To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.

Search Discussions

  • Andreas Ntaflos at Sep 11, 2012 at 3:17 pm

    On 11/09/12 16:00, Sandra Schlichting wrote:
    Hi all =)

    Does anyone know of a module that can configure the DNS on Ubuntu 12.04
    clients?

    This module works for CentOS and Ubuntu < 12.04

    http://forge.puppetlabs.com/saz/resolv_conf

    but in Ubuntu 12.04 you can't just overwrite the /etc/resolv.conf
    anymore. DNS have to be set in /etc/network/interfaces
    Not necessarily. I have not tried this myself yet, but you can put
    static DNS settings in /etc/resolvconf/resolv.conf.d/{head,base,tail}.
    Afterwards call "service resolvconf restart". See here for details:
    http://www.stgraber.org/2012/02/24/dns-in-ubuntu-12-04/

    You should be able to adapt the resolv_conf module accordingly, or write
    your own.

    Andreas
  • Stephen Gran at Sep 11, 2012 at 3:23 pm
    Hi,
    On Tue, 2012-09-11 at 17:16 +0200, Andreas Ntaflos wrote:
    On 11/09/12 16:00, Sandra Schlichting wrote:
    Hi all =)

    Does anyone know of a module that can configure the DNS on Ubuntu 12.04
    clients?

    This module works for CentOS and Ubuntu < 12.04

    http://forge.puppetlabs.com/saz/resolv_conf

    but in Ubuntu 12.04 you can't just overwrite the /etc/resolv.conf
    anymore. DNS have to be set in /etc/network/interfaces
    Not necessarily. I have not tried this myself yet, but you can put
    static DNS settings in /etc/resolvconf/resolv.conf.d/{head,base,tail}.
    Afterwards call "service resolvconf restart". See here for details:
    http://www.stgraber.org/2012/02/24/dns-in-ubuntu-12-04/

    You should be able to adapt the resolv_conf module accordingly, or write
    your own.
    Surely if you're statically configuring DNS on a server, you don't want
    a dynamic DNS configuration daemon running on the same server.

    Presumably something like:

    package { 'resolvconf':
    ensure => purged
    }

    And then get on with your life?

    Cheers,
    --
    Stephen Gran
    Senior Systems Integrator - guardian.co.uk

    Please consider the environment before printing this email.
    ------------------------------------------------------------------
    Visit guardian.co.uk - newspaper of the year

    www.guardian.co.uk www.observer.co.uk www.guardiannews.com

    On your mobile, visit m.guardian.co.uk or download the Guardian
    iPhone app www.guardian.co.uk/iphone and iPad edition www.guardian.co.uk/iPad

    Save up to 37% by subscribing to the Guardian and Observer - choose the papers you want and get full digital access.
    Visit guardian.co.uk/subscribe

    ---------------------------------------------------------------------
    This e-mail and all attachments are confidential and may also
    be privileged. If you are not the named recipient, please notify
    the sender and delete the e-mail and all attachments immediately.
    Do not disclose the contents to another person. You may not use
    the information for any purpose, or store, or copy, it in any way.

    Guardian News & Media Limited is not liable for any computer
    viruses or other material transmitted with or as part of this
    e-mail. You should employ virus checking software.

    Guardian News & Media Limited

    A member of Guardian Media Group plc
    Registered Office
    PO Box 68164
    Kings Place
    90 York Way
    London
    N1P 2AP

    Registered in England Number 908396

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Sandra Schlichting at Sep 11, 2012 at 3:44 pm

    Surely if you're statically configuring DNS on a server, you don't want
    a dynamic DNS configuration daemon running on the same server.

    Presumably something like:

    package { 'resolvconf':
    ensure => purged
    }

    And then get on with your life?
    That is a very attractive solution fore sure!

    Should I just ignore that it depends on the "ubuntu-minimal" package?


    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/aNi1lLxBg9EJ.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Joe Topjian at Sep 11, 2012 at 3:54 pm

    That is a very attractive solution fore sure!

    Should I just ignore that it depends on the "ubuntu-minimal" package?
    ouch.

    Since /etc/resolv.conf is a symlink to resolvconf's resolv.conf, you can
    break the symlink, turn resolv.conf into a normal static file and then use
    the puppet module.

    I am not 100% confident of this solution, though, since I'm not sure if
    resolvconf will recreate the symlink at some point -- I haven't used this
    solution enough to confirm that.

    Thanks,
    Joe


    --
    Joe Topjian
    Systems Administrator
    Cybera Inc.

    www.cybera.ca

    Big data is coming to Canada. Join the welcome wagon.
    *Cyber Summit 2012*
    October 1-3, Banff
    www.cybera.ca/summit2012

    Cybera is a not-for-profit organization that works to spur and support
    innovation, for the economic benefit of Alberta, through the use
    of cyberinfrastructure.

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Craig White at Sep 11, 2012 at 4:29 pm

    On Sep 11, 2012, at 8:54 AM, Joe Topjian wrote:

    That is a very attractive solution fore sure!

    Should I just ignore that it depends on the "ubuntu-minimal" package?

    ouch.

    Since /etc/resolv.conf is a symlink to resolvconf's resolv.conf, you can break the symlink, turn resolv.conf into a normal static file and then use the puppet module.

    I am not 100% confident of this solution, though, since I'm not sure if resolvconf will recreate the symlink at some point -- I haven't used this solution enough to confirm that.
    ----
    if /etc/resolv.conf is a puppet maintained file, even if resolvconf package is updated, it will be replaced by the puppet asserted file anyway.

    Craig

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Joe Topjian at Sep 11, 2012 at 5:08 pm

    if /etc/resolv.conf is a puppet maintained file, even if resolvconf
    package is updated, it will be replaced by the puppet asserted file anyway.
    Very true, but I would hate to have two services fighting with each other
    in that way.


    --
    Joe Topjian
    Systems Administrator
    Cybera Inc.

    www.cybera.ca

    Big data is coming to Canada. Join the welcome wagon.
    *Cyber Summit 2012*
    October 1-3, Banff
    www.cybera.ca/summit2012

    Cybera is a not-for-profit organization that works to spur and support
    innovation, for the economic benefit of Alberta, through the use
    of cyberinfrastructure.

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Craig White at Sep 12, 2012 at 3:17 pm

    On Sep 11, 2012, at 10:08 AM, Joe Topjian wrote:

    if /etc/resolv.conf is a puppet maintained file, even if resolvconf package is updated, it will be replaced by the puppet asserted file anyway.

    Very true, but I would hate to have two services fighting with each other in that way.
    ----
    well, I upgraded a 10.04 test server to 12.04 and noticed the messaging about the dynamic nature of /etc/resolv.conf in the Ubuntu server list but it hasn't been a problem at all so I have left it alone (with puppet fully managing /etc/resolv.conf). There's been no contention so I gather that if /etc/resolv.conf isn't a symlink, it isn't mucked with by the Ubuntu/Debian packaging.

    I am however starting to gear up for testing puppet 3, on a test server and ruby 1.93 clients with puppet 3 and even though the current estimate is another year of 10.04 for new deploys, I have an eye on this issue but so far, it's not been a problem.

    Craig

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Stephen Gran at Sep 11, 2012 at 3:59 pm
    Hi,
    On Tue, 2012-09-11 at 08:44 -0700, Sandra Schlichting wrote:
    Surely if you're statically configuring DNS on a server, you
    don't want
    a dynamic DNS configuration daemon running on the same
    server.

    Presumably something like:

    package { 'resolvconf':
    ensure => purged
    }

    And then get on with your life?


    That is a very attractive solution fore sure!


    Should I just ignore that it depends on the "ubuntu-minimal" package?
    It won't cause any harm (as in, lack of functionality) - the
    ubuntu-minimal package only exists to make sure other software is
    installed. If you are uneasy about removing the package, you can also
    presumably just make sure the service doesn't run.

    Cheers,
    --
    Stephen Gran
    Senior Systems Integrator - guardian.co.uk

    Please consider the environment before printing this email.
    ------------------------------------------------------------------
    Visit guardian.co.uk - newspaper of the year

    www.guardian.co.uk www.observer.co.uk www.guardiannews.com

    On your mobile, visit m.guardian.co.uk or download the Guardian
    iPhone app www.guardian.co.uk/iphone and iPad edition www.guardian.co.uk/iPad

    Save up to 37% by subscribing to the Guardian and Observer - choose the papers you want and get full digital access.
    Visit guardian.co.uk/subscribe

    ---------------------------------------------------------------------
    This e-mail and all attachments are confidential and may also
    be privileged. If you are not the named recipient, please notify
    the sender and delete the e-mail and all attachments immediately.
    Do not disclose the contents to another person. You may not use
    the information for any purpose, or store, or copy, it in any way.

    Guardian News & Media Limited is not liable for any computer
    viruses or other material transmitted with or as part of this
    e-mail. You should employ virus checking software.

    Guardian News & Media Limited

    A member of Guardian Media Group plc
    Registered Office
    PO Box 68164
    Kings Place
    90 York Way
    London
    N1P 2AP

    Registered in England Number 908396

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Sandra Schlichting at Sep 11, 2012 at 4:29 pm

    Not necessarily. I have not tried this myself yet, but you can put
    static DNS settings in /etc/resolvconf/resolv.conf.d/{head,base,tail}.
    Afterwards call "service resolvconf restart". See here for details:
    http://www.stgraber.org/2012/02/24/dns-in-ubuntu-12-04/
    Just tried it, and just treating /etc/resolvconf/resolv.conf.d/base as your
    /etc/resolv.conf works.

    You should be able to adapt the resolv_conf module accordingly, or write
    your own.
    That should be interesting. I on it =)



    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/qbZNclGp6bIJ.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.
  • Saz at Sep 12, 2012 at 1:19 pm

    On Tuesday, September 11, 2012 6:29:32 PM UTC+2, Sandra Schlichting wrote:

    That should be interesting. I on it =)

    As you've mentioned my resolv_conf module in your first post,
    feel free to send me a pull request on Github, if you're
    extending my module.

    HAND,

    Saz

    --
    You received this message because you are subscribed to the Google Groups "Puppet Users" group.
    To view this discussion on the web visit https://groups.google.com/d/msg/puppet-users/-/pCoTsz61XgkJ.
    To post to this group, send email to puppet-users@googlegroups.com.
    To unsubscribe from this group, send email to puppet-users+unsubscribe@googlegroups.com.
    For more options, visit this group at http://groups.google.com/group/puppet-users?hl=en.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouppuppet-users @
categoriespuppet
postedSep 11, '12 at 2:07p
activeSep 12, '12 at 3:17p
posts11
users6
websitepuppetlabs.com

People

Translate

site design / logo © 2022 Grokbase