Unable to install mysqlclient on centos

前端 未结 5 2141
别跟我提以往
别跟我提以往 2021-01-14 05:36

I am building a django app and for which i need to configure mysql.I am trying to install mysqlclient module for sql connection and this is what i am trying

         


        
5条回答
  •  佛祖请我去吃肉
    2021-01-14 06:25

    Open the terminal or login to the workstation/laptop/dev-server using ssh client. Type the following command yum command as a root user:

    # yum install mysql
    Loaded plugins: downloadonly, fastestmirror, security
    Loading mirror speeds from cached hostfile
     * base: mirror.wiredtree.com
     * extras: mirrors.serveraxis.net
     * updates: bay.uchicago.edu
    Setting up Install Process
    Resolving Dependencies
    --> Running transaction check
    ---> Package mysql.x86_64 0:5.1.71-1.el6 will be installed
    --> Finished Dependency Resolution
    
    Dependencies Resolved
    
    ================================================================================
     Package         Arch             Version                  Repository      Size
    ================================================================================
    Installing:
     mysql           x86_64           5.1.71-1.el6             base           893 k
    
    Transaction Summary
    ================================================================================
    Install       1 Package(s)
    
    Total download size: 893 k
    Installed size: 2.4 M
    Is this ok [y/N]: y
    Downloading Packages:
    mysql-5.1.71-1.el6.x86_64.rpm                            | 893 kB     00:00     
    Running rpm_check_debug
    Running Transaction Test
    Transaction Test Succeeded
    Running Transaction
      Installing : mysql-5.1.71-1.el6.x86_64                                    1/1 
      Verifying  : mysql-5.1.71-1.el6.x86_64                                    1/1 
    
    Installed:
      mysql.x86_64 0:5.1.71-1.el6                                                   
    
    Complete!
    

    mysql client the basic syntax is:

    mysql -u USER-NAME-HERE -h MYSQL-DB-SERVER-IP-ADDRESS-HERE -p DB-NAME
    mysql -u nixcraft -h server1.cyberciti.biz -p salesdata
    

提交回复
热议问题