windows下安裝MySQL
1)下載安裝檔案
2)解壓安裝檔案到指定目錄
3)配置好引數檔案;
4)初始化MySQL資料庫
mysqld --initialize datadir=D:\MySQL\mariadb-10.2.13-winx64\datadb
5)註冊服務
D:\MySQL\mariadb-10.2.13-winx64\bin\mysqld install mysqld --defaults-file=D:\MySQL\mariadb-10.2.13-winx64\datadb\my.ini
6)啟動MySQL服務:
a)直接在 windows服務配置裡直接啟動
b)命令列啟動: net start mysqld (停止服務 net stop mysqld)
7)刪除服務
需要在管理員模式下開啟cmd,執行sc delete mysqld 即可
8)附上引數檔案:
#[mysqld]
#datadir=D:/MySQL/mariadb-10.2.13-winx64/data
#[client]
#plugin-dir=D:/MySQL/mariadb-10.2.13-winx64/lib/plugin
#
[client]
#password = your_password
port = 3306
socket = D:\\MySQL\mariadb-10.2.13-winx64\\mysql.sock
plugin-dir=D:\\MySQL\\mariadb-10.2.13-winx64\\lib\\plugin
# Here follows entries for some specific programs
# The MySQL server
[mysqld]
basedir=D:\\MySQL\mariadb-10.2.13-winx64
datadir=D:\\MySQL\mariadb-10.2.13-winx64\\datadb
log-error=D:\\MySQL\mariadb-10.2.13-winx64\\datadb\\mysqld.log
port = 3306
socket = D:\\MySQL\mariadb-10.2.13-winx64\\mysql.sock
init_connect = 'SET NAMES utf8'
skip-external-locking
key_buffer_size = 16K
max_allowed_packet = 1M
table_open_cache = 4
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 240K
server-id = 168
innodb_data_file_path = ibdata1:10M:autoextend
innodb_buffer_pool_size = 400M
innodb_log_file_size = 5M
innodb_log_buffer_size = 8M
innodb_flush_log_at_trx_commit = 2
innodb_lock_wait_timeout = 60
character_set_server=utf8
collation-server=utf8_general_ci
character_set_client=utf8
log-bin=mysql-bin
binlog_format=mixed
expire_logs_days=3
max_binlog_size=200M
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
default-character-set=utf8
character_set_connection=utf8
no-auto-rehash
[client]
default-character-set=utf8
[myisamchk]
key_buffer_size = 8M
sort_buffer_size = 8M
[mysqlhotcopy]
interactive-timeout
2)解壓安裝檔案到指定目錄
3)配置好引數檔案;
4)初始化MySQL資料庫
mysqld --initialize datadir=D:\MySQL\mariadb-10.2.13-winx64\datadb
5)註冊服務
D:\MySQL\mariadb-10.2.13-winx64\bin\mysqld install mysqld --defaults-file=D:\MySQL\mariadb-10.2.13-winx64\datadb\my.ini
6)啟動MySQL服務:
a)直接在 windows服務配置裡直接啟動
b)命令列啟動: net start mysqld (停止服務 net stop mysqld)
7)刪除服務
需要在管理員模式下開啟cmd,執行sc delete mysqld 即可
8)附上引數檔案:
#[mysqld]
#datadir=D:/MySQL/mariadb-10.2.13-winx64/data
#[client]
#plugin-dir=D:/MySQL/mariadb-10.2.13-winx64/lib/plugin
#
[client]
#password = your_password
port = 3306
socket = D:\\MySQL\mariadb-10.2.13-winx64\\mysql.sock
plugin-dir=D:\\MySQL\\mariadb-10.2.13-winx64\\lib\\plugin
# Here follows entries for some specific programs
# The MySQL server
[mysqld]
basedir=D:\\MySQL\mariadb-10.2.13-winx64
datadir=D:\\MySQL\mariadb-10.2.13-winx64\\datadb
log-error=D:\\MySQL\mariadb-10.2.13-winx64\\datadb\\mysqld.log
port = 3306
socket = D:\\MySQL\mariadb-10.2.13-winx64\\mysql.sock
init_connect = 'SET NAMES utf8'
skip-external-locking
key_buffer_size = 16K
max_allowed_packet = 1M
table_open_cache = 4
sort_buffer_size = 64K
read_buffer_size = 256K
read_rnd_buffer_size = 256K
net_buffer_length = 2K
thread_stack = 240K
server-id = 168
innodb_data_file_path = ibdata1:10M:autoextend
innodb_buffer_pool_size = 400M
innodb_log_file_size = 5M
innodb_log_buffer_size = 8M
innodb_flush_log_at_trx_commit = 2
innodb_lock_wait_timeout = 60
character_set_server=utf8
collation-server=utf8_general_ci
character_set_client=utf8
log-bin=mysql-bin
binlog_format=mixed
expire_logs_days=3
max_binlog_size=200M
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
default-character-set=utf8
character_set_connection=utf8
no-auto-rehash
[client]
default-character-set=utf8
[myisamchk]
key_buffer_size = 8M
sort_buffer_size = 8M
[mysqlhotcopy]
interactive-timeout
來自 “ ITPUB部落格 ” ,連結:http://blog.itpub.net/9606353/viewspace-2152093/,如需轉載,請註明出處,否則將追究法律責任。
相關文章
- 【Mysql】Windows下安裝和配置MysqlMySqlWindows
- windows下安裝mysql-proxyWindowsMySql
- MySQL下載並安裝(Windows)MySqlWindows
- Windows下安裝 Apache PHP Mysql RedisWindowsApachePHPMySqlRedis
- Windows下安裝MySQL解壓版WindowsMySql
- mysql總結(二)--Windows下安裝教程MySqlWindows
- windows下mysql安裝缺少某個dllWindowsMySql
- Windows安裝mysqlWindowsMySql
- Windows下 MySQL-5.7.11 安裝與配置WindowsMySql
- windows 下安裝Windows
- Windows 安裝 MySQL 5.6WindowsMySql
- windows安裝使用mysqlWindowsMySql
- WINDOWS下安裝MYSQL資料庫教程詳解WindowsMySql資料庫
- Windows平臺下安裝與配置MySQL9WindowsMySql
- Windows平臺下安裝與配置MySQL5.7WindowsMySql
- windows 下安裝 nvmWindows
- windows 下安裝 yarnWindowsYarn
- Windows下安裝MongoDBWindowsMongoDB
- Windows 下安裝GNUstepWindows
- windows下安裝glassfishWindows
- mysql安裝教程-windows版MySqlWindows
- mysql 在windows上安裝MySqlWindows
- windows 安裝 mysql 5.7.12WindowsMySql
- windows簡易安裝MYSQLWindowsMySql
- Windows安裝MySQL8WindowsMySql
- windows下mysql的安裝於使用(啟動、關閉)WindowsMySql
- ubuntu下安裝mysqlUbuntuMySql
- MySQL下載安裝MySql
- OpenSSL + Windows 下載安裝Windows
- 在 windows下安裝rabbitmqWindowsMQ
- windows下安裝nodejsWindowsNodeJS
- windows下安裝tornadoWindows
- Windows下Redis的安裝WindowsRedis
- Windows下解除安裝OracleWindowsOracle
- Windows下安裝Zabbix AgentdWindows
- windows下安裝unbantuWindows
- 【Redis】Windows下安裝RedisRedisWindows
- Linux下安裝、解除安裝mysqlLinuxMySql