zoukankan      html  css  js  c++  java
  • mysql-5.6.28-linux-glibc2.5-x86_64.tar.gz 快速安装记录

    安装包:

    mysql-5.6.28-linux-glibc2.5-x86_64.tar.gz

    yum -y install gcc gcc-c++ gcc-g77 autoconf automake zlib* fiex* libxml* ncurses-devel
    libmcrypt* libtool-ltdl-devel* make cmake curl curl-devel libaio

    useradd -s /sbin/nologin mysql

    tar -xf mysql-5.6.28-linux-glibc2.5-x86_64.tar.gz

    mv mysql-5.6.28-linux-glibc2.5-x86_64   /opt/mysql

    chown -R mysql.mysql /opt/mysql

    cd /opt/mysql

    ./scripts/mysql_install_db --defaults-file=/etc/my.cnf --user=mysql --basedir=/opt/mysql --datadir=/opt/mysql/data

    vim /etc/my.cnf

    [mysqld]
    skip-host-cache
    skip-name-resolve
    
    #skip-grant-tables
    port = 3306
    
    
    innodb_flush_log_at_trx_commit=0
    
    lower_case_table_names=1
    character-set-server=utf8mb4
    max_connections=1000
    innodb_flush_log_at_trx_commit=0
    
    max_allowed_packet = 20M
    
    slow_query_log = ON
    slow_query_log_file = /opt/mysql/data/slow-query.log
    long_query_time = 2
    log-queries-not-using-indexes
    log-slow-admin-statements
    log-slow-slave-statements
    log_queries_not_using_indexes = OFF
    # Disabling symbolic-links is recommended to prevent assorted security risks
    # symbolic-links=0
    
    # Disabling symbolic-links is recommended to prevent assorted security risks
    symbolic-links=0
    
    [mysqld_safe]
    general_log=1
    general_log_file=/var/log/mysqld.log
    
    log-error=/var/log/mysqld.error.log
    
    slow_query_log=1
    slow_query_log_file=/var/log/mysqld.slow.log
    
    long_query_time=2
    log_output='FILE'
    
    
    pid-file=/var/run/mysqld/mysqld.pid

    vim /etc/profile

    export PATH=$PATH:/opt/mysql/bin

    source /etc/profile


    cp -rp support-files/mysql.server /etc/init.d/mysqld

    vim /etc/init.d/mysqld

    basedir=/opt/mysql
    datadir=/opt/mysql/data

    OK完成

    好记性不如烂笔头,最难不过坚持
  • 相关阅读:
    WINFORM实现进程信息的查看,listview,点击,右键,右键菜单
    VFP 实验参考答案
    C++ 大作业 超市收银系统
    ASP实现计算机爱好者网站,可以直接浏览
    C语言实验单片机串口发送int型数据
    超声波 HC-SR04
    django应用之corsheaders[跨域设置]
    git
    Your activation code could not be validated(error 1653219)
    Django Rest Framework简介及初步使用
  • 原文地址:https://www.cnblogs.com/dannylinux/p/15464693.html
Copyright © 2011-2022 走看看