zoukankan      html  css  js  c++  java
  • mysql数据库部署与连接

    第一章 数据库部署与连接

    1. Windows系统环境下操作:

    1.1. 安装部署

    方式一: https://dev.mysql.com/downloads/installer/

     

    方式二:下载安装PHPstudy程序,然后打开其MySQL服务。注意:phpstudy程序存储目录必须全英文!

    1.2. 连接

    备注:mysql服务端口为——3306

    方式一:命令行操作

    win+r——>cmd——>进入phpstudy数据程序的MySQLbin目录下——>mysql.exe -uroot -proot(mysql .exe用户名 密码(默认为root))

    C:Users子墨.咖啡>d:
    
    D:>cd D:phpstudyphpstudy_proExtensionsMySQL5.7.26in
    
    D:phpstudyphpstudy_proExtensionsMySQL5.7.26in>mysql -uroot -proot
    mysql: [Warning] Using a password on the command line interface can be insecure.
    Welcome to the MySQL monitor.  Commands end with ; or g.
    Your MySQL connection id is 2
    Server version: 5.7.26 MySQL Community Server (GPL)
    
    Copyright (c) 2000, 2019, Oracle and/or its affiliates. All rights reserved.
    
    Oracle is a registered trademark of Oracle Corporation and/or its
    affiliates. Other names may be trademarks of their respective
    owners.
    
    Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
    
    mysql>

     

    方式二:图形界面操作

    安装程序Navicat

    链接本地数据库,密码默认root

     

    打开数据库

     

    2. Linux系统环境下:

    2.1. 安装,启动

    [root@test-201 ~]# yum -y install mariadb mariadb-server
    
    [root@test-201 ~]# systemctl start mariadb      systemctl enable mariadb

    2.2. 连接

    方式一:

    [root@test-201 ~]# mysql -uroot
    
    Welcome to the MariaDB monitor.  Commands end with ; or g.
    
    Your MariaDB connection id is 3
    
    Server version: 5.5.65-MariaDB MariaDB Server
    
     
    Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
    
    
    Type 'help;' or 'h' for help. Type 'c' to clear the current input statement.
    
    
    MariaDB [(none)]>

    方式二:

     

     

  • 相关阅读:
    libuv::线程
    libuv::定时器
    libuv::线程池
    libuv::线程同步
    ABAQUS 2017 安装后无法运行问题
    Abaqus2017安装全过程
    ModelCenter安装详解
    centos下安装Ansys 17.2的全部过程
    Jmeter压力测试分布式部署
    Centos7永久挂载iso文件
  • 原文地址:https://www.cnblogs.com/dazhu-secure/p/13716076.html
Copyright © 2011-2022 走看看