Считаете, что Ubuntu недостаточно дружелюбна к новичкам? Помогите создать новое Руководство для новичков!
0 Пользователей и 1 Гость просматривают эту тему.
Ключевые слова: mysql, trouble, security, password, (найти похожие документы)Date: Tue, 22 Jan 2002 23:30:36 +0300From: Igor Cherkaev <Igor.Cherkaev@p6.f18.n5006.z2.fidonet.org>Newsgroups: fido7.ru.unix.bsdSubject: Как изменить забытые MySQL пароли. DF> Есть тачка, на которой стоит MySQL, c момента установки так и не DF> использовавшийся, посему пароли благополучно забыты. DF> Как бы их добыть/сменить? Текущие базы ценности не имеют, но при DF> попытке сделать по новой mysql_install_db... MySQL при запуске тут же DF> пишет mysql ended - и все.читать мануал уже не модно...Кратко:1. перезапустить mysqld с опцией --skip-grant-tables2. mysqladmin -h хост -u пользователь password 'новый пароль'=== Cut ===A.4.2 How to Reset a Forgotten PasswordIf you have forgotten the root user password for MySQL, you can restore it withthe following procedure:Take down the mysqld server by sending a kill (not kill -9) to the mysqldserver. The pid is stored in a .pid file, which is normally in the MySQLdatabase directory:kill `cat /mysql-data-directory/hostname.pid`You must be either the Unix root user or the same user the server runs as to dothis.Restart mysqld with the --skip-grant-tables option.Connect to the mysqld server with mysql -h hostname mysql and change thepassword with a GRANT command. See section 4.3.1 GRANT and REVOKE Syntax. Youcan also do this with mysqladmin -h hostname -u user password 'new password'Load the privilege tables with: mysqladmin -h hostname flush-privileges or withthe SQL command FLUSH PRIVILEGES.Note that after you started mysqld with --skip-grant-tables, any usage of GRANTcommands will give you an Unknown command error until you have executed FLUSHPRIVILEGES.Comments:Hardly Boffin <mysqladmin@subgenius.net>: As a new user i find this veryconfusing..I was able to find another refference with easier examples athttp://www.codebits.com/bit.cfm?BitID=1201. /usr/local/mysql/bin/safe_mysqld --skip-grant-tables &2. /usr/local/mysql3. use mysql;4. update user set password = password('.......') where user = 'root' andhost='localhost';5. Stop and Start the MySQL server.=== Cut === wbr, IC. |email: ic@rm-nkz.ru / root@rm-nkz.ru |pager: 1000 [45-03-03]
mysqld --skip-grant-tables
$ sudo mysqld --skip-grant-tables[sudo] password for user-pc: InnoDB: Unable to lock ./ibdata1, error: 11InnoDB: Check that you do not already have another mysqld processInnoDB: using the same InnoDB data or log files.090406 14:04:59 InnoDB: Retrying to lock the first data fileInnoDB: Unable to lock ./ibdata1, error: 11
Страница сгенерирована за 0.08 секунд. Запросов: 20.