Resetting LDAP and MySQL Passwords: Difference between revisions
(Changing category) |
No edit summary |
||
(3 intermediate revisions by 3 users not shown) | |||
Line 1: | Line 1: | ||
{{BC|Community Sandbox}} | |||
__FORCETOC__ | |||
<div class="col-md-12 ibox-content"> | |||
=Resetting LDAP and MySQL passwords= | |||
{{KB|{{Unsupported}}|{{ZCS 5.0}}||}} | |||
{{Archive}}{{WIP}} | |||
Various Zimbra services use passwords stored in [[Zmlocalconfig|localconfig]] when connecting to ldap and mysql. If these passwords are incorrect, or if you just want to change them, this guide explains how to update the passwords. | Various Zimbra services use passwords stored in [[Zmlocalconfig|localconfig]] when connecting to ldap and mysql. If these passwords are incorrect, or if you just want to change them, this guide explains how to update the passwords. | ||
Line 49: | Line 55: | ||
== Updating Mailbox MySQL Database Passwords == | == Updating Mailbox MySQL Database Passwords == | ||
<pre> | |||
New feature in 7.x /opt/zimbra/libexec/zmresetmysqlpassword (a life saver) | |||
</pre> | |||
It is necessary to run the password update commands as the zimbra user. | It is necessary to run the password update commands as the zimbra user. | ||
# su - zimbra | # su - zimbra | ||
Line 97: | Line 106: | ||
Keywords: ''ldap, logger, mysql, database, password'' | Keywords: ''ldap, logger, mysql, database, password'' | ||
[[Category: Database]] | [[Category: Database]] | ||
[[Category: LDAP]] | [[Category: LDAP]] | ||
Line 105: | Line 113: | ||
[[Category: Troubleshooting Authentication]] | [[Category: Troubleshooting Authentication]] | ||
[[Category: ZCS 5.0]] | [[Category: ZCS 5.0]] | ||
Revision as of 20:52, 12 July 2015
Resetting LDAP and MySQL passwords
Various Zimbra services use passwords stored in localconfig when connecting to ldap and mysql. If these passwords are incorrect, or if you just want to change them, this guide explains how to update the passwords.
Updating LDAP Passwords
It is necessary to run the password update commands as the zimbra user.
# su - zimbra
In ZCS 5.0.x
Command Usage: /opt/zimbra/bin/zmldappasswd [-h] [-r] [-p] [-l] newpassword -h: display this help message -a: change ldap_amavis_password -l: change ldap_replication_password -n: change ldap_nginx_password -p: change ldap_postfix_password -r: change ldap_root_passwd Only one of a, l, n, p, or r may be specified Without options zimbra_ldap_password is changed
Make sure that slapd is running. Note that the actual process id (pid) will vary.
$ ldap status slapd running pid: 32266
Update the ldap root password.
$ zmldappasswd -r newrootpass
Update the zimbra ldap password.
$ zmldappasswd newpass
If necessary, update the password for other ldap users (amavis, replication, nginx, postfix).
In ZCS 4.5.x
Stop zimbra services.
# su - zimbra $ zmcontrol stop
Verify that all Zimbra services are stopped.
$ ps auxww | grep zimbra
Now we can reset the passwords. Note: In versions of ZCS up to 4.5.x the zimbra ldap password must be the same as the ldap root password.
Update the ldap root password.
$ zmldappasswd --root newpass
Update the zimbra ldap password.
$ zmldappasswd newpass
Updating Mailbox MySQL Database Passwords
New feature in 7.x /opt/zimbra/libexec/zmresetmysqlpassword (a life saver)
It is necessary to run the password update commands as the zimbra user.
# su - zimbra
Make sure the mailbox mysql database is running. Note that the actual process id (pid) will vary.
$ mysql.server status mysql is running with pid 23830
If that fails to find a running mysql, verify that the mailbox mysqld does not appear in the process list, and then start it.
$ ps a | grep mysqld.*my.cnf $ mysql.server start
Update the mysql root password.
$ zmmypasswd --root newrootpass
Update the zimbra mysql password.
$ zmmypasswd newpass
Updating Logger MySQL Database Passwords
It is necessary to run the password update commands as the zimbra user.
# su - zimbra
Make sure the logger mysql database is running. Note that the actual process id (pid) will vary.
$ logmysql.server status mysql is running with pid 23830
If that fails to find a running mysql, verify that the mailbox mysqld does not appear in the process list, and then start it.
$ ps a | grep mysqld.*my.logger.cnf $ logmysql.server start
Update the logger mysql root password.
$ zmmylogpasswd --root newrootpass
Update the logger zimbra mysql password.
$ zmmylogpasswd newpass
Related Articles
- Issues with mysql and logmysql passwords may help if the steps in this guide do not work to update the passwords
Keywords: ldap, logger, mysql, database, password