In addition to Weibo, there is also WeChat
Please pay attention
WeChat public account
Shulou
2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >
Share
Shulou(Shulou.com)06/01 Report--
Method 1: login will display the version number [oracle@ogg1 ~] $sqlplus / as sysdba # sometimes directly enter # sqlplusSQL*Plus: Release 11.2.0.3.0 Production on trickle 7 17:51:14 2015Copyright (c) 1982, 2011, Oracle. All rights reserved. Method 2: SQL > select * from v$version BANNER----Oracle Database 11g Enterprise Edition Release 11.2.0.3.0-64bit ProductionPL/SQL Release 11.2.0.3.0-ProductionCORE 11.2.0. 3.0 ProductionTNS for Linux: Version 11.2.0.3.0-ProductionNLSRTL Version 11.2.0.3.0-Production logs in as sysdba such as conn / as sysdba anonymous administrator to view SID1. Log in as sysdba such as conn / as sysdba2.select instance_name from vault instance; check the user name select * from dba_users;-check all the users in the database, provided you have an account with dba authority, such as sys,systemselect * from all_users;-check all the users you can manage! Select * from user_users;-View current user information! -[oracle@redhat4 ~] $lsnrctl statusLSNRCTL for Linux: Version 11.2.0.1.0-Production on 06-OCT-2015 21:10:05Copyright (c) 1991 2009, Oracle. All rights reserved.Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)) STATUS of the LISTENER----Alias LISTENERVersion TNSLSNR for Linux: Version 11.2.0.1.0-ProductionStart Date 06-OCT-2015 19:45:16Uptime 0 days 1 hr. 24 min. 49 secTrace Level offSecurity ON: Local OS AuthenticationSNMP OFFListener Parameter File / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.oraListener Log File / u01/app/oracle/diag/tnslsnr/redhat4/listener/alert/log.xmlListening Endpoints Summary... (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521) (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=redhat4.7) (PORT=1521)) Services Summary...Service "ora11g" has 1 instance (s) Instance "ora11g", status READY, has 1 handler (s) for this service...Service "ora11gXDB" has 1 instance (s). Instance "ora11g", status READY, has 1 handler (s) for this service...Service "orcl.7" has 1 instance (s). Instance "orcl", status READY, has 1 handler (s) for this service...Service "orclXDB.7" has 1 instance (s). Instance "orcl", status READY, has 1 handler (s) for this service...The command completed successfully [oracle@redhat4] $lsnrctl stopLSNRCTL for Linux: Version 11.2.0.1.0-Production on 06-OCT-2015 21:10:14Copyright (c) 1991, 2009, Oracle. All rights reserved.Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521)) The command completed successfully [oracle@redhat4] $lsnrctl startLSNRCTL for Linux: Version 11.2.0.1.0-Production on 06-OCT-2015 21:10:26Copyright (c) 1991, 2009, Oracle. All rights reserved.Starting / u01/app/oracle/product/11.2.0/dbhome_1/bin/tnslsnr: please wait...TNSLSNR for Linux: Version 11.2.0.1.0-ProductionSystem parameter file is / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.oraLog messages written to / u01/app/oracle/diag/tnslsnr/redhat4/listener/alert/log.xmlListening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521) Listening on: (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=redhat4.7) (PORT=1521)) Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=IPC) (KEY=EXTPROC1521) STATUS of the LISTENER----Alias LISTENERVersion TNSLSNR for Linux: Version 11.2.0.1.0-ProductionStart Date 06-OCT-2015 21:10:26Uptime 0 days 0 hr. 0 min. 0 secTrace Level offSecurity ON: Local OS AuthenticationSNMP OFFListener Parameter File / u01/app/oracle/product/11.2.0/dbhome_1/network/admin/listener.oraListener Log File / u01/app/oracle/diag/tnslsnr/redhat4/listener/alert/log.xmlListening Endpoints Summary... (DESCRIPTION= (ADDRESS= (PROTOCOL=ipc) (KEY=EXTPROC1521) (DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=redhat4.7) (PORT=1521) The listener supports no servicesThe command completed successfully
(summary) detailed explanation of lsnrctl parameters and query status of Oracle snooping service
Common parameters of lsnrctl command are explained in detail:
Lsnrctl
Start
Start the specified listener
Stop
Close the specified listener
Status
Displays the status of the listener. The status command shows whether the listener is active, the location of the log and trace files, how long the listener has been running, and the tasks the listener is listening for. As shown in the following figure:
Services
List the listener's service information, such as whether these services have any dedicated pre-generated server processes or associated scheduling processes, and how many connections have been accepted or rejected for each service. This method is used to check whether a listener is listening on a specified service.
Lists a summary of services and the number of connection information established and rejected for each protocol service handler.
Version
Displays the version of the oracle net software and protocol adapter.
Reload
Reload the listener, re-read the listener.ora file, but do not close the listener. If the file changes, refresh the listener.
Save_config
When you make changes to the listener.ora file from the lsnrctl tool, copy a listener.ora file called listener.bak.
Trace
Turn on the tracking feature of the listener.
Change_password
Allows the user to change the password required to turn off the listener.
Quit
Exit the lsnrctl tool.
Exit
Exit the lsnrctl tool.
Set*
Password
Specify the password required to perform administrative tasks in the lsnrctl command line tool.
Rawmode
Displaymode
Trc_file
Specifies the location of the listener tracking information. The default setting is $ORACLE_HOME\ network\ trace\ listener.trc
Trc_directory
Trc_level
Tracking level
OFF-tracing is not enabled. OFF is the default setting.
USER-sets the trace to the appropriate level for the user. Trace to identify the error condition caused by the user.
ADMIN-sets the trace to the appropriate level of the database administrator. Track to identify specific installation issues.
SUPPORT-set tracking to the appropriate level of customer support personnel. The trace file can become very large.
Oracle Corporation recommends that you turn off tracking when you are not diagnosing network problems.
Log_file
Specify where a listener will write log information. This parameter is ON by default and defaults to% oracle_home%\ network\ log\ listener.log
Log_directory
Log_status
Current_listener
Inbound_connect_timeout
Defines the effective response time that the listener will wait when a session is started. The default setting is 10 seconds.
Startup_waittime
Defines how long the listener will wait before responding to a status command in the lsnrctl command line tool.
Save_config_on_stop
Specifies whether changes that occur during a lsnrctl session should be saved on exit.
Show*
Rawmode
Displays more detailed information about status and service (when they are set to on) with a value of ON or OFF.
Displaymode
Set the display mode of the lsnrctl tool to raw, compact, normal, or verbose
The service display mode is NORMAL
Rules
Trc_file
Specifies the location of the listener tracking information. The default setting is $ORACLE_HOME\ network\ trace\ listener.trc
Current_listener
The current listener is listener2
Inbound_connect_timeout
Defines the effective response time that the listener will wait when a session is started. The default setting is 10 seconds.
Startup_waittime
Defines how long the listener will wait before responding to a status command in the lsnrctl command line tool.
Snmp_visible
Save_config_on_stop
Specifies whether changes that occur during a lsnrctl session should be saved on exit.
Detailed description of query status of part of lsnrctl:
LSNRCTL > status
Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=ocm1.oracle.domain) (PORT=1521)
STATUS of the LISTENER
-
Alias LISTENER
Version TNSLSNR for Linux: Version 10.2.0.1.0-Production
Start Date 17-MAY-2011 21:03:40
Uptime 0 days 0 hr. 2 min. 49 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File / u01/app/oracle/product/10.2.1/db/network/admin/listener.ora
Listener Log File / u01/app/oracle/product/10.2.1/db/network/log/listener.log
Listening Endpoints Summary...
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=1521))
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=1522))
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=1600))
Services Summary...
Service "POD" has 1 instance (s).
Instance "POD", status READY, has 1 handler (s) for this service...
Service "POD1" has 1 instance (s).
Instance "POD", status UNKNOWN, has 1 handler (s) for this service...
Service "PODS" has 1 instance (s).
Instance "POD", status READY, has 2 handler (s) for this service...
Service "pod_XPT" has 1 instance (s).
Instance "POD", status READY, has 1 handler (s) for this service...
Service "repos" has 2 instance (s).
Instance "repos", status UNKNOWN, has 1 handler (s) for this service...
Instance "repos", status READY, has 1 handler (s) for this service...
Service "repos_XPT" has 1 instance (s).
Instance "repos", status READY, has 1 handler (s) for this service...
The command completed successfully
Status detailed explanation
Listening Endpoints Summary...
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=1521))
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=1522))
(DESCRIPTION= (ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=1600))
# this indicates that the address of the host is ocm1.oracle.domain, and the open listening ports are 1521, 1522, 1600.
Services Summary...
Service "POD" has 1 instance (s).
Instance "POD", status READY, has 1 handler (s) for this service...
# indicates that there is a service with the service name POD, the database instance is named POD, and the status READY indicates that it is currently registered dynamically
Service "POD1" has 1 instance (s).
Instance "POD", status UNKNOWN, has 1 handler (s) for this service...
# it is stated here that there is a service named POD1, and the instance of the database is named POD. The status UNKNOWN indicates that it is currently registered statically.
Service "PODS" has 1 instance (s).
Instance "POD", status READY, has 2 handler (s) for this service...
# it is stated here that there is a service named PODS, the database instance is named POD, and the status READY indicates that it is dynamically registered
Service "repos" has 2 instance (s).
Instance "repos", status UNKNOWN, has 1 handler (s) for this service...
Instance "repos", status READY, has 1 handler (s) for this service...
The command completed successfully
# it is stated here that there is a service named repos, and the corresponding database instance has a status of repos,UNKNOWN,READY, indicating that it currently has a static registration and a dynamic registration.
LSNRCTL > services
Connecting to (DESCRIPTION= (ADDRESS= (PROTOCOL=TCP) (HOST=ocm1.oracle.domain) (PORT=1521)
Services Summary...
Service "POD" has 1 instance (s).
Instance "POD", status READY, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
Service "POD1" has 1 instance (s).
Instance "POD", status UNKNOWN, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0
LOCAL SERVER
Service "PODS" has 1 instance (s).
Instance "POD", status READY, has 2 handler (s) for this service...
Handler (s):
"D001" established:0 refused:0 current:0 max:1022 state:ready
DISPATCHER
(ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=37290))
"D000" established:0 refused:0 current:0 max:1022 state:ready
DISPATCHER
(ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=37288))
Service "pod_XPT" has 1 instance (s).
Instance "POD", status READY, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
Service "repos" has 2 instance (s).
Instance "repos", status UNKNOWN, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0
LOCAL SERVER
Instance "repos", status READY, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
Service "repos_XPT" has 1 instance (s).
Instance "repos", status READY, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
The command completed successfully
Service detailed explanation
Service "POD" has 1 instance (s).
Instance "POD", status READY, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
# the service named POD, the corresponding database instance is POD, and the status READY indicates that it is dynamically registered
DEDICATED "established:0 refused:0 state:ready description is a proprietary connection, the number of connections is 0, the number of rejections is 0, and the status is dynamic.
Service "POD1" has 1 instance (s).
Instance "POD", status UNKNOWN, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0
LOCAL SERVER
# the service named POD1, the corresponding database instance is POD, and the status UNKNOWN indicates that it is statically registered
DEDICATED "established:2 refused:0 indicates that it is a proprietary connection, and the number of connections is 2 and the number of rejections is 0.
Service "PODS" has 1 instance (s).
Instance "POD", status READY, has 2 handler (s) for this service...
Handler (s):
"D001" established:0 refused:0 current:0 max:1022 state:ready
DISPATCHER
(ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=37290))
"D000" established:0 refused:0 current:0 max:1022 state:ready
DISPATCHER
(ADDRESS= (PROTOCOL=tcp) (HOST=ocm1.oracle.domain) (PORT=37288))
# the service named PODS corresponds to the database instance named POD. The status of READY indicates that it is dynamically registered.
"D001" established:0 refused:0 current:0 max:1022 state:ready
"D000" established:0 refused:0 current:0 max:1022 state:ready
This shows that it is in share mode. At present, both dispatcher are connected to 0, rejected to 0, the maximum number is 1022, and the status is dynamic registration.
Corresponding sql query
SQL > show parameter dispatchers
NAME TYPE VALUE
-
Dispatchers string
Max_dispatchers integer
SQL > alter system set dispatchers=' (protocol=tcp) (dispatchers=2)'; System altered.SQL > show parameter dispatchersNAME TYPE VALUE
-
Dispatchers string (protocol=tcp) (dispatchers=2)
Max_dispatchers integerSQL > select name,network,paddr,status from venerable cherry name NETWORK PADDR STATUS
D000 (ADDRESS= (PROTOCOL=tcp) (HOST=seagull) (PORT=37288)) 2A220390 WAIT
D001 (ADDRESS= (PROTOCOL=tcp) (HOST=seagull) (PORT=37290)) 2A220948 WAIT
Service "repos" has 2 instance (s).
Instance "repos", status UNKNOWN, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0
LOCAL SERVER
Instance "repos", status READY, has 1 handler (s) for this service...
Handler (s):
"DEDICATED" established:0 refused:0 state:ready
LOCAL SERVER
There are two instances corresponding to # repos service, but here they are all instance repos, one is static UNKNOWN and the other is dynamic READY. Currently, the number of connections is 0 and rejection is also 0.
The command completed successfully
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.
Continue with the installation of the previous hadoop.First, install zookooper1. Decompress zookoope
"Every 5-10 years, there's a rare product, a really special, very unusual product that's the most un
© 2024 shulou.com SLNews company. All rights reserved.