你这个是要先在root下输入 xhost +
如果是远程连接的话,需要在oracle用户下的命令行输入 export DISPLAY=你本机的IP地址:0.0
手工命令行配置
一、修改listener.ora文件内容
命令:[oracle@gpdb ~]$ vi /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
内容:
SID_LIST_LISTENER=
(SID_LIST=
(SID_DESC=
(GLOBAL_DBNAME= orcl)
(ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1)
(SID_NAME=orcl)
)
)
LISTENER=(DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.1.121)(PORT=1521)))
ADR_BASE_LISTENER = /u01/app/oracle
二、修改tnsnames.ora文件内容
命令:[oracle@gpdb ~]$ vi /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/tnsnames.ora
内容:
orcl =
(DESCRIPTION =
(ADDRESS_LIST =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.1.121)(PORT = 1521))
)
(CONNECT_DATA =
(SID = orcl)
)
)
三、启动监听并更新注册收起
如果觉得《liunx 查看oracle监听 Linux配置Oracle监听提示异常》对你有帮助,请点赞、收藏,并留下你的观点哦!