1. Installation method
Put it out, My.ini.
# MySQL Server Instance Configuration file#----------------------------------------------------------------------# Generated by the MySQL Server Instance Configuration wizard### installation instructions#------------------------------ ----------------------------------------# # on Linux Your can copy this file to/etc/my.cnf to set global options,# Mysql-da TA-DIR/MY.CNF to set server-specific options# (@[email protected] for the installation) or to# ~/.my.cnf to set user -specific options.## on Windows your should keep this file in the installation directory # of your server (e.g. C:\Program Files\mysql\mysql Server x.y). to# Make sure the server reads the config file with the startup option # "--defaults-file". # # To Run Run ' the server from the ' command line, ' execute this ' command line shell, e.g.# mysqld--defaults-file= "c:\p Rogram files\mysql\mysql Server X.y\my.ini "# to install the server as a Windows service manually, execute this in a # com Mand line Shell, e.g.# mysqld--Install mysqllng--defaults-file= "D:\mydeploy\mysqllng\my.ini" # # and then execute this in a command line shell to start th E Server, e.g.# net start mysqlxy### guildlines for editing this file#-------------------------------------------------- --------------------# # In this file, you can use the all long options and the program supports.# If you want to know the Opti ONS a program supports, start the program# with the '--help ' option.## More detailed information about the individual Opti ONS can also be# found in the manual.### CLIENT section#--------------------------------------------------------------- -------# # The following options would be read by MySQL client applications.# Note This only client applications shipped by MySQL is guaranteed# to the read this section. If you want your own MySQL client program to# Honor these values, you need to specify it as an option during the# MySQL CL Ient Library initialization.#[client]port=3319[mysql]default-character-set=utf8# SERVER section#----------------------------------------------------------------------# # The following options would be read by the MySQL Server. Make sure that# you had installed the server correctly (see above) so it reads this # file.#[mysqld]# the TCP/IP Port the MySQL Server would listen onport=3319#path to installation directory. All paths is usually resolved relative to this.basedir= "d:/mydeploy/mysqllng/" #Path to the database rootdatadir= "D:/myde ploy/mysqllng/data/"# The default character set that would be used when a new schema or table is# created and no character Set is definedcharacter-set-server=utf8# the default storage engine, that'll be used when create new tables Whendefault-s torage-engine=innodb# Set the SQL mode to strictsql-mode= "Strict_trans_tables,no_auto_create_user,no_engine_ SUBSTITUTION "# The maximum amount of concurrent sessions the MySQL server will# Allow. One of these connections'll be reserved-a user with# SUPER privileges to allow the administrator to login even if th e# CoNnection limit has been reached.max_connections=100# Query cache was used to cache SELECT results and later return them# WI Thout actual executing the same query once again. Having the query# cache enabled may result in significant speed improvements, if your# has a lot of identical queries and Rarely changing tables. See the# "qcache_lowmem_prunes" status variable to check if the current value# are high enough for your load.# note:in CAs E Your tables change very often or if your queries are# textually different every time, the query cache could result in a# s Lowdown instead of a performance improvement.query_cache_size=100m# the number of open tables for all threads. Increasing this value# increases the number of the file descriptors that mysqld requires.# Therefore you had to do sure to Set the amount of open files# allowed to at least 4096 in the variable "open-files-limit" in# sections [Mysqld_safe]table_c ache=256# Maximum size for internal (in-memory) temporary tables. If a table# Grows larger than this value, it's automatically converted to disk# based table This limitation was for a single table. There can many# of them.tmp_table_size=103m# how many threads we should keep in a cache for reuse. When a client# disconnects, the client ' s threads is put in the cache if there aren ' t# more than thread_cache_size threads From before. This greatly reduces# the amount of the thread creations needed if you had a lot of new# connections. (Normally this doesn ' t give a notable performance# improvement if you have a good thread implementation.) thread_cache_size=8#*** MyISAM specific options# The maximum size of the temporary file MySQL is allowed to use while# Rec Reating the index (during REPAIR, ALTER TABLE or LOAD DATA infile.# If The file-size would is bigger than this, the index Would be created# through the key cache (which was slower). myisam_max_sort_file_size=100g# If The temporary file used for FA St Index creation would is bigger# than using the key cache by the amount sPecified here, then prefer the# key cache method. This was mainly used to force long character keys in# large tables to use the slower key cache method to create the INDEX.M yisam_sort_buffer_size=205m# size of the Key buffer, used to cache index blocks for MyISAM tables.# does not set it larger t Han 30% of your available memory, as some memory# is also required by the OS to cache rows. Even if you ' re not using# MyISAM tables, you should still set it to 8-64m as it would also be# used for internal temporary Disk tables.key_buffer_size=16m# size of the buffer used for doing full table scans of MyISAM tables.# allocated per Threa D, if a full scan was needed.read_buffer_size=64kread_rnd_buffer_size=256k# this buffer was allocated when MySQL needs to re Build the index in# REPAIR, Optimze, ALTER table statements as well as in LOAD DATA infile# to an empty table. It is allocated per thread so being careful with# large settings.sort_buffer_size=256k#*** INNODB specific options ***# use T His option If you has a MySQL server with the InnoDB support enabled# and you don't plan to use it. This would save memory and disk space# and speed up some things. #skip-innodb# Additional memory pool that's used by InnoDB to store metadata# information. If InnoDB requires more memory for this purpose it will# start-to-allocate it from the OS. As this is fast enough in most# recent operating systems, you normally does not need to change this# value. SHOW INNODB STATUS would display the current amount used.innodb_additional_mem_pool_size=12m# If set to 1, INNODB'll flus H (fsync) the transaction logs to the# disk at each commit, which offers full ACID behavior. If you are# willing to compromise the safety, and you is running small# transactions, you could set this to 0 or 2 to redu Ce disk I/O to the# logs. Value 0 means that the log was only written to the log file and# the log file flushed to disk approximately once per second . Value means the log is written to the log file at each commit, but the log# file is a flushed to disk approximately once per second.innodb_flush_log_at_trx_commit=1# the size of the buffer InnoDB uses for buffering log data. As soon as# it's full, InnoDB'll has to flush it to disk. As it is flushed# once per second anyway, it does does sense to has it very large# (even with long transactions). Inno db_log_buffer_size=6m# InnoDB, unlike MyISAM, uses a buffer pool to cache both indexes and# row data. The bigger you set this and the less disk I/O is needed to# access data in tables. On a dedicated database server, set this# parameter up to 80% of the machine physical memory size. Do not set it# too large, though, because competition of the physical memory may# cause paging in the operating system. Note that on 32bit systems you# might is limited to 2-3.5g of the user level memory per process, so do not# set it too high.in nodb_buffer_pool_size=579m# size of each log file in a log group. You should set the combined size# of logs files to about 25%-100% of your buffer pool size to avoid# unneeded buffer pool flush activity on log file overwrite. however,# Note that a larger logfile size would increase the time needed for the# recovery process.innodb_log_file_size=116 m# number of threads allowed inside the InnoDB kernel. The optimal value# depends highly on the application and hardware as well as the os# Scheduler properties. A too high value may leads to thread thrashing.innodb_thread_concurrency=8
Installation service, my MySQL bin directory is D:\mydeploy\mysqllng\bin
D:\mydeploy\mysqllng\bin\mysqld-install gfscn--defaults-file= "D:\mydeploy\mysqllng\bin\my.ini"
Start the service
net start GFSCN
Stop Service
net stop GFSCN
Delete Service
D:\mydeploy\mysqllng\bin\mysqld-remove GFSCN
To modify a database password
Log in as root user, command: mysql-uroot-p enter the password;
Mysql>use MySQL;
Mysql>update user SET Password=password (' Enter new password ') WHERE user= ' root ';
Mysql>flush privileges;
MySQL app continues to update