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
- MySQL下載並安裝(Windows)MySqlWindows
- Windows下安裝 Apache PHP Mysql RedisWindowsApachePHPMySqlRedis
- mysql總結(二)--Windows下安裝教程MySqlWindows
- windows下mysql安裝缺少某個dllWindowsMySql
- Windows安裝mysqlWindowsMySql
- Windows 安裝 MySQL 5.6WindowsMySql
- windows安裝使用mysqlWindowsMySql
- windows 下安裝Windows
- Windows平臺下安裝與配置MySQL5.7WindowsMySql
- Windows平臺下安裝與配置MySQL9WindowsMySql
- WINDOWS下安裝MYSQL資料庫教程詳解WindowsMySql資料庫
- Windows安裝MySQL8WindowsMySql
- windows簡易安裝MYSQLWindowsMySql
- mysql安裝教程-windows版MySqlWindows
- windows下oracle安裝WindowsOracle
- windows下安裝nodejsWindowsNodeJS
- windows 下安裝 nvmWindows
- windows 下安裝 yarnWindowsYarn
- Windows下安裝MongoDBWindowsMongoDB
- 【MySQL安裝】Linux下安裝MySQL(預編譯)MySqlLinux編譯
- Mysql 5.7 免安裝版windows安裝完整教程MySqlWindows
- Windows 本地安裝 Mysql8.0WindowsMySql
- Windows安裝MySQL5.7教程WindowsMySql
- Windows 安裝並配置 MySQL 5.6WindowsMySql
- MySQL下載安裝MySql
- mysql linux下安裝MySqlLinux
- ubuntu下安裝mysqlUbuntuMySql
- windows下安裝部署 hadoopWindowsHadoop
- 【Redis】Windows下安裝RedisRedisWindows
- 在 windows下安裝rabbitmqWindowsMQ
- windows下Tomcat安裝配置WindowsTomcat
- OpenSSL + Windows 下載安裝Windows
- windows下pytorch的安裝WindowsPyTorch
- 1、Windows下安裝mysql-8.0.12及修改初始密碼WindowsMySql密碼
- MySQL 8.0.21下載安裝教程及Navicat for MySQL安裝MySql
- webpack安裝教程windows下、mac下WebWindowsMac
- Windows10安裝MySQL8.0.40WindowsMySql