![]() |
Berikut ini merupakan petunjuk sederhana untuk mengetahui lokasi Aplikasi Database MySQL menyimpan data di hard disk, baik di Windows dan Linux.
Windows
1) Cari file my.ini, yang yang disimpan pada folder instalasi MySQL.
Contoh,
C:\Program Files\MySQL\MySQL Server 5.1\my.ini
2) Buka file “my.ini” tersebut dengan aplikasi teks editor misal Notepad.
#Path to installation directory. All paths are usually resolved relative to this. basedir="C:/Program Files/MySQL/MySQL Server 5.1/" #Path to the database root datadir="C:/Documents and Settings/All Users/Application Data/MySQL/MySQL Server 5.1/Data/"
Cari “datadir”, ini adalah lokasi penyimpanan data MySQL pada Windows.
Linux
1) Buka file my.cnf dengan perintah find / -name my.cnf .
adlinux@myserver:~$ find / -name my.cnf find: /home/lost+found: Permission denied find: /lost+found: Permission denied /etc/mysql/my.cnf
2) tampilkan isi file my.cnf dengan perintah cat /etc/mysql/my.cnf
adlinux@myserver:~$ cat /etc/mysql/my.cnf # # The MySQL database server configuration file. # # You can copy this to one of: # - "/etc/mysql/my.cnf" to set global options, # - "~/.my.cnf" to set user-specific options. # [mysqld] # # * Basic Settings # user = mysql pid-file = /var/run/mysqld/mysqld.pid socket = /var/run/mysqld/mysqld.sock port = 3306 basedir = /usr datadir = /var/lib/mysql tmpdir = /tmp language = /usr/share/mysql/english skip-external-locking
3) cari teks “datadir”, disinilah lokasi penyimpanan data MySQL pada System Linux.
thnks info gan
BalasHapus