■ static service 등록
listener.ora 에 메뉴얼하게 서비스 등록해준다.
[oracle1@oracle ~]$ cd $ORACLE_HOME/network/admin
[oracle1@oracle admin]$ pwd
[oracle1@oracle admin]$ cat listener.ora
#) pmon 확인
[oracle1@oracle admin]$ lsnrctl status
Service "ora11g" has 1 instance(s). <- pmon이 등록
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...
The command completed successfully
#) listener.ora 백업파일로 복사
[oracle1@oracle admin]$ cp listener.ora listener.bak
[oracle1@oracle admin]$ ls
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.56.108)(PORT = 1521))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1521))
)
)
을 아래로 변경 (LISTENER, PORT 변경 및 나머지 삭제)
db_name.db_domain = service_names = GLOBAL_DBNAME
db_name = instance_name(메모리)
SID_LIST_L01 =
(SID_LIST =
(SID_DESC =
(GLOBAL_DBNAME = ora11g) : listener 이름
(ORACLE_HOME = /u01/app/oracle/product/11.2.0.4/db_1) : 절대 경로
(SID_NAME = ora11g) : instance 이름
)
)
L01 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.56.108)(PORT = 1522)))
#) vi 편집기 오픈
[oracle1@oracle admin]$ vi listener.ora
# static 하게 구성한 listener 시작
[oracle1@oracle admin]$ lsnrctl start L01 : lsnrctl start 리스너이름
# static 하게 구성한 listener 상태 확인
[oracle1@oracle admin]$ lsnrctl status L01
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 05-JAN-2024 10:17:24
Copyright (c) 1991, 2013, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.56.108)(PORT=1522)))
STATUS of the LISTENER
------------------------
Alias L01
Version TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date 05-JAN-2024 10:16:02
Uptime 0 days 0 hr. 1 min. 22 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/oracle/product/11.2.0.4/db_1/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/oracle/l01/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.56.108)(PORT=1522)))
Services Summary...
Service "ora11g" has 1 instance(s).
Instance "ora11g", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
# static 하게 구성한 listener 중지
[oracle1@oracle admin]$ lsnrctl stop L01
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 05-JAN-2024 10:17:24
Copyright (c) 1991, 2013, Oracle. All rights reserved.
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.56.108)(PORT=1522)))
STATUS of the LISTENER
------------------------
Alias L01
Version TNSLSNR for Linux: Version 11.2.0.4.0 - Production
Start Date 05-JAN-2024 10:16:02
Uptime 0 days 0 hr. 1 min. 22 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /u01/app/oracle/product/11.2.0.4/db_1/network/admin/listener.ora
Listener Log File /u01/app/oracle/diag/tnslsnr/oracle/l01/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=192.168.56.108)(PORT=1522)))
Services Summary...
Service "ora11g" has 1 instance(s).
Instance "ora11g", status UNKNOWN, has 1 handler(s) for this service...
The command completed successfully
# 기본 listener 상태 확인
[oracle1@oracle admin]$ lsnrctl status
# 기본 listener 중지
[oracle1@oracle admin]$ lsnrctl stop
LSNRCTL for Linux: Version 11.2.0.4.0 - Production on 05-JAN-2024 10:19:42
Copyright (c) 1991, 2013, Oracle. All rights reserved.
Connecting to (ADDRESS=(PROTOCOL=tcp)(HOST=)(PORT=1521))
The command completed successfully
'Data Base > Linux' 카테고리의 다른 글
240105 Architecture _ server 구성 (0) | 2024.01.05 |
---|---|
240105 Architecture_ Client - Server 환경, Database Link (0) | 2024.01.05 |
240104 Oracle DB Linux _ PORT 변경 방법 (0) | 2024.01.04 |
240104 Oracle DB Linux_Oracle Network (2) | 2024.01.04 |
240104 Oralce DB Linux _ SQL LOADER (0) | 2024.01.04 |