An automatic installation script and tool for non-installed MySQL versions (new version)

Source: Internet
Author: User

Respect for personal work. If the record is reprinted, indicate the source. Iihero @ csdn

Some of my friends asked me what is the difference between this non-installed version and the installed version (of course, it is a Windows platform)

Simply write a script to automatically create the mysql5 service for it.

 

The script is as follows. Put it in the decompressed directory and execute it.

@ Echo offecho "this is a demo script for auto installation of noninstall version of MySQL on Windows. "Echo" Copyright: iihero @ csdn, When you distribute it, please copy this section abve the head. "Echo" ==================================== iiihero@hotmail.com ==== ==================================== "set mysql_home = % ~ Dp0echo mysql_home = % mysql_home % del/f my. iniecho [client]> my. iniecho Port = 3306> my. iniecho default_character_set = GBK> my. iniecho [mysqld]> my. iniecho default_character_set = utf8> my. iniecho default_storage_engine = InnoDB> my. iniecho basedir = % mysql_home %> my. iniecho datadir = % mysql_home % DATA> my. iniecho innodb_data_file = ibdata1: 50 m; ibdata2: 10 m: autoextend> my. iniecho transaction-isolation = read-committed> my. iniecho Port = 3306> my. iniecho max_allowed_packet = 64 m> my. iniecho "My. INI in % mysql_home % created. "Set Path = % mysql_home %/bin; % PATH % if exist "% mysql_home %/bin/mysqld-nt.exe" Call mysqld-NT -- install-manual mysql55 -- defaults-file = "% mysql_home %/My. ini "if not exist" % mysql_home %/bin/mysqld-nt.exe "Call mysqld -- install-manual mysql55 -- defaults-file =" % mysql_home %/My. ini"

 

Continue to organize:

 

I wrote an article for installing a non-installed MySQL version on the command line. However, the general perception is not enough.
I admit that I am very lazy. It is a waste of time to download and manually configure some things each time. So I made such a thing.
Directly decompress mysql_install_auto.zip to a disk, such as under D: // mysql_install_auto.
Run the following command in D:/mysql_install_auto:
Mysql_install.bat [version] [port]

Here [version] is the version number, but 4.1, 5.1 or 5.5, must be specified
The [port] value can be 3306 or 3307. It is used when MySQL with port 3306 is installed on your machine and you want to specify a different port.

After the download and installation are complete, a MySQL service named iihero [Version], Net start iihero [version]
To start the MySQL service.

Because the website space is really limited, there is no place to put attachments. I have put the attachment on csdn. If you are interested, please download and try it out.

: Http://download.csdn.net/source/2998831

If you have any questions, please leave a message. I will continue to improve.

 

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.