ubuntu 1204 安裝mysql,ubuntu1204

來源:互聯網
上載者:User

ubuntu 1204 安裝mysql,ubuntu1204

檢測本機是否有安裝mysql

sudo netstat -tap | grep mysql

執行上面的命令之後,看到 mysq 的socket 處於監聽狀態,說明有安裝成功。

安裝mysql

sudo apt-get install mysql-server  mysql-client libmysqlclient-dev

安裝過程中會提示輸入資料庫管理員密碼(自己設定的),

設定完成之後等待安裝完成即可。

mysql 的登陸與退出

$ mysql -u root -pEnter password: Welcome to the MySQL monitor.  Commands end with ; or \g.Your MySQL connection id is 45Server version: 5.5.43-0ubuntu0.12.04.1 (Ubuntu)Copyright (c) 2000, 2015, Oracle and/or its affiliates. All rights reserved.Oracle is a registered trademark of Oracle Corporation and/or itsaffiliates. Other names may be trademarks of their respectiveowners.Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.mysql> quit;Bye

著作權聲明:本文為博主原創文章,未經博主允許不得轉載。

相關文章

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.