Mysql Installation Guide Abstract
Total Page:16
File Type:pdf, Size:1020Kb
MySQL Installation Guide Abstract This is the MySQL Installation Guide from the MySQL 8.0 Reference Manual. For legal information, see the Legal Notices. For help with using MySQL, please visit the MySQL Forums, where you can discuss your issues with other MySQL users. Document generated on: 2021-10-02 (revision: 70953) Table of Contents Preface and Legal Notices .................................................................................................................. v 1 Installing and Upgrading MySQL ...................................................................................................... 1 2 General Installation Guidance .......................................................................................................... 3 2.1 Supported Platforms ............................................................................................................. 3 2.2 Which MySQL Version and Distribution to Install .................................................................... 3 2.3 How to Get MySQL .............................................................................................................. 4 2.4 Verifying Package Integrity Using MD5 Checksums or GnuPG ................................................ 5 2.4.1 Verifying the MD5 Checksum ..................................................................................... 5 2.4.2 Signature Checking Using GnuPG .............................................................................. 5 2.4.3 Signature Checking Using Gpg4win for Windows ...................................................... 13 2.4.4 Signature Checking Using RPM ............................................................................... 17 2.5 Installation Layouts ............................................................................................................. 18 2.6 Compiler-Specific Build Characteristics ................................................................................ 18 3 Installing MySQL on Unix/Linux Using Generic Binaries .................................................................. 19 4 Installing MySQL from Source ....................................................................................................... 23 4.1 Source Installation Methods ................................................................................................ 23 4.2 Source Installation Prerequisites .......................................................................................... 24 4.3 MySQL Layout for Source Installation .................................................................................. 25 4.4 Installing MySQL Using a Standard Source Distribution ........................................................ 26 4.5 Installing MySQL Using a Development Source Tree ............................................................ 30 4.6 Configuring SSL Library Support ......................................................................................... 32 4.7 MySQL Source-Configuration Options ................................................................................. 32 4.8 Dealing with Problems Compiling MySQL ............................................................................ 64 4.9 MySQL Configuration and Third-Party Tools ........................................................................ 65 4.10 Generating MySQL Doxygen Documentation Content ......................................................... 65 5 Installing MySQL on Microsoft Windows ......................................................................................... 67 5.1 MySQL Installation Layout on Microsoft Windows ................................................................. 70 5.2 Choosing an Installation Package ........................................................................................ 70 5.3 MySQL Installer for Windows .............................................................................................. 71 5.3.1 MySQL Installer Initial Setup .................................................................................... 73 5.3.2 Setting Alternative Server Paths with MySQL Installer ................................................ 77 5.3.3 Installation Workflows with MySQL Installer ............................................................... 78 5.3.4 MySQL Installer Product Catalog and Dashboard ...................................................... 86 5.3.5 MySQLInstallerConsole Reference ..................................................................... 92 5.4 Installing MySQL on Microsoft Windows Using a noinstall ZIP Archive ............................. 97 5.4.1 Extracting the Install Archive .................................................................................... 97 5.4.2 Creating an Option File ............................................................................................ 97 5.4.3 Selecting a MySQL Server Type .............................................................................. 99 5.4.4 Initializing the Data Directory .................................................................................... 99 5.4.5 Starting the Server for the First Time ........................................................................ 99 5.4.6 Starting MySQL from the Windows Command Line .................................................. 100 5.4.7 Customizing the PATH for MySQL Tools ................................................................. 101 5.4.8 Starting MySQL as a Windows Service ................................................................... 102 5.4.9 Testing The MySQL Installation .............................................................................. 105 5.5 Troubleshooting a Microsoft Windows MySQL Server Installation ........................................ 105 5.6 Windows Postinstallation Procedures ................................................................................. 107 5.7 Windows Platform Restrictions .......................................................................................... 109 6 Installing MySQL on macOS ........................................................................................................ 111 6.1 General Notes on Installing MySQL on macOS .................................................................. 111 6.2 Installing MySQL on macOS Using Native Packages .......................................................... 112 6.3 Installing and Using the MySQL Launch Daemon ............................................................... 117 iii MySQL Installation Guide 6.4 Installing and Using the MySQL Preference Pane .............................................................. 121 7 Installing MySQL on Linux ........................................................................................................... 127 7.1 Installing MySQL on Linux Using the MySQL Yum Repository ............................................. 128 7.2 Installing MySQL on Linux Using the MySQL APT Repository ............................................. 132 7.3 Installing MySQL on Linux Using the MySQL SLES Repository ........................................... 132 7.4 Installing MySQL on Linux Using RPM Packages from Oracle ............................................. 133 7.5 Installing MySQL on Linux Using Debian Packages from Oracle .......................................... 137 7.6 Deploying MySQL on Linux with Docker ............................................................................ 139 7.6.1 Basic Steps for MySQL Server Deployment with Docker .......................................... 139 7.6.2 More Topics on Deploying MySQL Server with Docker ............................................. 144 7.6.3 Deploying MySQL on Windows and Other Non-Linux Platforms with Docker .............. 150 7.7 Installing MySQL on Linux from the Native Software Repositories ....................................... 151 7.8 Installing MySQL on Linux with Juju .................................................................................. 153 7.9 Managing MySQL Server with systemd ............................................................................. 153 8 Installing MySQL on Solaris ......................................................................................................... 159 8.1 Installing MySQL on Solaris Using a Solaris PKG .............................................................. 160 9 Postinstallation Setup and Testing ................................................................................................ 163 9.1 Initializing the Data Directory ............................................................................................. 163 9.2 Starting the Server ............................................................................................................ 169 9.2.1 Troubleshooting Problems Starting the MySQL Server ............................................. 169 9.3 Testing the Server ............................................................................................................ 172 9.4 Securing the Initial MySQL Account ................................................................................... 174 9.5 Starting and Stopping MySQL Automatically ...................................................................... 175 10 Upgrading MySQL ..................................................................................................................... 177 10.1 Before You Begin ..........................................................................................................