我创建了一个名为 listener 的监听器(使用 netca)。
当我启动监听器(使用 lsnrctl start)时,我有以下日志。
LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 24-JUN-2012 17:56:35 Copyright (c) 1991, 2009, Oracle. All rights reserved. Starting /opt/oracle/eesrv/11.2.0/db1/bin/tnslsnr: please wait... TNSLSNR for Linux: Version 11.2.0.1.0 - Production System parameter file is /opt/oracle/network/listener.ora Log messages written to /opt/oracle/diag/tnslsnr/sakura/listener/alert/log.xml Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521))) Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=sakura)(PORT=1521))) STATUS of the LISTENER ------------------------ Alias LISTENER Version TNSLSNR for Linux: Version 11.2.0.1.0 - Production Start Date 24-JUN-2012 17:56:35 Uptime 0 days 0 hr. 0 min. 10 sec Trace Level off Security ON: Local OS Authentication SNMP OFF Listener Parameter File /opt/oracle/network/listener.ora Listener Log File /opt/oracle/diag/tnslsnr/sakura/listener/alert/log.xml Listening Endpoints Summary... (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521))) The listener supports no services The command completed successfully
问:为什么听众在 localhost 而不是 sakura 上收听?!?
这是我的 listener.ora 文件(我明确指定使用 sakura):
TRACE_DIRECTORY_PROD = /var/opt/oracle/otk/1.0/log/network/trace
SUBSCRIBE_FOR_NODE_DOWN_EVENT_PROD = 关闭
LISTENER = (DESCRIPTION_LIST = (DESCRIPTION = (ADDRESS = (PROTOCOL = TCP)(HOST = sakura)(PORT = 1521)) ) )
ADR_BASE_LISTENER = /opt/oracle
LOG_DIRECTORY_PROD = /var/opt/oracle/otk/1.0/log/network
为什么我做错了?
谢谢