[Puppet Users] migrate from puppetmaster 3.4.3 -> 4.8.2
Hi all. In old puppet master node with puppetmaster 3.4.3 i use mysql to storу data. In [master] section of puppet.conf configured data to access the database: storeconfigs = true dbadapter = mysql dbname = puppetdb dbuser = puppetdbu dbpassword = * dbserver = localhost it works fine. On fresh install with puppetmaster 4.8.2 I get error on client node: === Warning: Unable to fetch my node definition, but the agent run will continue: Warning: Error 500 on SERVER: Server Error: Could not retrieve facts for debian9-lab3: Could not find terminus active_record for indirection facts Info: Retrieving pluginfacts Info: Retrieving plugin Info: Loading facts Error: Could not retrieve catalog from remote server: Error 500 on SERVER: Server Error: Could not find terminus active_record for indirection facts Warning: Not using cache on failed catalog Error: Could not retrieve catalog; skipping run = Is it possible to use storeconfig in database without using puppetdb? -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/a3d48e4b-c946-00bd-b6cb-68397d296b00%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [Puppet Users] stop service after install
Hi. At the current moment I need bind the apache to localhost:80 and nginx to external_ip:80. I cannot change nginx config before it installed and debian start nginx automatic after install package with default configuration (bind to *:80) => conflict. So first I stop the apache service, after install nginx and go update config's... 14.05.2017 16:10, Poil пишет: > Why do you want to stop it ? I think you want to change the listen port. > > So I think something like this will do the job : > > package { 'apache2': ensure => installed, } > > service { 'apache2': > ensure => running, > enable => true, > } > > file { '/etc/apache2/conf.d/listen_port.conf': > content => "your_template.conf.erb", > require => Package['apache2'], > notify => Service['apache2'], # Refresh apache after the listen_port > is changed > } > > package {'nginx': > ensure => installed, > require => Service['apache2'], # Install nginx after apache have > been restarted with another config > } > > > Le 13/05/2017 à 11:45, Anton Gorlov a écrit : >> Hi. >> >> I need stop service (apache) after it install from puppet. >> platform is debian 9 and puppet version is 4.8.2 >> >> I my class i wrote: >> >> >> class webpackages { >> >> exec { 'apachechk': >> command => "/bin/systemctl stop apache2;", >> onlyif => "/bin/grep -c 'Listen 80' /etc/apache2/ports.conf", >> } >> >> package { 'libapache2-mpm-itk': >> ensure => latest, >> } >> >> package { 'apache2': >> require => Exec['apachechk'], >> ensure => latest, >> } >> >> package { 'apache2-dev': >> ensure => latest, >> } >> package { 'apache2-suexec-pristine': >> ensure => latest, >> } >> package { 'apache2-utils': >> ensure => latest, >> } >> package { 'apache2-bin': >> ensure => latest, >> } >> package { 'apachetop': >> ensure => latest, >> } >> package { 'libapache2-mod-rpaf': >> ensure => latest, >> } >> package { 'nginx-light': >> require => Exec['apachechk'], >> ensure => latest, >> } >> >> } >> === >> >> but apache not stopping and install nginx is fail because port is busy >> by apache >> >> May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> [::]:8…se) >> May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> 0.0.0.…se) >> May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> [::]:8…se) >> May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> 0.0.0.…se) >> May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> [::]:8…se) >> May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] still could >> not bind() >> >> What is wrong and what is right way to do it? >> > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/57fa4c2b-06b8-8663-daff-02cfdaeea65a%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [Puppet Users] stop service after install
15.05.2017 15:16, R.I.Pienaar пишет: > Debian is just by design stupid, thinks starting all services > unconfigured on install is a good idea, suggest you use a OS designed to > be used on servers and not peoples basements. Yes this is true... But I can't change OS at current time. Question why does not work exec in package install package { 'nginx-light': require => Exec['apachechk'], ensure => latest, } -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/0358969c-0796-eddc-c6c7-ede0c9742f53%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [Puppet Users] stop service after install
Hi. At the current moment I need bind the apache to localhost:80 and nginx to external_ip:80. I cannot change nginx config before it installed and debian start nginx automatic after install package with default configuration (bind to *:80) => conflict. So first I stop the apache service, after install nginx and go update config's... 14.05.2017 16:10, Poil пишет: > Why do you want to stop it ? I think you want to change the listen port. > > So I think something like this will do the job : > > package { 'apache2': ensure => installed, } > > service { 'apache2': > ensure => running, > enable => true, > } > > file { '/etc/apache2/conf.d/listen_port.conf': > content => "your_template.conf.erb", > require => Package['apache2'], > notify => Service['apache2'], # Refresh apache after the listen_port > is changed > } > > package {'nginx': > ensure => installed, > require => Service['apache2'], # Install nginx after apache have > been restarted with another config > } > > > Le 13/05/2017 à 11:45, Anton Gorlov a écrit : >> Hi. >> >> I need stop service (apache) after it install from puppet. >> platform is debian 9 and puppet version is 4.8.2 >> >> I my class i wrote: >> >> >> class webpackages { >> >> exec { 'apachechk': >> command => "/bin/systemctl stop apache2;", >> onlyif => "/bin/grep -c 'Listen 80' /etc/apache2/ports.conf", >> } >> >> package { 'libapache2-mpm-itk': >> ensure => latest, >> } >> >> package { 'apache2': >> require => Exec['apachechk'], >> ensure => latest, >> } >> >> package { 'apache2-dev': >> ensure => latest, >> } >> package { 'apache2-suexec-pristine': >> ensure => latest, >> } >> package { 'apache2-utils': >> ensure => latest, >> } >> package { 'apache2-bin': >> ensure => latest, >> } >> package { 'apachetop': >> ensure => latest, >> } >> package { 'libapache2-mod-rpaf': >> ensure => latest, >> } >> package { 'nginx-light': >> require => Exec['apachechk'], >> ensure => latest, >> } >> >> } >> === >> >> but apache not stopping and install nginx is fail because port is busy >> by apache >> >> May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> [::]:8…se) >> May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> 0.0.0.…se) >> May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> [::]:8…se) >> May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> 0.0.0.…se) >> May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to >> [::]:8…se) >> May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] still could >> not bind() >> >> What is wrong and what is right way to do it? >> > -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/b40462e2-620d-3245-c0c2-92b0d442e3bc%40gmail.com. For more options, visit https://groups.google.com/d/optout.
[Puppet Users] stop service after install
Hi. I need stop service (apache) after it install from puppet. platform is debian 9 and puppet version is 4.8.2 I my class i wrote: class webpackages { exec { 'apachechk': command => "/bin/systemctl stop apache2;", onlyif => "/bin/grep -c 'Listen 80' /etc/apache2/ports.conf", } package { 'libapache2-mpm-itk': ensure => latest, } package { 'apache2': require => Exec['apachechk'], ensure => latest, } package { 'apache2-dev': ensure => latest, } package { 'apache2-suexec-pristine': ensure => latest, } package { 'apache2-utils': ensure => latest, } package { 'apache2-bin': ensure => latest, } package { 'apachetop': ensure => latest, } package { 'libapache2-mod-rpaf': ensure => latest, } package { 'nginx-light': require => Exec['apachechk'], ensure => latest, } } === but apache not stopping and install nginx is fail because port is busy by apache May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to [::]:8…se) May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to 0.0.0.…se) May 13 12:21:29 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to [::]:8…se) May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to 0.0.0.…se) May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] listen() to [::]:8…se) May 13 12:21:30 debian9-lab3 nginx[19538]: nginx: [emerg] still could not bind() What is wrong and what is right way to do it? -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/puppet-users/0dc1d498-9963-171f-c223-e3af643a1b20%40gmail.com. For more options, visit https://groups.google.com/d/optout.