您的位置:首页 > 数据库 > Oracle

oracle监听器启动错误-TNS-12546: TNS:permission denied

2014-07-11 23:04 309 查看
今天一台数据库服务器登录不上,报TNS-12541: TNS:no listener

到服务器上看下监听器状态

 

1.    oracle@linux-34:~> lsnrctl status 

2.   

3.    LSNRCTL for Linux: Version 11.1.0.6.0 - Production on 14-OCT-2011 09:12:37 

4.   

5.    Copyright (c) 1991, 2007, Oracle.  All rights reserved. 

6.   

7.    Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=linux-34.site)(PORT=1521))) 

8.    TNS-12541: TNS:no listener 

9.    TNS-12560: TNS:protocol adapter error 

10.     TNS-00511: No listener 

11.      Linux Error: 111: Connection refused 

12.   Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=IPC)(KEY=EXTPROC1521))) 

13.   TNS-12541: TNS:no listener 

14.   TNS-12560: TNS:protocol adapter error 

15.     TNS-00511: No listener 

16.      Linux Error: 111: Connection refused

启动下试试

 

1.    oracle@linux-34:~> lsnrctl start 

2.   

3.    LSNRCTL for Linux: Version 11.1.0.6.0 - Production on 14-OCT-2011 09:12:45 

4.   

5.    Copyright (c) 1991, 2007, Oracle.  All rights reserved. 

6.   

7.    Starting /home/oracle/product/11.1.0/db_1/bin/tnslsnr: please wait... 

8.   

9.    TNSLSNR for Linux: Version 11.1.0.6.0 - Production 

10.   System parameter file is /home/oracle/product/11.1.0/db_1/network/admin/listener.ora 

11.   Log messages written to /home/oracle/diag/tnslsnr/linux-34/listener/alert/log.xml 

12.   Error listening on: (ADDRESS=(PROTOCOL=ipc)(PARTIAL=yes)(QUEUESIZE=1)) 

13.   No longer listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=linux-34.site)(PORT=1521))) 

14.   TNS-12546: TNS:permission denied 

15.   TNS-12560: TNS:protocol adapter error 

16.     TNS-00516: Permission denied 

17.      Linux Error: 13: Permission denied 

18.  

19.   Listener failed to start. See the error message(s) above...

竟然报TNS-12546: TNS:permission denied

查看下 /var/tmp/.oracle、/tmp/.oracle 这两个目录的权限访问。

 

1.    linux-34:~ # ls -lrtd /tmp/.oracle 

2.    drwxrwxrwx 2 root root 4096 May  9 16:01 /tmp/.oracle 

3.   

4.    linux-34:~ # ls -lrtd /var/tmp/.oracle 

5.    drwxr-xr-x 2 root root 4096 Oct 14 09:45 /var/tmp/.oracle

原因应该就在这了,/var/tmp/.oracle是755权限,把它修改为777。

chmod -R 777 /var/tmp/.oracle 

然后再启动监听试试。

 

1.    oracle@linux-34:~> lsnrctl start 

2.   

3.    LSNRCTL for Linux: Version 11.1.0.6.0 - Production on 14-OCT-2011 09:45:04 

4.   

5.    Copyright (c) 1991, 2007, Oracle.  All rights reserved. 

6.   

7.    Starting /home/oracle/product/11.1.0/db_1/bin/tnslsnr: please wait... 

8.   

9.    TNSLSNR for Linux: Version 11.1.0.6.0 - Production 

10.   System parameter file is /home/oracle/product/11.1.0/db_1/network/admin/listener.ora 

11.   Log messages written to /home/oracle/diag/tnslsnr/linux-34/listener/alert/log.xml 

12.   Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=linux-34.site)(PORT=1521))) 

13.   Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) 

14.  

15.   Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=linux-34.site)(PORT=1521))) 

16.   STATUS of the LISTENER 

17.   ------------------------ 

18.   Alias                     LISTENER 

19.   Version                   TNSLSNR for Linux: Version 11.1.0.6.0 - Production 

20.   Start Date                14-OCT-2011 09:45:04 

21.   Uptime                    0 days 0 hr. 0 min. 0 sec 

22.   Trace Level               off

23.   Security                  ON: Local OS Authentication 

24.   SNMP                      OFF

25.   Listener Parameter File   /home/oracle/product/11.1.0/db_1/network/admin/listener.ora 

26.   Listener Log File         /home/oracle/diag/tnslsnr/linux-34/listener/alert/log.xml 

27.   Listening Endpoints Summary... 

28.     (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=linux-34.site)(PORT=1521))) 

29.     (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) 

30.   The listener supports no services 

31.   The command completed successfully 

32.   oracle@linux-34:~> lsnrctl status 

33.  

34.   LSNRCTL for Linux: Version 11.1.0.6.0 - Production on 14-OCT-2011 09:46:02 

35.  

36.   Copyright (c) 1991, 2007, Oracle.  All rights reserved. 

37.  

38.   Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=linux-34.site)(PORT=1521))) 

39.   STATUS of the LISTENER 

40.   ------------------------ 

41.   Alias                     LISTENER 

42.   Version                   TNSLSNR for Linux: Version 11.1.0.6.0 - Production 

43.   Start Date                14-OCT-2011 09:45:04 

44.   Uptime                    0 days 0 hr. 0 min. 58 sec 

45.   Trace Level               off

46.   Security                  ON: Local OS Authentication 

47.   SNMP                      OFF

48.   Listener Parameter File   /home/oracle/product/11.1.0/db_1/network/admin/listener.ora 

49.   Listener Log File         /home/oracle/diag/tnslsnr/linux-34/listener/alert/log.xml 

50.   Listening Endpoints Summary... 

51.     (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=linux-34.site)(PORT=1521))) 

52.     (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1521))) 

53.   Services Summary... 

54.   Service "orarpt" has 1 instance(s). 

55.     Instance "orarpt", status READY, has 1 handler(s) for this service... 

56.   Service "orarpt_XPT" has 1 instance(s). 

57.     Instance "orarpt", status READY, has 1 handler(s) for this service... 

58.   The command completed successfully

问题解决。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐