zabbix3.0监控–修改管理员(Admin)密码

本篇文章主要讲解zabbix3.0监控--修改管理员(Admin)密码,通过本文您将了解到zabbix3.0,Admin的相关内容,希望对大家有所帮助。

zabbix3.0监控--修改管理员(Admin)密码

查看mysql登陆用户,密码,数据库: # grep 'DB.*' /etc/zabbix/zabbix_server.conf

# DBHost=localhost

 DBHost=localhost

### Option: DBName

# For SQLite3 path to database file must be provided. DBUser and DBPassword are ignored.

# DBName=

DBName=zabbix

### Option: DBSchema

# Schema name. Used for IBM DB2 and PostgreSQL.

# DBSchema=

### Option: DBUser

# DBUser=

DBUser=zabbix

### Option: DBPassword

DBPassword=zabbix

### Option: DBSocket

# DBSocket=/tmp/mysql.sock

### Option: DBPort

 DBPort=3306

### Option: StartDBSyncers

# Number of pre-forked instances of DB Syncers.

# StartDBSyncers=4


1、进入zabbix数据库中

root@zabbix-server:~# mysql -uroot -p

Enter password:

Welcome to the MySQL monitor.  Commands end with ; or \g.

Your MySQL connection id is 4646

Server version: 5.5.50-0ubuntu0.14.04.1 (Ubuntu)

 

Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.

 

Oracle is a registered trademark of Oracle Corporation and/or its

affiliates. Other names may be trademarks of their respective

owners.

 

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

 

mysql> use zabbix;

Reading table information for completion of table and column names

You can turn off this feature to get a quicker startup with -A

 

Database changed

2、查看users

mysql> desc users;

+----------------+---------------------+------+-----+---------+-------+

| Field          | Type                | Null | Key | Default | Extra |

+----------------+---------------------+------+-----+---------+-------+

| userid         | bigint(20) unsigned | NO   | PRI | NULL    ||

| alias          | varchar(100)        | NO| UNI |         |       |

| name           | varchar(100)        | NO|     |         ||

| surname        | varchar(100)        | NO|     |         ||

| passwd         | char(32)            | NO   ||         |       |

| url            | varchar(255)        | NO|     |         ||

| autologin      | int(11)             | NO   || 0       |       |

| autologout     | int(11)             | NO   || 900     |       |

| lang           | varchar(5)          | NO|     | en_GB   ||

| refresh        | int(11)             | NO   || 30      |       |

| type           | int(11)             | NO   || 1       |       |

| theme          | varchar(128)        | NO|     | default |       |

| attempt_failed | int(11)             | NO   || 0       |       |

| attempt_ip     | varchar(39)         | NO|     |         ||

| attempt_clock  | int(11)             | NO   || 0       |       |

| rows_per_page  | int(11)             | NO   || 50      |       |

+----------------+---------------------+------+-----+---------+-------+

16 rows in set (0.00 sec)

 

mysql> select userid,name,passwd from users;

+--------+--------+----------------------------------+

| userid | name   | passwd                           |

+--------+--------+----------------------------------+

|      1 | Zabbix | 3a57eccc286881c27531d5bdd48c2a25 |

|      2 || d41d8cd98f00b204e9800998ecf8427e |

+--------+--------+----------------------------------+

2 rows in set (0.00 sec)

3、修改Admin密码

mysql> select userid,alias,passwd from users;

+--------+-------+----------------------------------+

| userid | alias | passwd                           |

+--------+-------+----------------------------------+

|      1 | Admin | 3a57eccc286881c27531d5bdd48c2a25 |

|      2 | guest | d41d8cd98f00b204e9800998ecf8427e |

+--------+-------+----------------------------------+

2 rows in set (0.00 sec)

 

mysql> update users set passwd=MD5('solin') where userid=1;

Query OK, 1 row affected (0.00 sec)

Rows matched: 1  Changed: 1  Warnings: 0

 

mysql> select userid,alias,passwd from users;

+--------+-------+----------------------------------+

| userid | alias | passwd                           |

+--------+-------+----------------------------------+

|      1 | Admin | 6d3b365884aa3ff4107b6995e580de1b |

|      2 | guest | d41d8cd98f00b204e9800998ecf8427e |

+--------+-------+----------------------------------+

2 rows in set (0.00 sec)

 

mysql> flush privileges;

Query OK, 0 rows affected (0.00 sec)

 

mysql> \q

Bye

4、登陆测试

 

zabbix3.0监控–修改管理员(Admin)密码

本文转自不要超过24个字符博客51CTO博客,原文链接http://blog.51cto.com/cstsncv/1907884如需转载请自行联系原作者


cstsncv


上一篇:【汇编语言与计算机系统结构笔记09】程序栈,(x86-32)过程调用,栈帧,寄存器使用惯例


下一篇:CVE-2021-3156:Sudo 堆缓冲区溢出漏洞 POC