
mysql
Mr.Lpp
这个作者很懒,什么都没留下…
展开
-
Slave failed to initialize relay log info structure from the repository
启动从时报错:mysql> start slave;ERROR 1872 (HY000): Slave failed to initialize relay log info structure from the repositoryreset slave之后可以:mysql> reset slave;Query OK, 0 rows affected (0.00 sec)mysql> change master to master_host='192...原创 2021-05-30 08:22:49 · 493 阅读 · 1 评论 -
pt-archiver结合crontab定时自动归档数据
根据时间戳定时归档#!/bin/sh#source ~/.bash_profile#Get current timestampcurrent=`date "+%Y-%m-%d %H:%M"`timeStamp=`date -d "$current" +%s`#echo $timeStamp#currentTimeStamp=$((timeStamp*1000+`date "+%N"`/1000000))currentTimeStamp=$((timeStamp*1000))echo $c原创 2020-10-21 17:19:37 · 433 阅读 · 0 评论 -
MySql8.0修改root密码
MySql 这个垃圾,从8.0开始修改密码有了变化,在user表加了字段authentication_string,修改密码前先检查authentication_string是否为空1、如果不为空use mysql;update user set authentication_string='' where user='root';--将字段置为空ALTERuser'root...原创 2018-09-05 10:54:47 · 5115 阅读 · 3 评论 -
mysql下的user表为空
1、首先修改my.cnf文件里面的sql_mode值,因认5.6之后的默认值就是下面的两个sql_mode=NO_ENGINE_SUBSTITUTION,STRICT_TRANS_TABLES需要把STRICT_TRANS_TABLES去掉,即改为:# vi /usr/local/mysql/my.cnfsql_mode=NO_ENGINE_SUBSTITUTION注:简单来说S...转载 2019-07-22 17:43:35 · 2624 阅读 · 0 评论