Sandra Schlichting
2012-Sep-11 14:00 UTC
[Puppet Users] How to set DNS on Ubuntu 12.04 clients?
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.
Andreas Ntaflos
2012-Sep-11 15:16 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
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/interfacesNot 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
2012-Sep-11 15:23 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
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
2012-Sep-11 15:44 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
> > 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
2012-Sep-11 15:54 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
> > 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.
Stephen Gran
2012-Sep-11 15:59 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
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.
Craig White
2012-Sep-11 16:28 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
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.
Sandra Schlichting
2012-Sep-11 16:29 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
> > 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.
Joe Topjian
2012-Sep-11 17:08 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
> > 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.
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.
Craig White
2012-Sep-12 15:17 UTC
Re: [Puppet Users] How to set DNS on Ubuntu 12.04 clients?
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.