Now that you've installed MySQL, it's time to perform some basic administrative and configuration tasks to ensure that your database environment is ready for production. In this installment of our MySQL series, we'll look at the process of configuring MySQL on a Windows system. Next time, we'll explore getting up and running in a Linux/Unix environment.
If you installed MySQL on a Windows system and used the Windows Installation Wizard, you're probably already good to go!
When that wizard completed, it most likely launched the MySQL Configuration Wizard which walked you through the process of configuring the database. If you didn't go through the configuration wizard or wish to repeat the process, you may manually invoke it by navigating to the bin directory of your MySQL installation and issuing the command MySQLInstanceConfig.exe.
When the wizard starts for the first time, it asks you if you'd like to perform a standard configuration or a detailed configuration. Unless you have a specific reason to do otherwise, you should start by selecting the less complex standard configuration process. If your system will be running more than one instance of MySQL or you have unusually complex requirements, you should consult the MySQL Documentation and use the detailed configuration process.
The standard configuration process consists of two steps: service options and security options. You'll first see a screen asking you if you'd like to install MySQL as a service.
In most cases, you should select this option. Running the database as a service lets it run in the background without requiring user interaction. You also probably want to select the option to launch the MySQL server automatically at startup. The combination of these two options allows MySQL to restart automatically upon process or system failure.
The second phase of the standard configuration process allows you to set two types of security settings. The first is the use of a root password, which is strongly recommended. This root password controls access to the most sensitive administration tasks on your server. If you're running in an environment where the administrator can access the system running MySQL, you might also want to check the box that specifies the root account may only connect from the localhost. This prevents administrative connections from remote network location. The second option you'll select on this screen is whether you'd like to have an anonymous user account. I recommend that you do not enable this option unless absolutely necessary to increase the security of your system.
That's all there is to configuring a Windows MySQL installation. On the next page, we take a brief look at the configuration process on Linux systems and in future articles we'll dive into using your new MySQL installation!