官术网_书友最值得收藏!

Time for action – installing MySQL on Ubuntu

This section shows you the procedure to install MySQL on Ubuntu. Before starting, please note that Ubuntu typically includes MySQL out of the box. So if that’s the case, you’re done. If not, please follow these instructions:

Note

In order to follow the tutorial you need to be connected to the Internet

  1. Open Ubuntu Software Center.
  2. In the search textbox, type mysql. A list of results will be displayed as shown in the following screenshot:
  3. Among the results, look for MySQL Server and click on it. In the window that shows up, click on Install. The installation begins.
    Note

    Note that if MySQL is already installed, this button will not be available.

  4. At a particular moment, you will be prompted for a password for the root user—the administrator of the database engine. Enter a password of your choice. You will have to enter it twice.
  5. When the installation ends, the MySQL server should start automatically. To check if the server is running, open a terminal and run this:
    sudo netstat -tap | grep mysql
    
  6. You should see the following line or similar:
    tcp 0 0 localhost:mysql *:* LISTEN -
    
  7. At any moment, you can start the service using this command:
    /etc/rc.d/init.d/mysql start
    
  8. Or stop it using this:
    /etc/rc.d/init.d/mysql stop
    

What just happened?

You installed MySQL server in your Ubuntu system. In particular, the screens that were displayed belong to Version 12 of the operating system.

Note

The previous directions are for a standard installation. For custom installations you can visit this page https://help.ubuntu.com/12.04/serverguide/mysql.html. For instructions related to other operating systems or for troubleshooting information you can check the MySQL documentation at http://dev.mysql.com/doc/refman/5.5/en/windows-installation.html.

Have a go hero – installing a visual software for administering and querying MySQL

Beside the MySQL server, it’s recommended that you install some visual software that will allow you to administer and query MySQL. Now it’s your time to look for a software of your choice and install it.

One option would be installing the official GUI tool: MySQL Workbench. On Windows, you can install it with the MySQL Installer. In Ubuntu, the installation process is similar to that of the MySQL server.

Another option would be to install a generic open source tool, for example, SQuirrel SQL Client, a graphical program that will allow you to work with MySQL as well as with other database engines. For more information about this software, visit this link: http://squirrel-sql.sourceforge.net/.

主站蜘蛛池模板: 七台河市| 新昌县| 陈巴尔虎旗| 四子王旗| 崇义县| 阜康市| 广平县| 岱山县| 顺昌县| 泉州市| 德安县| 溧阳市| 封丘县| 萝北县| 苍梧县| 霍山县| 汾阳市| 临海市| 布尔津县| 禄丰县| 工布江达县| 青川县| 德清县| 格尔木市| 桃园市| 南部县| 龙陵县| 淳安县| 措勤县| 鞍山市| 莎车县| 汤阴县| 囊谦县| 巧家县| 保德县| 临沧市| 铁岭县| 广宁县| 平陆县| 微博| 栾川县|