惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

Google DeepMind News
Google DeepMind News
N
Netflix TechBlog - Medium
The Register - Security
The Register - Security
C
Cybersecurity and Infrastructure Security Agency CISA
H
Hackread – Cybersecurity News, Data Breaches, AI and More
The Hacker News
The Hacker News
P
Proofpoint News Feed
Project Zero
Project Zero
The GitHub Blog
The GitHub Blog
The Last Watchdog
The Last Watchdog
F
Fortinet All Blogs
S
Schneier on Security
Help Net Security
Help Net Security
Security Archives - TechRepublic
Security Archives - TechRepublic
C
Check Point Blog
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
P
Proofpoint News Feed
I
InfoQ
T
The Blog of Author Tim Ferriss
Cisco Talos Blog
Cisco Talos Blog
Stack Overflow Blog
Stack Overflow Blog
T
Troy Hunt's Blog
人人都是产品经理
人人都是产品经理
T
Threatpost
www.infosecurity-magazine.com
www.infosecurity-magazine.com
C
Cyber Attacks, Cyber Crime and Cyber Security
雷峰网
雷峰网
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
爱范儿
爱范儿
Forbes - Security
Forbes - Security
Vercel News
Vercel News
S
Security Affairs
美团技术团队
P
Privacy & Cybersecurity Law Blog
N
News and Events Feed by Topic
Cyberwarzone
Cyberwarzone
Recent Commits to openclaw:main
Recent Commits to openclaw:main
Jina AI
Jina AI
Spread Privacy
Spread Privacy
Attack and Defense Labs
Attack and Defense Labs
IT之家
IT之家
U
Unit 42
Recorded Future
Recorded Future
W
WeLiveSecurity
PCI Perspectives
PCI Perspectives
P
Palo Alto Networks Blog
H
Hacker News: Front Page
S
Security @ Cisco Blogs
博客园 - 【当耐特】

博客园 - hehoge

mysql mybatis 日期查询 druid报错:javax.management.InstanceNotFoundException: com.alibaba.druid:type=DruidDataSourceStat mysql删除固定前缀的表 Mac上操作 androidStudio Unable to find a @SpringBootConfiguration xstream.fromXML 忽略没有的节点 Fatal error compiling: 无效的目标发行版: 1.8 NoSuchMethodError 一般是jar包冲突了 联通网络环境上无法访问http://repo1.maven.org/maven2/中央库解决,镜像库添加 如何在类中获取request,和网站路径 maven build 报release 400错误 mysql启动问题access denied for user 'root'@'localhost'(using password:YES) adapter结构异常记录 eclipse项目报红解决 Location Type Project 'testma' is missing required source folder: 'src/test/resources' testma Build 当遇到eclipse调试断点乱走数据不准确的时候,请maven clean,maven install git学习(一)与eclipse结合 反欺诈组之前接口项目学习 null值插入数据库会报错
linux下安装Mysql
hehoge · 2017-10-13 · via 博客园 - hehoge

1、首先下载,命令行直接下载:

下载地址:http://dev.mysql.com/downloads/mysql/5.6.html#downloads

    下载版本:我这里选择的5.6.33,通用版,linux下64位

    也可以直接复制64位的下载地址,通过命令下载:wget http://dev.mysql.com/get/Downloads/MySQL-5.6/mysql-5.6.33-linux-glibc2.5-x86_64.tar.gz

2、

tar -zxvf mysql-5.6.33-linux-glibc2.5-x86_64.tar.gz

cp -r mysql-5.6.33-linux-glibc2.5-x86_64 /usr/local/mysql

3、

groupadd mysql

useradd -g mysql mysql

4、安装

cd /usr/local/mysql/
mkdir ./data/mysql
chown -R mysql:mysql ./
./scripts/mysql_install_db --安装

----------------#解决方法:
yum install -y perl-Data-Dumper

出现下面情况:
linux libaio.so.1: cannot open shared object file: No such file or directory
缺少安装包libaio和libaio-devel.
命令行
yum install libaio*。自动安装这两个包

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

chmod 755 /etc/init.d/mysqld

cp support-files/my-default.cnf /etc/my.cnf

vi /etc/init.d/mysqld

basedir=/usr/local/mysql/

datadir=/usr/local/mysql/data/mysql

service mysqld start

8、修改当前目录拥有者为root用户

    9、修改当前data目录拥有者为mysql用户

chown -R mysql:mysql data

10、添加mysql服务开机自启动

添加开机启动,把启动脚本放到开机初始化目录。

复制代码

cp support-files/mysql.server /etc/init.d/mysql
# 赋予可执行权限
chmod +x /etc/init.d/mysql
# 添加服务
chkconfig --add mysql 
# 显示服务列表
chkconfig --list 

复制代码

 如果看到mysql的服务,并且3,4,5都是on的话则成功,如果是off,则执行

设置root 密码:

set password for root@localhost = password('root12345');

12、设置远程客户端连接mysql

mysql> GRANT ALL PRIVILEGES ON *.* TO 'root'@'192.168.1.100' IDENTIFIED BY '' WITH GRANT OPTION;

 

mysql> -- @'192.168.1.100'可以替换为@‘%’就可任意ip访问,当然我们也可以直接用 UPDATE 更新 root 用户 Host, 但不推荐, SQL如下:

mysql> -- UPDATE user SET Host='192.168.1.100' WHERE User='root' AND Host='localhost' LIMIT 1;

mysql> flush privileges; --该句一定要有,才能生效;

13、修改root密码

mysql> use mysql

Database changed

mysql> update user set password=PASSWORD('123456') where user='root';

Query OK, 0 rows affected (0.00 sec)

Rows matched: 1  Changed: 0  Warnings: 0

mysql> flush privileges;

Query OK, 0 rows affected (0.00 sec)

 14、创建数据库
CREATE DATABASE 库名;