Install MySQL green zip version under Windows

Source: Internet
Author: User

  1. take mysql-5.7.4-m14-winx64 as an example , mysql-5.7.4-m14-winx64.ziphttp://dev.mysql.com/downloads/mysql/5.7.html
  2. Unzip to the installation directory D:\mysql-5.7.4-m14-winx64
  3. Install the root directory D:\mysql-5.7.4-m14-winx64 under Create option profile My.ini
    [Client]port=3306Socket="D:/mysql-5.7.4-m14-winx64/data/mysql.sock"[Mysqld]port=3306Basedir="d:/mysql-5.7.4-m14-winx64/"DataDir="d:/mysql-5.7.4-m14-winx64/data/"Socket="D:/mysql-5.7.4-m14-winx64/data/mysql.sock"#the default character set encodingDefault-character-set=utf-8#The default storage engineDefault-storage-engine=INNODB#set up a strict SQL modelSql-mode="strict_trans_tables,no_auto_create_user,no_engine_substitution" #maximum concurrency allowed on Mysql servermax_connections=100#The query cache is used in the cache for the select result, which returns results that are not actually querying the database. #the results of queries from the cache can significantly increase query speed if you have many of the same queries and rarely change the table structure. #Note: Using Query caching results may not be a performance improvement if your table structure changes frequently or if you have different queries each time. Query_cache_size=1M#The number of open tables for all threads. table_cache=256#The maximum memory size for the temporary table. If a table grows larger than this value, it is automatically converted to disk, which only restricts a single table and can have manyTmp_table_size=18M#There are many threads that we should keep in a cache for reuse. Thread_cache_size=8#InnoDB Saving Data directoryInnodb_data_home_dir="d:/mysql-5.7.4-m14-winx64/data/" #if set to 1,innodb, the transaction log is refreshed on each commit disk, which provides the full acid behavior.#If you want to be secure, and you are doing some small operations, you can set the disk I/O log to 0 or 2 to reduce. innodb_flush_log_at_trx_commit=0#this size is used to buffer the InnoDB in the buffered log data. Once it is full, InnoDB will release it on the disk. #it buffers for a second at any rate, which is meaningless for very large logs. Innodb_log_buffer_size=1M#On a dedicated database server you can set the physical memory size of a machine with up to 80% parameters. #不用把它设置的太大Innodb_buffer_pool_size=128M#The size of each log file in the log group. Innodb_log_file_size=16M#the InnoDB kernel allows multithreading. The highest performance depends on the high application, hardware, and operating system. #a very high value can cause thread jitterInnodb_thread_concurrency=8#This buffer is allocated when MySQL rebuilds the index. It is assigned to each thread, so use it carefully in large settings. Sort_buffer_size=2M#used in the MyISAM table to cache index blocks. Do not set it to more than 30% of your available memory, because some memory also needs to be cached by the OS line,#even if you do not use the MyISAM table, you should still set it to 8-64 m because it will also be used for internal temporary disk tablesKey_buffer_size=16M. Join_buffer_size=128mread_rnd_buffer_size=2M Max_allowed_packet=32m
  4. Add D:\mysql-5.7.4-m14-winx64\bin directory to environment variable
  5. Registering MySQL as a Windows system service, an administrator opens a command prompt
    Mysqld Install MySQL--defaults-file="D:\mysql-5.7.4-m14-winx64\my.ini"

    The Remove service command is

    Mysqld Remove

    Start Service Command

    net start MySQL

    Remove Service Command

    net stop MySQL

  6. change root password to 123456, command line run
    Mysql–uroot
     mysql>  show databases;mysql  Span style= "color: #808080;" >>  use   Mysql;mysql  >  update  user  set  password=  password (" 123456  ") where  Span style= "color: #ff00ff;" >user  "    " ;mysql  >  FLUSH privileges  ;mysql  Span style= "color: #808080;" >>  QUIT 
Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

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.