ubuntu安裝MySQL
作業系統版本:Ubuntu 12.04.3 LTS
安裝步驟
其他功能
reference web: http://www.arthurtoday.com/2009/11/ubuntu-910-mysql.html#.UvTroWKSx1Z
安裝步驟
- 利用apt-get安裝MySQL
- 設定MySQL參數(一般會放大下面的參數,以增加效能)
- 登入MySQL
- 開放遠端可以連線MySQL
sudo apt-get install mysql-server
key_buffer = 16K max_allowed_packet = 1M thread_stack = 64K table_cache = 4 sort_buffer = 64K net_buffer_length = 2K
mysql -u root -p
sudo vi /etc/mysql/my.cnf bind_address = 127.0.0.1 (改為網卡實體IP) mysql> grant all on *.* to user_account@'ip' identified by 'user_password'; mysql> flush privileges; sudo /etc/init.d/apache2 restart sudo /etc/init.d/mysql restart
其他功能
- 重新設定MySQL root 密碼
sudo dpkg-reconfigure mysql-server-5.1
reference web: http://www.arthurtoday.com/2009/11/ubuntu-910-mysql.html#.UvTroWKSx1Z
留言
張貼留言