• 周六. 7 月 27th, 2024

5G编程聚合网

5G时代下一个聚合的编程学习网

热门标签

使用DB2数据库切换用户启动时提示SQL10007N Message "-1390" could not be retrieved. Reason code: "3".

admin

11 月 28, 2021

今天要使用DB2数据库,切换db2inst1用户时在linux shell中不显示路径了,显示为-bash-4.1#。

并且在使用DB2的命令时提示SQL10007N Message “-1390” could not be retrieved.  Reason code: “3”.

经过查询资料后发现应该是环境变量的问题。

cd /home/db2inst1
vim ~/.bash_profile

在db2inst1用户的环境变量文件中添加:

export PATH=$PATH:$HOME/bin:/home/db2inst1/sqllib/bin
if [ -f /home/db2inst1/sqllib/db2profile ]
then
source /home/db2inst1/sqllib/db2profile
fi

记得使环境变量生效

source ~/.bash_profile

此时恢复正常

发表回复