Puppet dependency error while installing mysql on puppet server

0 votes

I have setup a puppet server (ubuntu 18.04) and a puppet agent (ubuntu 18.04) as a part of my puppet infrastructure and while trying to configure a mysql module to install mysql on my puppet agent. Here's the manifest file.

class mysql {
    package { ["mysql-server-5.5", "libaio1", "libdbd-mysql-perl", "libdbi-perl", "libhtml-template-perl", "libmysqlclient18", "mysql-client-5.5", "mysql-common", "mysql-server-core-5.5"]:
    ensure => present,
    allowcdrom => 'true',
    }
}

The package resource contains all the dependencies of mysql-server still I am getting the below error.

Building dependency tree...
Reading state information...
The following extra packages will be installed:
  mysql-common
The following NEW packages will be installed:
  libmysqlclient18 mysql-common
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 738 kB of archives.
After this operation, 3513 kB of additional disk space will be used.
WARNING: The following packages cannot be authenticated!
  mysql-common libmysqlclient18
E: There are problems and -y was used without --force-yes
Error: /Stage[main]/Mysql/Package[libmysqlclient18]/ensure: change from purged to present failed: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install libmysqlclient18' returned 100: Reading package lists...

I tried adding install_options: "--force-yes", but still getting the same output. Please help!

Aug 9, 2019 in Puppet by Sam
• 6,260 points
1,516 views

1 answer to this question.

0 votes

Try adding -f and --allow-unauthenticated options for apt-get to resolve the dependencies and to go ahead and install it. Adding these flags is all you have to do and you will not need to add each individual dependency to the package resource.

class mysql {
    package { ["mysql-server-5.5"]:
    ensure => present,
    allowcdrom => 'true',
    install_options => ['--allow-unauthenticated', '-f'],
    }
}
answered Aug 9, 2019 by Sirajul
• 59,230 points

Related Questions In Puppet

–1 vote
1 answer

Errors and warnings while installing graphite server using puppet.

Hey @Harish, If you puppet modules is /etc/puppet/modules, ...READ MORE

answered Feb 15, 2019 in Puppet by Varshi
749 views
0 votes
1 answer

Error saying "Error: Could not autoload puppet/provider/package/rpm: No child processes." While installing gcc through puppet

Hey @Laksha, check your internet connectivity. You usually ...READ MORE

answered Feb 15, 2019 in Puppet by Jugnu
1,173 views
0 votes
1 answer

Problems occurred while installing Puppet on Ubuntu

Hey @Dipti, you could execute the following ...READ MORE

answered Feb 25, 2019 in Puppet by Nandita
863 views
+15 votes
2 answers

Git management technique when there are multiple customers and need multiple customization?

Consider this - In 'extended' Git-Flow, (Git-Multi-Flow, ...READ MORE

answered Mar 27, 2018 in DevOps & Agile by DragonLord999
• 8,450 points
4,034 views
+2 votes
1 answer
0 votes
1 answer
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP