Linux Error: 29: Illegal seek

SQL> !cat /etc/issue
Enterprise Linux Enterprise Linux Server release 5.5 (Carthage)
Kernel \r on an \m




SQL> select * from v$version where rownum<2;


BANNER
--------------------------------------------------------------------------------
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - Production



今天打开监听程序时,报以下错误:
TNS-12560: TNS:protocol adapter error
  TNS-00507: Connection closed
        Linux Error: 29: Illegal seek
开始认为是Linux本身内部错误,检查hosts文件: 
[oracle@localhost ~]$ cat /etc/hosts
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1               localhost.localdomain localhost
::1             localhost6.localdomain6 localhost6
没有什么问题。


检查listener.ora:
LISTENER =
  (DESCRIPTION =
    (ADDRESS = (PROTOCOL = TCP)(HOST = localhost.localdomain)(PORT = 1521))
  )


SID_LIST_LISTENER =
  (SID_LIST =
    (SID_DESC =       
      (GLOBAL_DBNAME = jing)
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1)
      (SID_NAME = orcl3939)
    )
    (SID_DESC =
      (GLOBAL_DBNAME = tai)
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1)
      (SID_NAME = orcl3939)
    )
  )




SID_LIST_WEN =
  (SID_LIST =
    (SID_DESC =
      (SID_NAME = PLSExtProc)
      (ORACLE_HOME = /u01/app/oracle/product/11.2.0/dbhome_1)
      (PROGRAM = extproc)
    )
  )
WEN =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS = (PROTOCOL = TCP)(HOST = localhost.localdomain)(PORT = 1522))
      (ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC0))
    )
  )




检查tnsnames.ora:

diy =
(DESCRIPTION =
    (ADDRESS_LIST =
        (ADDRESS=(PROTOCOL=TCP)(HOST = localhost.localdomain)(PORT = 1522))
    )
)

SQL> show parameter local_listener;


NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
local_listener                       string      DIY
SQL> show parameter service_names;


NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
service_names                        string      a,b,c,d,diy
SQL> show parameter instance_name;


NAME                                 TYPE        VALUE
------------------------------------ ----------- ------------------------------
instance_name                        string      orcl3939


以上检查没有异样。
然后重启os后,竟然可以启动监听程序:
[oracle@localhost ~]$ lsnrctl start listener


LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 05-8月 -2015 22:01:27


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


启动/u01/app/oracle/product/11.2.0/dbhome_1/bin/tnslsnr: 请稍候...


 TNSLSNR for Linux: Version 11.2.0.1.0 - Production
系统参数文件为/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
写入/u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml的日志信息
写入/u01/app/oracle/diag/tnslsnr/localhost/listener/trace/ora_5336_3086415552.trc的跟踪信息
监听: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))


正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost.localdomain)(PORT=1521)))
LISTENER 的 STATUS
------------------------
别名                      listener
版本                      TNSLSNR for Linux: Version 11.2.0.1.0 - Production
启动日期                  05-8月 -2015 22:01:27
正常运行时间              0 天 0 小时 0 分 0 秒
跟踪级别                  support
安全性                    ON: Local OS Authentication
SNMP                      OFF
监听程序参数文件          /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
监听程序日志文件          /u01/app/oracle/diag/tnslsnr/localhost/listener/alert/log.xml
监听程序跟踪文件          /u01/app/oracle/diag/tnslsnr/localhost/listener/trace/ora_5336_3086415552.trc
监听端点概要...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1521)))
服务摘要..
服务 "jing" 包含 1 个实例。
  实例 "orcl3939", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
服务 "tai" 包含 1 个实例。
  实例 "orcl3939", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
命令执行成功
[oracle@localhost ~]$  lsnrctl start wen


LSNRCTL for Linux: Version 11.2.0.1.0 - Production on 05-8月 -2015 22:01:36


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


启动/u01/app/oracle/product/11.2.0/dbhome_1/bin/tnslsnr: 请稍候...


TNSLSNR for Linux: Version 11.2.0.1.0 - Production
系统参数文件为/u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
写入/u01/app/oracle/diag/tnslsnr/localhost/wen/alert/log.xml的日志信息
监听: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1522)))
监听: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))


正在连接到 (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=localhost.localdomain)(PORT=1522)))
LISTENER 的 STATUS
------------------------
别名                      wen
版本                      TNSLSNR for Linux: Version 11.2.0.1.0 - Production
启动日期                  05-8月 -2015 22:01:38
正常运行时间              0 天 0 小时 0 分 0 秒
跟踪级别                  off
安全性                    ON: Local OS Authentication
SNMP                      OFF
监听程序参数文件          /u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.ora
监听程序日志文件          /u01/app/oracle/diag/tnslsnr/localhost/wen/alert/log.xml
监听端点概要...
  (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=localhost.localdomain)(PORT=1522)))
  (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC0)))
服务摘要..
服务 "PLSExtProc" 包含 1 个实例。
  实例 "PLSExtProc", 状态 UNKNOWN, 包含此服务的 1 个处理程序...
命令执行成功

以上原因不清楚是OS还是oracle造成的。网上有朋友遇到同样错误解决的方法 blog.chinaunix.net/uid-20048945-id-471098.html,尚不明白我重启后可以使用。

你可能感兴趣的:(Linux Error: 29: Illegal seek)