Change and Reset MySQL root Password Mengubah dan Reset MySQL root Password

Other then the ways specified Lainnya, maka cara yang ditetapkan here di sini to reset and change the root password for mySQL database in the case that the password is forgotten or lost, the following instructions explain in details the alternative way at the last part of the guide, where no additional file needs to be created: untuk me-reset dan mengganti password root untuk mySQL database dalam kasus yang lupa password atau hilang, instruksi berikut menjelaskan secara rinci alternatif jalan di bagian terakhir buku petunjuk, di mana tidak ada file tambahan yang harus dibuat:

  1. Login as root to the Windows or Unix-like (Unix, Linux or BSD) machine with the MySQL server. Login sebagai root untuk Windows atau mirip Unix (Unix, Linux atau BSD) mesin dengan MySQL server.
  2. Stop the MySQL server by using either of the following command: Menghentikan MySQL server dengan menggunakan salah satu dari perintah berikut:

    Linux: /etc/rc.d/init.d/mysql stop Linux: / etc / rc.d / init.d / mysql stop
    FreeBSD: /usr/local/etc/rc.d/mysql-server.sh stop FreeBSD: / usr / local / etc / rc.d / mysql-server.sh berhenti

  3. Open the mysql server startup script (ie mysql-server.sh – the file executed to start or stop MySQL server. Buka mysql server startup script (misalnya mysql-server.sh - file dijalankan untuk memulai atau menghentikan MySQL server.
  4. Add –skip-grant-tables to the end of the line that contains the mysqld_safe command as its parameter. Menambahkan-skip-grant-tabel di bagian akhir baris yang berisi perintah mysqld_safe sebagai parameter.
  5. Start MySQL server with the following command: Mulai MySQL server dengan perintah berikut:

    Linux: /etc/rc.d/init.d/mysql start Linux: / etc / rc.d / init.d / mysql start
    FreeBSD: /usr/local/etc/rc.d/mysql-server.sh start FreeBSD: / usr / local / etc / rc.d / mysql-server.sh mulai

  6. Alternatively, start the MySQL server directly and skip the editing with the following command: Atau, memulai MySQL server langsung dan melewatkan pengeditan dengan perintah berikut:

    mysqld_safe –skip-grant-tables & mysqld_safe-skip-grant-tables &

    Depending on your path environment, you may need to point to the correct directory where mysqld_safe is instead. Tergantung pada lingkungan jalan, Anda mungkin perlu untuk menunjuk ke direktori yang benar adalah dimana mysqld_safe instead.

  7. Run the following commands to login as the mysql user and connect to mysql user/permission database: Jalankan perintah berikut untuk login sebagai mysql user dan koneksi ke mysql user / izin database:

    # mysql -u root mysql # Mysql-u root mysql

  8. Run the update queries to change the MySQL password: Menjalankan memperbarui permintaan untuk mengubah MySQL password:

    mysql> UPDATE user SET Password=PASSWORD('newrootpassword') WHERE User='root'; mysql> UPDATE user SET Password = PASSWORD ( 'newrootpassword') WHERE Pengguna = 'root';
    mysql> FLUSH PRIVILEGES; mysql> Flush PRIVILEGES;

    Note: Replace newrootpassword with the new root password for MySQL server. Catatan: Ganti dengan yang baru newrootpassword password root untuk MySQL server. Flush Privileges is needed to making the password change effect immediately. Flush Privileges diperlukan untuk membuat efek segera mengubah password.

  9. Exit mysql database client by typing exit. Keluar dari mysql dengan mengetikkan database klien keluar.
  10. Stop MySQL server with commands listed at step 2. Berhenti MySQL server dengan perintah yang tercantum pada langkah 2.
  11. Open the mysql server startup script edit in step 3 again and remove the –skip-grant-tables parameter that has been added. Buka mysql server startup script edit dalam langkah 3 kembali dan menghapus-skip-grant-tabel parameter yang telah ditambahkan.
  12. Start MySQL server by using command from step 5 or 6. Mulai MySQL server dengan menggunakan perintah dari langkah 5 atau 6.

For Redhat Linux users, use the following instructions as the root user of Redhat Linux machine: Untuk pengguna Linux Redhat, gunakan petunjuk berikut ini sebagai root dari mesin Redhat Linux:

  1. Stop MySQL process by using command: MySQL menghentikan proses dengan menggunakan perintah:

    # killall mysqld # Killall mysqld

  2. Start the MySQL server with following options: Memulai MySQL server dengan beberapa pilihan berikut:

    # /usr/libexec/mysqld -Sg –user=root & # / Usr / libexec / mysqld-Sg-user = root &

  3. Start the MySQL client: Memulai MySQL klien:

    # mysql # Mysql

    You should see the following message: Anda akan melihat pesan berikut:

    Welcome to the MySQL monitor. Selamat datang ke MySQL monitor. Commands end with ; or g. Perintah diakhiri dengan; atau g.
    Your MySQL connection id is 1 to server version: 3.xx.xx Anda koneksi MySQL id adalah 1 untuk versi server: 3.xx.xx

    Type 'help;' or 'h' for help. Jenis' membantu; 'atau' h 'for help. Type 'c' to clear the buffer. Ketik 'c' untuk menghapus penyangga.

    mysql> mysql>

  4. Use mysql database: Menggunakan database mysql:

    mysql> USE mysql mysql> USE mysql

    You should see the following message: Anda akan melihat pesan berikut:

    Reading table information for completion of table and column names Membaca tabel informasi untuk menyelesaikan tabel dan nama kolom
    You can turn off this feature to get a quicker startup with -A Anda dapat menonaktifkan fitur ini untuk mendapatkan dengan cepat startup-A

    Database changed Database berubah

  5. Then, update the password for the root user with the following command: Kemudian, memperbarui password untuk root dengan perintah berikut:

    UPDATE user SET password=password(”newpassword”) WHERE user=”root”; UPDATE user SET password = password ( "Newpassword") WHERE user = "root";

    Replace newpassword with your desired password. Newpassword ganti dengan password yang Anda inginkan. You should see the following message: Anda akan melihat pesan berikut:

    Query OK, 2 rows affected (0.03 sec) Query OK, 2 rows affected (0,03 detik)
    Rows matched: 2 Changed: 2 Warnings: 0 Baris dicocokkan: 2 Changed: 2 Peringatan: 0

    Rows affected may be different, but the Query OK should be there. Baris yang terkena mungkin berbeda, tetapi Query OK harus ada.

  6. Flush the database privileges to reload it in order to make the changes effective: Flush privileges database kembali ke dalam untuk melakukan perubahan yang efektif:

    mysql> flush privileges; mysql> flush privileges;

    You should get the following result: Anda akan mendapatkan hasil sebagai berikut:

    Query OK, 0 rows affected (0.02 sec) Query OK, 0 rows affected (0,02 detik)

  7. Exit the MySQL client by typing exit. Keluar dari MySQL client dengan mengetikkan keluar.
  8. Kill the MySQL server process by typing killall mysqld. Membunuh proses server MySQL dengan mengetikkan killall mysqld.
  9. Then start MySQL again: Kemudian mulai lagi MySQL:

    /etc/init.d/mysqld start / etc / init.d / mysqld mulai

IMPORTANT : The page is machine translated and provided "as is" without warranty. PENTING: Halaman yang diterjemahkan mesin dan diberikan "sebagaimana adanya" tanpa jaminan. Machine translation may be difficult to understand. Mesin terjemahan mungkin sulit dimengerti. Please refer to Silakan merujuk ke original English article artikel asli Inggris whenever possible. bila memungkinkan.


8 Responses to “Change and Reset MySQL root Password” 8 Responses to "Ubah dan Reset MySQL root Password"

  1. ap ap
    March 12th, 2009 17:35 12 Mar 2009 17:35
    8 8

    @trail: Worked like a charm, thanks! @ denai: Worked like a charm, thanks!

  2. trail jejak
    September 23rd, 2008 17:22 September 23, 2008 17:22
    7 7

    worked for me on ubuntu, in just one line: bekerja untuk saya pada ubuntu, hanya dalam satu baris:

    sudo dpkg-reconfigure mysql-server-5.0 sudo dpkg-reconfigure mysql-server-5,0

  3. Rajesh Cheethirala Rajesh Cheethirala
    July 3rd, 2008 05:46 3 Jul 2008 05:46
    6 6

    On ubuntu, command is mysqld_safe –-skip-grant-tables & Di ubuntu, perintah adalah mysqld_safe - skip-grant-tables &

    Extra dash is required so mysql can parse it correctly. Sengkang tambahan diperlukan agar dapat parsing mysql dengan benar.

  4. Mengubah password root pada MySQL 5.0 di Windows. Mengubah password root pada MySQL 5,0 di Windows. « Iwan Binanto: “hari-hari ku yang berlalu ..” «Iwan Binanto:" hari-hari ku yang berlalu .. "
    May 5th, 2008 16:52 5 Mei 2008 16:52
    5 5

    [...] judulnya), setelah googling cuma dapat cara untuk mereset dan mengganti password MySQL di UNIX-like di sini. [...] Judulnya), setelah Googling cuma dapat cara untuk mereset dan mengganti password MySQL di UNIX seperti di sini. Wah, perlu sedikit modifikasi ni … Berikut cara2 yang saya lakukan: 1. Wah, perlu sedikit modifikasi ... ni Berikut cara2 yang saya Lakukan: 1. Kill proses MySQL [...] Membunuh proses MySQL [...]

  5. links for 2007-04-23 | Patrick Kempf link untuk 2007/04/23 | Patrick Kempf
    April 23rd, 2007 08:23 23 Apr 2007 08:23
    4 4

    [...] Change and Reset MySQL root Password » My Digital Life (tags: mysql administration) No Tags Gelesen: 2 / heute: 2 [...] Ubah [...] dan Reset Password root MySQL »My Digital Life (tags: mysql administrasi) Tag Gelesen No: 2 / heute: 2 [...]

  6. Help me retrieve my password - Geeks Talk Membantu saya mengambil sandi saya - Geeks Bicara
    December 19th, 2006 14:54 19 Des 2006 14:54
    3 3

    [...] Re: Help me retrieve my password Try this link… Change and Reset MySQL root Password [...] Re: Bantu saya mengambil sandi saya Coba link ini ... Ubah dan Reset MySQL root Password

  7. Vincitore Vincitore
    July 9th, 2006 12:05 9 Jul 2006 12:05
    2 2

    I wanna reset my ZXDSL 831 ADSL Modemn Saya ingin saya ulang ZXDSL 831 ADSL Modemn
    Plz tell me the way how to reset it Plz tell me the way how to reset
    I need to do that right now Saya harus melakukan itu sekarang

    Best Rgds Rgds terbaik
    dugger(vincitore) dugger (vincitore)

  8. Reset the Root Password of MySQL Server » My Digital Life Reset Password Root di MySQL Server »My Digital Life
    June 6th, 2006 18:18 6 Jun 2006 18:18
    1 1

    [...] Alternatively, on any platform, mysql client can be used to set the new password, althought it's less secure way of resetting the password (detailed instruction here): [...] [...] Atau, pada platform manapun, mysql klien dapat digunakan untuk mengatur password baru, meskipun kurang aman jalan ulang sandi (instruksi rinci di sini): [...]

Leave a Reply Meninggalkan Balas

You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong> Anda dapat menggunakan tag ini: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime = ""> <em> <i> <q cite=""> <strike> <strong>

Subscribe to comments feature has been disabled. Berlangganan ke fitur komentar telah dinonaktifkan. To receive notification of latest comments posted, subscribe to Untuk menerima pemberitahuan tentang komentar terbaru diposting, berlangganan My Digital Life Comments RSS feed Saya Digital Life Komentar RSS feed or atau register to receive mendaftar untuk menerima new comments in daily email digest. komentar baru di email harian digest.
Custom Search

New Articles Artikel Baru

Incoming Search Terms for the Article Cari Syarat masuk untuk Artikel

change mysql root password mengubah password root mysql - -- mysql change root password mengubah password root mysql - -- mysql change password mysql mengubah sandi - -- reset mysql password reset password mysql - -- reset mysql root password reset password root mysql - -- mysql password change mysql mengubah sandi - -- mysql password reset reset password mysql - -- mysql password recovery mysql pemulihan password - -- change root password mysql mengubah password root mysql - -- change password mysql mengubah password mysql - -- retrieve mysql root password mengambil password root mysql - -- forgot mysql password lupa password mysql - -- mysql root password change mengubah password root mysql - -- mysql root password reset reset password root mysql - -- reset mysql password ubuntu reset password mysql ubuntu - -- reset mysql root pass reset mysql root lulus - -- mysql retrieve root password mengambil password root mysql - -- ubuntu stop mysql Ubuntu stop mysql - -- change password in mysql mengubah password di mysql - -- mysql reset root pass mysql reset root lulus - -- How to change Mysql root password Cara mengganti password root Mysql - -- change mysql password ubuntu mengubah password mysql ubuntu - -- CHANGE MYSQL PASSWORD CHANGE MYSQL SANDI - -- how to reset mysql password caranya untuk reset password mysql - -- mysql reset privileges mysql privileges ulang - -- ubuntu reset mysql root password Ubuntu-reset password root mysql - -- ubuntu reset mysql password mysql ubuntu ulang sandi - -- how to change password in mysql cara mengganti password di mysql - -- mysql ubuntu default password mysql ubuntu default password - -- retrieve mysql password mengambil mysql password - -- mysql reset password reset password mysql - -- ubuntu mysql reset password mysql ubuntu ulang sandi - -- reset mysql root password ubuntu reset password root mysql ubuntu - -- crack mysql password crack password mysql - -- reset mysql password linux reset mysql password linux - -- forgot mysql root password lupa password root mysql - -- reset mysql pass reset mysql pass - -- all semua - -- reset password mysql reset password mysql - -- stop mysql ubuntu stop mysql ubuntu - -- ubuntu change mysql password Ubuntu mengubah password mysql - -- ubuntu mysql change password Ubuntu mysql mengubah sandi - -- mysql set password mysql menetapkan sandi - -- mysql lost password mysql lost password - -- mysql forgot password mysql lupa password - -- mysql reset password linux mysql reset password linux - -- mysql reset root mysql reset root - -- changing mysql root password mengubah password root mysql - -- how to reset mysql root password cara untuk me-reset password root mysql - -- ubuntu mysql default password Ubuntu mysql default password - -- mysql forgot root password lupa password root mysql - -- mysql change password root mengubah password root mysql - -- ubuntu mysql set root password Ubuntu menetapkan password root mysql - -- mysql "change password" mysql "ubah sandi" - -- lost mysql password hilang mysql sandi - -- mysql change root pass mengubah root mysql lulus - -- mysql root change password mengubah password root mysql - -- ubuntu mysql reset root password Ubuntu-reset password root mysql - -- resetting mysql password ulang mysql sandi - -- mysql reset root password reset password root mysql - -- change password mysql ubuntu mengubah password mysql ubuntu - -- change mysql root pass mengubah root mysql lulus - -- change mysql password linux mengubah password mysql linux - -- mysql clear password mysql jelas sandi - -- mysql password mysql password - -- mysql lost root password windows mysql lost password root jendela - -- mysql reset user mysql ulang pengguna - -- set mysql password mengatur mysql sandi - -- set password mysql set password mysql - -- ubuntu mysql password Ubuntu mysql password - -- lost mysql password ubuntu hilang mysql ubuntu sandi - -- linux mysql reset password linux mysql ulang sandi - -- reset mysql database password reset password mysql database - -- retrieve lost mysql password mengambil password hilang mysql - -- linux reset mysql password linux-reset password mysql - --