MySQL解壓縮版安裝手記(windows)

來源:互聯網
上載者:User

標籤:

作業系統:windows 2003
mysql版本:mysql-5.6.22-winx64.zip

安裝及配置步驟:
1,解壓縮mysql;
2,建立my.ini檔案並寫入一下內容:

[client]no-beepport=3369default-character-set=utf8[mysql]default-character-set=utf8[mysqld]port=3369#mysql解壓目錄basedir=D:/mysql_test/mysql-5.6.22-winx64#mysql資料檔案所在位置datadir=D:/mysql_test/mysql-5.6.22-winx64/datacharacter-set-server=utf8default-storage-engine=INNODBsql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION"# General and Slow logging.log-output=FILEgeneral-log=0general_log_file="WIN-SAN3COGQ5SE.log"slow-query-log=1#慢查詢記錄檔存放位置slow_query_log_file="D:/mysql_test/mysql-5.6.22-winx64/slow_sql_log.log"long_query_time=5log-error="WIN-SAN3COGQ5SE.err"server-id=1max_connections=151query_cache_size=512Mtable_open_cache=2000tmp_table_size=706Mthread_cache_size=16#*** MyISAM Specific optionsmyisam_max_sort_file_size=10Gmyisam_sort_buffer_size=2Gkey_buffer_size=8Mread_buffer_size=64Kread_rnd_buffer_size=256Ksort_buffer_size=32M#*** INNODB Specific options ***innodb_additional_mem_pool_size=32Minnodb_flush_log_at_trx_commit=0innodb_log_buffer_size=16Minnodb_buffer_pool_size=4Ginnodb_log_file_size=1024Minnodb_thread_concurrency=33innodb_autoextend_increment=64innodb_buffer_pool_instances=16innodb_concurrency_tickets=5000innodb_old_blocks_time=1000innodb_open_files=300innodb_stats_on_metadata=0innodb_file_per_table=1innodb_checksum_algorithm=0back_log=80flush_time=0join_buffer_size=32Mmax_allowed_packet=24Mmax_connect_errors=100open_files_limit=4161query_cache_type=1sort_buffer_size=32Mtable_definition_cache=1400binlog_row_event_max_size=8Ksync_master_info=10000sync_relay_log=10000sync_relay_log_info=10000



3,建立mysql啟動服務
cmd -> mysql/bin -> mysqld.exe -install mysql<服務名> --defaults-file="my.ini檔案所在路徑"
進入windows管理 - 服務 查看mysql服務是否建立成功,並啟動服務;

刪除mysql服務;
mysqld.exe -remove mysql<服務名>

4,測試mysql安裝是否成功;host:localhost user:root password:(空,首次安裝無密碼)
5,設定使用者
#刪除匿名使用者
#建立新使用者並限制可訪問ip;如:
使用者名稱為newuser,host為10.64.7.%,意思為,僅有來自10.64.7.%這個位址區段才能進行訪問;
#使root使用者僅能在本機使用,host為localhost,127.0.0.1,::1(這是ipv6的 127.0.0.1)並設定密碼;
6,許可權授權,原則是最小許可權授權.

MySQL解壓縮版安裝手記(windows)

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.