Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Solution to Oracle 12.2 snooping unable to start

2025-01-17 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

When I was doing an experiment in my virtual machine, I suddenly found that I could not connect to the database using PL/SQL Developer, and I reported an error ORA-12514, saying that the monitoring was not started.

First introduce the virtual machine environment: redhat7.2+GI 12.2.0.1+Oracle 12.2.0.1, GI is installed to test the ASM feature of 12.2. Usually, the listener is turned on and started by default. But I don't know why it didn't start today. Use crsctl to view resource status: find that the monitoring status is indeed OFFLINE status

[root@rhel7 .oracle] # crsstat----Name Target State Server State details- -Local Resources -- ora.DATA.dg ONLINE ONLINE rhel7 STABLEora.LISTENER.lsnr ONLINE OFFLINE rhel7 STABLEora.asm ONLINE ONLINE rhel7 Started STABLEora.ons OFFLINE OFFLINE rhel7 STABLE----Cluster Resources -ora.cssd 1 ONLINE ONLINE rhel7 STABLEora.diskmon 1 OFFLINE OFFLINE STABLEora.driver.afd 1 ONLINE ONLINE rhel7 STABLEora.evmd 1 ONLINE ONLINE rhel7 STABLEora.ora12c. Db 1 ONLINE ONLINE rhel7 Open HOME=/u01/app/o racle/product/12.2/d bachelorette Home1 and STABLERULARULICUR-

Try to start monitoring manually, but still report an error:

[grid@rhel7 ~] $srvctl start listenerPRCR-1079: Failed to start resource ora.LISTENER.lsnrCRS-5016: Process "/ u01/app/grid/bin/lsnrctl" spawned by agent "ORAAGENT" for action "start" failed: details at "in" / u01/app/12.2/grid/diag/crs/rhel7/crs/trace/ohasd_oraagent_grid.trc "CRS-5016: Process" / u01/app/grid/bin/lsnrctl "spawned by agent" ORAAGENT "for action" start "failed : details at "(: CLSN00010:)" in "/ u01/app/12.2/grid/diag/crs/rhel7/crs/trace/ohasd_oraagent_grid.trc" CRS-2674: Start of 'ora.LISTENER.lsnr' on' rhel7' failed

When prompted to view the trc file, you can see the following error:

LSNRCTL for Linux: Version 12.2.0.1.0-Production on 15-NOV-2017 20:03:28Copyright (c) 1991, 2016, Oracle. All rights reserved.Starting / u01/app/grid/bin/tnslsnr: please wait...TNSLSNR for Linux: Version 12.2.0.1.0-ProductionSystem parameter file is / u01/app/grid/network/admin/listener.oraLog messages written to / u01/app/12.2/grid/diag/tnslsnr/rhel7/listener/alert/log.xmlListening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=rhel7) (PORT=1521) Error listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)) TNS-12555: TNS:permission denied TNS-12560: TNS:protocol adapter error TNS-00525: Insufficient privilege for operation Linux Error: 1: Operation not permittedListener failed to start. See the error message (s) above...

When I saw the word Insufficient privilege for operation, I wondered why the permissions were insufficient, so I tried to start listening directly with root and still reported an error:

[root@rhel7 .oracle] # lsnrctl startLSNRCTL for Linux: Version 12.2.0.1.0-Production on 15-NOV-2017 20:22:30Copyright (c) 1991, 2016, Oracle. All rights reserved.Starting / u01/app/grid/bin/tnslsnr: please wait...TNS-12546: TNS:permission denied TNS-12560: TNS:protocol adapter error TNS-00516: Permission denied Linux Error: 13: Permission denied

So all kinds of Baidu, the following list of Baidu to the content may be useful for the students who read this article, but it is not useful for me:

It is mainly about the permission access of / var/tmp/.oracle and / tmp/.oracle. As soon as I enter it, my / var/tmp/.oracle permissions are fine, and / tmp/.oracle doesn't have this file at all.

So check MOS directly to see if there are any relevant documents, and find two documents:

Starting the Listener Fails With: TNS-12557 or TNS-12555: TNS:Permission Denied (document ID 343253.1)

Listener Fails To Start With IPC Permission Errors (TNS-12546 TNS-12555 TNS-00516 TNS-00525) (document ID 434062.1)

Compared with the problems listed in the document, which is not the same as my situation, I finally found this sentence:

If you find that there are no adapters linked or they have errors (such as "Permission denied") then issue a "relink all"

Reference:

Doc ID 1467060.1

So we have to try it this way, because crs uses the listening command under grid home, so do relink all operation on grid home. But there was another error:

[grid@rhel7 bin] $relink all The Oracle home in which you are running this relinking tool does not have proper write permissions. Please run this relink script as the sameuser who owns the Oracle home and ensure that the Oracle home has thepermissions from the original installation. If this is a Grid Infrastructure home, please refer to the documentation for the proper steps to relink and apply oneoff patches.

It means that the permission is insufficient, it is executed with root, and it is wrongly reported that it cannot be executed with root.

[root@rhel7 bin] # relink allThe relink script cannot be run as root.

Check the grid home directory permissions again

[root@rhel7 app] # ls-ld gridtotal 8drwxrMurray-84 root oinstall 4096 Jul 18 20:26 grid

It turns out that owner is root. No wonder the first execution is unsuccessful. Modify owner (it should also be possible to directly chmod, there is no test here), and re-execute relink all.

[root@rhel7 app] # chown grid grid [grid@rhel7 ~] $relink allwriting relink log to: / u01/app/grid/install/relink.log

After success, start monitoring again, and start successfully.

[grid@rhel7] $lsnrctl startLSNRCTL for Linux: Version 12.2.0.1.0-Production on 15-NOV-2017 20:50:59Copyright (c) 1991, 2016, Oracle. All rights reserved.Starting / u01/app/grid/bin/tnslsnr: please wait...TNSLSNR for Linux: Version 12.2.0.1.0-ProductionSystem parameter file is / u01/app/grid/network/admin/listener.oraLog messages written to / u01/app/12.2/grid/diag/tnslsnr/rhel7/listener/alert/log.xmlListening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=rhel7) (PORT=1521)) Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521)) Connecting to (DESCRIPTION= ( ADDRESS= (PROTOCOL=TCP) (HOST=rhel7) (PORT=1521)) STATUS of the LISTENER----Alias LISTENERVersion TNSLSNR for Linux: Version 12.2.0.1.0-ProductionStart Date 15-NOV-2017 20:51:00Uptime 0 days 0 hr. 0 min. 0 secTrace Level offSecurity ON: Local OS AuthenticationSNMP OFFListener Parameter File / u01/app/grid/network/admin/listener.oraListener Log File / u01/app/12.2/grid/diag/tnslsnr/rhel7/listener/alert/log.xmlListening Endpoints Summary... (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=rhel7) (PORT=1521) (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521) The listener supports no servicesThe command completed successfully

Once and for all, problem solved.

Summary

The above is the Oracle 12.2 monitoring can not start the solution introduced by the editor, I hope it will be helpful to you, if you have any questions, please leave me a message, the editor will reply you in time. Thank you very much for your support to the website!

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report