tidb grafana 忘记admin密码处理

基本原理是grafana中封装了sqlite数据库,admin密码在sqlite数据库中
,直接更新sqlite中用户的密码就行

[root@VM-4-10-centos ~]# ps -ef|grep grafa
tidb      5047     1  1 16:45 ?        00:00:08 bin/bin/grafana-server --homepath=/tidb-deploy/grafana-3000/bin --config=/tidb-deploy/grafana-3000/conf/grafana.ini
root      7993 29254  0 16:53 pts/4    00:00:00 grep --color=auto grafa
[root@VM-4-10-centos ~]# 
[root@VM-4-10-centos ~]# 
[root@VM-4-10-centos ~]# 
[root@VM-4-10-centos ~]# cd /tidb-deploy/grafana-3000
[root@VM-4-10-centos grafana-3000]# 
[root@VM-4-10-centos grafana-3000]# cd data
[root@VM-4-10-centos data]# ll 
total 5052
-rw-r----- 1 tidb tidb 5165056 Mar  7 16:52 grafana.db
drwx------ 2 tidb tidb    4096 Mar  7 16:45 png
---登录sqlite数据库,并将密码改回为admin
[root@VM-4-10-centos data]# sqlite3 grafana.db 
SQLite version 3.7.17 2013-05-20 00:56:22
Enter ".help" for instructions
Enter SQL statements terminated with a ";"
sqlite> update user set password = '59acf18b94d7eb0694c61e60ce44c110c7a683ac6a8f09580d626f90f4a242000746579358d77dd9e570e83fa24faa88a8a6', salt = 'F3FAxVm33R' where login = 'admin';
sqlite> .exit
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值