用户进程报错并退出。
查看应用类日志,提示获取Device信息失败,最终导致AscendCL初始化失败,日志片段示例如下:
[ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.635 [runtime.cc:1065]89696 CheckHaveDevice:[INIT][DEFAULT]Call halGetDeviceInfo failed: drvRet=4, module type=0, info type=1. [ERROR] ASCENDCL(89696,main):2023-03-07-17:13:27.994.723 [acl.cpp:164]89696 aclInit: [INIT][DEFAULT][Init][Version]init soc version failed, ret = 507008 [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.774 [api_impl.cc:3490]89696 GetDevErrMsg:report error module_type=3, module_name=EE8888 [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.798 [api_impl.cc:3490]89696 GetDevErrMsg:ctx is NULL! [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.827 [api_impl.cc:3546]89696 GetDevMsg:Failed to GetDeviceErrMsg, retCode=0x7070001. [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.849 [logger.cc:1348]89696 GetDevMsg:GetDeviceMsg failed, getMsgType=0. [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.888 [api_c.cc:3595]89696 rtGetDevMsg:ErrCode=107002, desc=[context pointer null], InnerCode=0x7070001 [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.910 [error_message_manage.cc:49]89696 FuncErrorReason:report error module_type=3, module_name=EE8888 [ERROR] RUNTIME(89696,main):2023-03-07-17:13:27.994.932 [error_message_manage.cc:49]89696 FuncErrorReason:rtGetDevMsg execute failed, reason=[context pointer null] EL0003: The argument is invalid. Solution: Try again with a valid argument. TraceBack (most recent call last): [Init][Version]init soc version failed, ret = 507008[FUNC:ReportInnerError][FILE:log_inner.cpp][LINE:145] ctx is NULL![FUNC:GetDevErrMsg][FILE:api_impl.cc][LINE:3490] rtGetDevMsg execute failed, reason=[context pointer null][FUNC:FuncErrorReason][FILE:error_message_manage.cc][LINE:49] [ERROR] acl init failed [ERROR] Sample init resource failed
可能存在以下原因:
cat /etc/ascend_install.info
在该文件中,Driver_Install_Path_Param表示Driver包的安装路径。
./upgrade-tool --device_index -1 --system_version
正常查询返回信息类似如下:
要求运行应用程序的用户,需与Driver运行用户在一个属组内。在“cat /etc/passwd”文件中,可查看用户属组,Driver的默认运行用户为HwHiAiUser。
修改用户属组的命令示例如下:
usermod -g 组名 用户名