We are having exactly the same problem on Debian Wheezy - did you ever find 
a solution Justin?

We have set root_password to the new password we want to use and 
old_root_password => ''. The /.my.cnf is created with the root password but 
root's password is still blank (if you check the the mysql.user table, 
password column to confirm).
In addition setting remove_default_accounts => true is not deleting the 
default mysql accounts or the test database.

Any ideas?


On Thursday, 6 February 2014 02:55:19 UTC, Justin Sevier wrote:
>
> Hi All,
>
> I did search and found this article before I posted:  
> https://groups.google.com/forum/#!searchin/puppet-users/mysql$20root/puppet-users/nEZ9bDcaBJE/4O0hN459g9oJ
>
> Unfortunately there really wasn't a resolution as far as I can see.  
>
>
> *The situation:*I am trying to setup a test environment to evaluate if 
> Puppet will work to automate my deployments.  I deployed a couple vm's from 
> my templates which have RHEL 6 and MySQL is already pre-installed.  I am 
> trying to get MySQL installed with a root password but it appears to not be 
> working.  I have run the following to try and remove all traces of MySQL:
>
> yum remove mysql 
> rm -f /etc/my.cnf
> rm -rf /var/lib/mysql
> rm -rf /etc/mysql
> rm -rf /etc/mysql/conf.d
> rm -f /var/log/mysqld.log.rpmsave
> rm -rf /var/backup/mysql
> rm -f /etc/cron.daily/mysqlbackup
> rm -f /root/.mysql_history
> rm -f /.my.cnf
>
> When I attempt to install with Puppet MySQL installs but I can login with 
> no password.  The /.my.cnf file is created with the correct password but 
> even if I try to login with it using mysql -uroot -p and specify the 
> password it fails.  It really seems as though the password is NOT being 
> set?  
>
> I am using the following in my site.pp for testing:
>
> class { '::mysql::server':
>   root_password => 'passwordtest',
>   override_options => { 'mysqld' => { 'max_connections' => '1024' } }
> }
>
> Below you'll find the complete output of the debug run.  I'm hoping 
> someone can point me in the right direction as I haven't been able to 
> figure this out now for a few days.
>
>
> debug: /Stage[main]/Mysql::Server::Config/before: requires 
> Class[Mysql::Server::Service]
> debug: /File[/etc/mysql/conf.d]/notify: subscribes to 
> Class[Mysql::Server::Service]
> debug: /Stage[deploy_app]/before: requires Stage[deploy]
> debug: /Stage[main]/Mysql::Server::Install/before: requires 
> Class[Mysql::Server::Config]
> debug: /Stage[main]//require: requires Class[Stdlib]
> debug: /File[/.my.cnf]/require: requires Mysql_user[root@localhost]
> debug: /Stage[setup_app]/before: requires Stage[deploy_app]
> debug: /Stage[main]/Mysql::Server::Providers/before: requires 
> Anchor[mysql::server::end]
> debug: /Stage[setup]/before: requires Stage[main]
> debug: /File[/etc/my.cnf]/notify: subscribes to 
> Class[Mysql::Server::Service]
> debug: /Stage[main]/Mysql::Server/Anchor[mysql::server::start]/before: 
> requires Class[Mysql::Server::Install]
> debug: /Stage[main]/Mysql::Server::Service/before: requires 
> Class[Mysql::Server::Root_password]
> debug: /File[/etc/httpd/conf.d/ewh.conf]/notify: subscribes to 
> Service[httpd]
> debug: /File[/etc/mysql]/notify: subscribes to 
> Class[Mysql::Server::Service]
> debug: /Stage[main]/Mysql::Server::Root_password/before: requires 
> Class[Mysql::Server::Providers]
> debug: /Stage[setup_infra]/before: requires Stage[deploy_infra]
> debug: /Stage[runtime]/require: requires Stage[main]
> debug: /Stage[runtime]/before: requires Stage[setup_infra]
> debug: /Stage[deploy_infra]/before: requires Stage[setup_app]
> debug: /File[/etc/mysql/conf.d]: Autorequiring File[/etc/mysql]
> debug: /Schedule[daily]: Skipping device resources because running on a 
> host
> debug: /Schedule[monthly]: Skipping device resources because running on a 
> host
> debug: /Schedule[hourly]: Skipping device resources because running on a 
> host
> debug: /Schedule[never]: Skipping device resources because running on a 
> host
> debug: Prefetching yum resources for package
> debug: Puppet::Type::Package::ProviderYum: Executing '/bin/rpm --version'
> debug: Puppet::Type::Package::ProviderYum: Executing '/bin/rpm -qa 
> --nosignature --nodigest --qf '%{NAME} %|EPOCH?{%{EPOCH}}:{0}| %{VERSION} 
> %{RELEASE} %{ARCH}
> ''
> debug: Puppet::Type::Package::ProviderYum: Executing '/bin/rpm -q 
> mysql-server --nosignature --nodigest --qf %{NAME} %|EPOCH?{%{EPOCH}}:{0}| 
> %{VERSION} %{RELEASE} %{ARCH}
> '
> debug: Package[mysql-server](provider=yum): Ensuring => present
> debug: Puppet::Type::Package::ProviderYum: Executing '/usr/bin/yum -d 0 -e 
> 0 -y install mysql-server'
> debug: Puppet::Type::Package::ProviderYum: Executing '/bin/rpm -q 
> mysql-server --nosignature --nodigest --qf %{NAME} %|EPOCH?{%{EPOCH}}:{0}| 
> %{VERSION} %{RELEASE} %{ARCH}
> '
> notice: /Stage[main]/Mysql::Server::Install/Package[mysql-server]/ensure: 
> created
> debug: /Stage[main]/Mysql::Server::Install/Package[mysql-server]: The 
> container Class[Mysql::Server::Install] will propagate my refresh event
> debug: Class[Mysql::Server::Install]: The container Stage[main] will 
> propagate my refresh event
> notice: /File[/etc/mysql]/ensure: created
> info: /File[/etc/mysql]: Scheduling refresh of 
> Class[Mysql::Server::Service]
> debug: /File[/etc/mysql]: The container Class[Mysql::Server::Config] will 
> propagate my refresh event
> notice: /File[/etc/my.cnf]/ensure: defined content as 
> '{md5}4354e13053a5679419f67a6e80b21104'
> info: /File[/etc/my.cnf]: Scheduling refresh of 
> Class[Mysql::Server::Service]
> debug: /File[/etc/my.cnf]: The container Class[Mysql::Server::Config] will 
> propagate my refresh event
> debug: /File[/var/www/html/divider.gif]/seluser: Found seluser default 
> 'system_u' for /var/www/html/divider.gif
> debug: /File[/var/www/html/divider.gif]/selrole: Found selrole default 
> 'object_r' for /var/www/html/divider.gif
> debug: /File[/var/www/html/divider.gif]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/divider.gif
> debug: /File[/var/www/html/divider.gif]/selrange: Found selrange default 
> 's0' for /var/www/html/divider.gif
> debug: /File[/var/www/html/logo.gif]/seluser: Found seluser default 
> 'system_u' for /var/www/html/logo.gif
> debug: /File[/var/www/html/logo.gif]/selrole: Found selrole default 
> 'object_r' for /var/www/html/logo.gif
> debug: /File[/var/www/html/logo.gif]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/logo.gif
> debug: /File[/var/www/html/logo.gif]/selrange: Found selrange default 's0' 
> for /var/www/html/logo.gif
> debug: /File[/var/www/html/test.txt]/seluser: Found seluser default 
> 'system_u' for /var/www/html/test.txt
> debug: /File[/var/www/html/test.txt]/selrole: Found selrole default 
> 'object_r' for /var/www/html/test.txt
> debug: /File[/var/www/html/test.txt]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/test.txt
> debug: /File[/var/www/html/test.txt]/selrange: Found selrange default 's0' 
> for /var/www/html/test.txt
> debug: /File[/var/www/html/defaultsite.css]/seluser: Found seluser default 
> 'system_u' for /var/www/html/defaultsite.css
> debug: /File[/var/www/html/defaultsite.css]/selrole: Found selrole default 
> 'object_r' for /var/www/html/defaultsite.css
> debug: /File[/var/www/html/defaultsite.css]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/defaultsite.css
> debug: /File[/var/www/html/defaultsite.css]/selrange: Found selrange 
> default 's0' for /var/www/html/defaultsite.css
> debug: /File[/var/www/html/index.php]/seluser: Found seluser default 
> 'system_u' for /var/www/html/index.php
> debug: /File[/var/www/html/index.php]/selrole: Found selrole default 
> 'object_r' for /var/www/html/index.php
> debug: /File[/var/www/html/index.php]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/index.php
> debug: /File[/var/www/html/index.php]/selrange: Found selrange default 
> 's0' for /var/www/html/index.php
> debug: /File[/var/www/html/ewh.conf]/seluser: Found seluser default 
> 'system_u' for /var/www/html/ewh.conf
> debug: /File[/var/www/html/ewh.conf]/selrole: Found selrole default 
> 'object_r' for /var/www/html/ewh.conf
> debug: /File[/var/www/html/ewh.conf]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/ewh.conf
> debug: /File[/var/www/html/ewh.conf]/selrange: Found selrange default 's0' 
> for /var/www/html/ewh.conf
> debug: /File[/var/www/html/background.jpg]/seluser: Found seluser default 
> 'system_u' for /var/www/html/background.jpg
> debug: /File[/var/www/html/background.jpg]/selrole: Found selrole default 
> 'object_r' for /var/www/html/background.jpg
> debug: /File[/var/www/html/background.jpg]/seltype: Found seltype default 
> 'httpd_sys_content_t' for /var/www/html/background.jpg
> debug: /File[/var/www/html/background.jpg]/selrange: Found selrange 
> default 's0' for /var/www/html/background.jpg
> debug: file_metadata supports formats: b64_zlib_yaml pson raw yaml; using 
> pson
> debug: Service[httpd](provider=redhat): Executing '/sbin/service httpd 
> status'
> debug: /Schedule[weekly]: Skipping device resources because running on a 
> host
> notice: /File[/etc/mysql/conf.d]/ensure: created
> info: /File[/etc/mysql/conf.d]: Scheduling refresh of 
> Class[Mysql::Server::Service]
> debug: /File[/etc/mysql/conf.d]: The container 
> Class[Mysql::Server::Config] will propagate my refresh event
> debug: Class[Mysql::Server::Config]: The container Stage[main] will 
> propagate my refresh event
> info: Class[Mysql::Server::Service]: Scheduling refresh of Service[mysqld]
> debug: Service[mysqld](provider=redhat): Executing '/sbin/service mysqld 
> status'
> debug: Puppet::Type::Service::ProviderRedhat: Executing '/sbin/chkconfig 
> mysqld'
> debug: Service[mysqld](provider=redhat): Executing '/sbin/service mysqld 
> start'
> debug: Puppet::Type::Service::ProviderRedhat: Executing '/sbin/chkconfig 
> mysqld'
> debug: Puppet::Type::Service::ProviderRedhat: Executing '/sbin/chkconfig 
> mysqld on'
> notice: /Stage[main]/Mysql::Server::Service/Service[mysqld]/ensure: ensure 
> changed 'stopped' to 'running'
> debug: /Stage[main]/Mysql::Server::Service/Service[mysqld]: The container 
> Class[Mysql::Server::Service] will propagate my refresh event
> debug: Service[mysqld](provider=redhat): Executing '/sbin/service mysqld 
> status'
> debug: Service[mysqld](provider=redhat): Executing '/sbin/service mysqld 
> stop'
> debug: Service[mysqld](provider=redhat): Executing '/sbin/service mysqld 
> start'
> notice: /Stage[main]/Mysql::Server::Service/Service[mysqld]: Triggered 
> 'refresh' from 1 events
> debug: /Stage[main]/Mysql::Server::Service/Service[mysqld]: The container 
> Class[Mysql::Server::Service] will propagate my refresh event
> debug: Class[Mysql::Server::Service]: The container Stage[main] will 
> propagate my refresh event
> notice: /File[/.my.cnf]/ensure: defined content as 
> '{md5}e25a44a94fe8c920bfd6d4d566914024'
> debug: /File[/.my.cnf]: The container Class[Mysql::Server::Root_password] 
> will propagate my refresh event
> debug: Class[Mysql::Server::Root_password]: The container Stage[main] will 
> propagate my refresh event
> debug: /Schedule[puppet]: Skipping device resources because running on a 
> host
> debug: Finishing transaction 70259919910440
> debug: Storing state
> debug: Stored state in 0.02 seconds
> notice: Finished catalog run in 30.20 seconds
> debug: report supports formats: b64_zlib_yaml pson raw yaml; using pson
>
>

-- 
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 [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-users/dd79877f-eefa-4d4b-9e74-ad6125a707c8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to