Installing and Configuring MySQL

Chapter 2 - What is MySQL?
byGareth Downes-Powellet al.
Wrox Press 2003

We will review a typical installation of MySQL. You will learn how to install and get started with the Windows version of MySQL.

Installation On Windows

Installing MySQL on a windows platform is very straightforward. The last stable version at the time of this writing is 3.23.49, so we'll focus on this version. But the installation procedure should be quite similar with other versions.

First, you need to download the binaries, which can be found at http://www.mysql.com/. Download the zip from the Windows section of this page. You will be directed to a list of mirror sites. Choose the mirror site that is closest to your location.

Once the download is complete, use WinZip to open it. If your WinZip version is recent enough, you should have an "Install" button on the toolbar. This will launch the installation process. If not, then decompress the files in the archive into a temporary directory, like C: \WINDOWS\TEMP, and then run the installation program in C: \WINDOWS\TEMP\ setup. exe. Like most installation software on Windows, the process is very simple: all that you have to do is to click on Next. Once the installation software has finished, it will have created all the files necessary to run the MySQL server, but you still need to activate the services.

The win32 version of MySQL comes with a little application that will help you finish the installation. It is called winMySQLadmin. exe that you can find in the "bin" directory located in the main installation folder. If you installed MySQL with the default location, you should find it in C: \MySQL\bin. You need to run this program at least once just after the install process has finished. When WinMySQLadmin is run for the very first time, it will create the configuration file of MySQL, called my. ini. You will be asked for a username and password. This username will be the MySQL user that you will be able to connect with. Just enter the username and password as shown on screenshot below:

click to expand

What exactly does the program WinMySQLadmin do?

First, it will create the configuration file for MySQL and WinMySQLadmin, my. ini, which we mentioned above. Next, it will create and register the "MySQL" service and start it. And finally, it will reduce to your taskbar as a small icon that will let you know the status of your MySQL server:

When the green light is on, it tells you that your MySQL server is running. If the red light is on, then your MySQL server has not been started. This icon is only shown when the WinMySQLadmin program is running and not necessarily when MySQL is running or not. You can have your MySQL server running without WinMySQLadmin.

You can stop the MySQL services, either by using the "Services" console that you can find in Control Panel / Administration Tools / Services. Select the MySQL service in the services list and then click on the stop button, situated in the toolbar.

You can also stop the MySQL services by entering this command in a command prompt: net stop mysql. The service can also be started manually by using the command: net start mysql.

Mac users should use the MySQL installation provided by Marc Liyanage at: http://www.entropy.ch/Softwarelmacosxlmysq//



Dreamweaver MX PHP Web Development
Dreamweaver Mx: Advanced Php Web Development
ISBN: 1904151191
EAN: 2147483647
Year: 2001
Pages: 88

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net