SUSE Linux9下Oracle10g監聽問題筆記

來源:互聯網
上載者:User

環境:

作業系統:SUSE Linux9

資料庫: Oracle10gR2

1:更改主機host

[root@www ~]# hostname

linux

[root@www ~]# hostname test11

[root@www ~]# hostname

test11

[root@www ~]#

2:嘗試重啟監聽

oracle@linux:/> lsnrctl stop

LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 29-11月-2006 16:51:09

Copyright (c) 1991, 2005, Oracle.  All rights reserved.

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))

The command completed successfully

oracle@linux:/> lsnrctl start

LSNRCTL for Linux: Version 10.2.0.1.0 - Production on 29-11月-2006 16:51:32

Copyright (c) 1991, 2005, Oracle.  All rights reserved.

Starting /free/oracle/product/10.2.0/db_1/bin/tnslsnr: please wait...

TNSLSNR for Linux: Version 10.2.0.1.0 - Production

System parameter file is /free/oracle/product/10.2.0/db_1/network/admin/listener.ora

Log messages written to /free/oracle/product/10.2.0/db_1/network/log/listener.log

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1)))

Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521)))

Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1)))

STATUS of the LISTENER

------------------------

Alias                     LISTENER

Version                   TNSLSNR for Linux: Version 10.2.0.1.0 - Production

Start Date                29-11月-2006 16:51:32

Uptime                    0 days 0 hr. 0 min. 42 sec

Trace Level               off

Security                  ON: Local OS Authentication

SNMP                      OFF

Listener Parameter File   /free/oracle/product/10.2.0/db_1/network/admin/listener.ora

Listener Log File         /free/oracle/product/10.2.0/db_1/network/log/listener.log

Listening Endpoints Summary...

(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1)))

(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=127.0.0.1)(PORT=1521)))

Services Summary...

Service "PLSExtProc" has 1 instance(s).

Instance "PLSExtProc", status UNKNOWN, has 1 handler(s) for this service...

The command completed successfully

可以看到,監聽啟動很慢,但是最後還是能啟動成功,其實這是假象,我們測試即可得知。

其實監聽在每次啟動時刻會去讀系統的主機名稱,然後根據主機名稱啟動lsnrctl。

3:測試監聽串連的有效性

下面的standby是本地目錄服務名。

oracle@linux:> sqlplus "sys/cicro@standby as sysdba"

SQL*Plus: Release 10.2.0.1.0 - Production on 星期三 11月 29 17:04:24 2006

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

ERROR:

ORA-12541: TNS:no listener

oracle@linux:> sqlplus "/as sysdba"

SQL*Plus: Release 10.2.0.1.0 - Production on 星期三 11月 29 17:07:32 2006

Copyright (c) 1982, 2005, Oracle.  All rights reserved.

Connected.

SQL> shutdown immediate

ORA-24324: service handle not initialized

ORA-24323: value not allowed

ORA-00600: internal error code, arguments: [%s], [%s], [%s], [%s], [%s], [%s], [%s], [%s]

SQL>

SQL> select host_name from v$instance;

HOST_NAME

--------------------------------------------------------------------------------

linux

可以看到,此時關閉資料庫也報錯。資料庫 v$instance中記錄的hostname是linux,但是此時host name已經修改成了test11

  • 1
  • 2
  • 3
  • 4
  • 下一頁

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.