某局点发现iMC/U-Center前台页面,性能监控的所有指标都没有数据。
1、收集imcperdm的debug日志,查看日志有数据库执行的报错提示errorMsg:The used command is not allowed with this MySQL version:
2022-06-13 16:01:15.813 [ERROR (1148)] [THREAD(3403545408)] [CQvDBConnADP::executeSQL] Execute "LOAD DATA local INFILE "/opt/iMC/server/bin/../../server/data/perfdm/perf_data_3403545408_1.dat" INTO TABLE td_2horigindata_1 FIELDS TERMINATED BY "," " failed, errorMsg:The used command is not allowed with this MySQL version
2022-06-13 16:01:15.813 [ERROR (10)] [THREAD(3403545408)] [CReportDbIf::iImportDataFile]Fail to execute bulk insert SQL.
2022-06-13 16:01:15.813 [ERROR (-100)] [THREAD(3403545408)] [CDataTableMgr::vImportDataFileToDB] Fail to call CReportDbIf::iImportDataFile().
2、经确认,现场使用的数据库是MySQL 8.0,且为分离式数据库。版本说明书要求添加loose-local-infile =1参数。
鉴于现场使用的分离式数据库,需要同时在imc服务器和数据库侧修改数据库配置文件。
1、imc侧新建/etc/my.cnf,配置内容如下:
[client]
port= 3306
loose-local-infile =1
[mysqld]
local-infile =1
[mysql]
local-infile =1
2、数据库侧在my.cnf下新增如下参数:[mysql] 和 [mysqld] 域下新增local-infile= 1,[client]域下新增loose-local-infile= 1
然后重启mysql,并重启imcperdm进程后恢复正常。
该案例暂时没有网友评论
✖
案例意见反馈
亲~登录后才可以操作哦!
确定你的邮箱还未认证,请认证邮箱或绑定手机后进行当前操作