今天,在玩 lsnrctl命令,是为了了解Oracle的一些配置。
当执行 show inbound_connect_timeout 命令之后,提示了错误信息:
TNS-01190: The user is not authorized to execute the requested listener command
解决方案:
查看lsnrctl 进程是由哪个用户启动的,在我这里是grid 用户。之前使用的是oracle用户,所以导致以上的错误。
ps -ef | grep lsnrctl
从输出信息中可以看到是哪个用户启动了lsnrctl 进程。
然后使用从上面查到的用户执行lsnrctl 命令,例如我这里是 grid 用户:
sudo -u grid lsnrctl
然后再执行 show inbound_connect_timeout已经不会报错了。