百度智能云文字识别OCR私有化部署服务常见问题QA - 鉴权服务排查
文档简介:
机器指纹方式(软件)鉴权
1、检查鉴权服务进程是否存在
ps -ef|grep auth_server
服务正常启动后如下图所示:
root 3126 3118 0 10月13 ? 00:00:10 /home/baidu/work/c-offline-security-server/auth_server
root 3129 3126 3 10月13 ? 00:45:20 /home/baidu/work/c-offline-security-server/auth_server
root 15042 12347 0 11:33 pts/0 00:00:00 grep --color=auto auth_server
【百度智能云】通用场景文字识别
【百度智能云】卡证文字识别
【百度智能云】财务票据文字识别
【百度智能云】医疗票据文字识别
【百度智能云】交通场景文字识别
【百度智能云】教育场景文字识别
【百度智能云】其他场景文字识别
【百度智能云】iOCR自定义模板文字识别
【百度智能云】通用文字识别(标准版)
【百度智能云】通用文字识别(高精度版)
【百度智能云】网络图片文字识别
【百度智能云】手写文字识别
【百度智能云】门脸文字识别
机器指纹方式(软件)鉴权
1、检查鉴权服务进程是否存在
ps -ef|grep auth_server
服务正常启动后如下图所示:
root 3126 3118 0 10月13 ? 00:00:10 /home/baidu/work/c-offline-security-server/auth_server
root 3129 3126 3 10月13 ? 00:45:20 /home/baidu/work/c-offline-security-server/auth_server
root 15042 12347 0 11:33 pts/0 00:00:00 grep --color=auto auth_server
2、检查鉴权服务端口是否监听
netstat -apn|grep -E '8443|7091|7092'
端口正常监听的话返回如下
tcp 0 0 0.0.0.0:7091 0.0.0.0:* LISTEN 3129/auth_server
tcp 0 0 0.0.0.0:7092 0.0.0.0:* LISTEN 3129/auth_server
tcp 0 0 0.0.0.0:8443 0.0.0.0:* LISTEN 3129/auth_server
3、检查鉴权启动和鉴权请求日志
1)检查是否有报错信息
cat /home/baidu/work/c-offline-security-server/log/auth_server.log |grep -Ei
'warning|error' |grep -v 'gethostbyname_r'|grep -v '8877' cat
/home/baidu/work/c-offline-security-server/log/aipe_info_$(date +%Y-%m-%d).log|grep -i 'error'
常见鉴权报错日志和其对应含义如下:
鉴权报错日志 | 含义 | 解决办法 |
---|---|---|
verify finger is invalid | license里的指纹错误 | 请确认运行鉴权服务的服务器是否有变化, 如硬盘、网卡等,如有变化, 请重新提取指纹、申请授权 |
verify product has not foud | 产品未授权 | 此服务器未获得授权,无法运行OCR模型 请重新提取指纹、申请授权 |
verify product lc is expired | 产品授权过期 | 请重新提取指纹、申请授权 |
instance_check reg fail,r_list full | 实例池已满 运行模型的服务器数量 (或实例数量)超出授权上限 | 请减少运行模型的服务器数量、 或实例数量 |
Environment is unsafe | 运行环境不安全,可能是license的版本不对或者人为修改了license。 | |
cache client get context error: Connection refused | 鉴权服务连接本机缓存失败,可能原因:7091和7092缓存端口没有启动,或者部署时填写的鉴权节点IP有误 |
2)检查是否启动成功
从/home/baidu/work/c-offline-security-server/log/auth_server.log查看鉴权服务启动日志
启动成功日志如下:
从/home/baidu/work/c-offline-security-server/log/aipeinfo当天日期.log查看算子应用程序向鉴权服务发起请求的日志
启动成功日志如下:
加密狗方式(硬件)鉴权
如果使用了加密狗硬件辅助鉴权,除了按照上文【机器指纹方式(软件)鉴权】提到的排查思路依次进行排查以外,
需要额外检查以下内容
1)加密狗驱动是否运行
service codemeter status
正常情况下返回 CodeMeter Server is running.
2)加密狗硬件是否被机器识别
cmu -x
识别成功的结果如下
cmu - CodeMeter Universal Support Tool.
Version 6.70 of 2018-Jul-19 (Build 3152) for Linux
Copyright (C) 2007-2018 by WIBU-SYSTEMS AG. All rights reserved.
List all locally connected CmContainers:
- CmContainer with Serial Number 3-4512221 and version 4.10 ...
Result: 1 CmContainer(s) listed.
识别失败的结果如下:
cmu - CodeMeter Universal Support Tool.Version 6.70 of 2018-Jul-19 (Build 3152) for LinuxCopyright (C)
2007-2018 by WIBU-SYSTEMS AG. All rights reserved.List all locally connected CmContainers:Result:
0 CmContainer(s) listed.
查看license信息
curl 0.0.0.0:8443/security/license
返回示例如下
{"dogCount":0,"fingerType":3,"holder":"15322","info":"license","issued":"2021-10-12 16:27:36",
"issuer":"baidu","productLicenses":[{"functions":[],"instanceSize":1,"notAfter":"2021-11-26
00:00:00","notBefore":"2021-10-11 00:00:00","qps":0,"subject":"general_nor"}],"safeType"
:1,"securityType":2}
license有效期为 notBefore ~ notAfter