31,029
edits
Tag: 2017 source edit |
Tag: 2017 source edit |
||
| Line 42: | Line 42: | ||
<source lang="sql"> | <source lang="sql"> | ||
mysql> UPDATE mysql.user SET Password = PASSWORD('anewpassword') WHERE User = 'root'; | mysql> UPDATE mysql.user SET Password = PASSWORD('anewpassword') WHERE User = 'root'; | ||
or on a more recent version | |||
mysql> SET PASSWORD FOR 'root@localhost' = PASSWORD('anewpassword'); | |||
</source> | |||
And to take change into account | |||
<source lang="sql"> | |||
mysql> FLUSH PRIVILEGES; | mysql> FLUSH PRIVILEGES; | ||
mysql> QUIT; | mysql> QUIT; | ||
| Line 65: | Line 70: | ||
$dolibarr_main_db_pass | $dolibarr_main_db_pass | ||
with value of the new password. | with value of the new password. The name of user is store into $dolibarr_main_db_user | ||
*Save file and quit. It should be ok. | *Save file and quit. It should be ok. | ||
*Go in Windows menu | *Go in Windows menu | ||
| Line 80: | Line 83: | ||
<source lang="sql"> | <source lang="sql"> | ||
mysql> UPDATE mysql.user SET Password = PASSWORD('anewpassword') WHERE User = ' | mysql> UPDATE mysql.user SET Password = PASSWORD('anewpassword') WHERE User = 'userusedfordatabaseroot'; | ||
or on a more recent version | or on a more recent version | ||
mysql> SET PASSWORD FOR ' | mysql> SET PASSWORD FOR 'userusedfordatabase@localhost' = PASSWORD('anewpassword'); | ||
</source> | </source> | ||
The to take the change into account. | The to take the change into account. | ||
| Line 90: | Line 93: | ||
</source> | </source> | ||
Note that you may need to change the "localhot" with the ip of the server if the database is onto another server. | |||
=Linux= | =Linux= | ||