728x90
요구사항
- OS계정 : oracle
- BASE : /oracle2/app/oracle HOME : /oracle2/app/oracle/product/192
- SID : testVM2
- 아카이브폴더 : /ARCH2
- 데이터파일 폴더 : /ORADATA/TESTVM2
※ 기존에 설치된 인스턴스가 있어 기본 환경이 세팅되었다는 전제 하에 진행
- 방화벽 중지
(ORCL)/oracle/app/oracle/product/192/network/admin> systemctl stop firewalld
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ===
Authentication is required to manage system services or units.
Authenticating as: root
Password:
==== AUTHENTICATION COMPLETE ===
- 경로 생성
[root@vc7-19 ~]# mkdir /oracle2
[root@vc7-19 ~]# chown -R oracle:dba /oracle2
[root@vc7-19 ~]# chmod -R 755 /oracle2
[root@vc7-19 ~]# su - oracle
(ORCL)/oracle/app/oracle/product/192> mkdir -p /oracle2/app/oracle/product/192
(ORCL)/oracle/app/oracle/product/192>
※ 설치 과정 중 GUI가 필요하기 때문에 GUI가 지원되는 프로그램을 사용해야 한다.
여기서는 PuTTY를 사용한다.
- GUI 설정
- Xming 실행
> xhost +
> xclock
커맨드가 정상 작동하는지 확인한다.
※ GUI를 실행하려면 PuTTY 로그인 시 바로 oracle 계정으로 접속해야 한다.
(root 계정으로 접속 후 su - oracle 하면 GUI가 실행되지 않았다)
- Oracle 설치
GUI 설정이 완료 되었다면 다음 단계를 진행한다.
오라클 설치 파일을 새 경로에 압축 해제한다.
(ORCL)/oracle/app/oracle/product/192> unzip LINUX.X64_193000_db_home.zip -d /oracle2/app/oracle/product/192
설정 파일 편집
(ORCL)/oracle/app/oracle/product/192> cd /oracle2/app/oracle/product/192
(ORCL)/oracle2/app/oracle/product/192> vi .profile
...
설정 적용 후 설치 시작
(ORCL)/oracle2/app/oracle/product/192> . ./.profile
(testVM2)/oracle2/app/oracle/product/192> ./runInstaller
새 경로에 오라클 설치
- 리스너 설정 변경
# vi tnsnames.ora
LISTENER_TESTVM2 =
(ADDRESS = (PROTOCOL = TCP)(HOST = vc7-19.localdomain)(PORT = 1522))
TESTVM2 =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = vc7-19.localdomain)(PORT = 1522))
(CONNECT_DATA =
(SERVER = DEDICATED)
(SERVICE_NAME = testVM2)
)
)
# vi listener.ora
LISTENER =
(DESCRIPTION_LIST =
(DESCRIPTION =
(ADDRESS = (PROTOCOL = TCP)(HOST = vc7-19.localdomain)(PORT = 1522))
(ADDRESS = (PROTOCOL = IPC)(KEY = EXTPROC1522))
)
)
# vi sqlnet.ora
NAMES.DIRECTORY_PATH= (TNSNAMES, EZCONNECT)
SQLNET.ALLOWED_LOGON_VERSION_SERVER=11
SQLNET.ALLOWED_LOGON_VERSION_CLIENT=11 # 외부 서버에서 연결하기 위함 (WINDOWS)
- 리스너 시작
(testVM2)/oracle2/app/oracle/product/192/network/admin> lsnrctl start
LSNRCTL for Linux: Version 19.0.0.0.0 - Production on 20-AUG-2021 03:06:07
Copyright (c) 1991, 2019, Oracle. All rights reserved.
Starting /oracle2/app/oracle/product/192/bin/tnslsnr: please wait...
TNSLSNR for Linux: Version 19.0.0.0.0 - Production
System parameter file is /oracle2/app/oracle/product/192/network/admin/listener.ora
Log messages written to /oracle2/app/oracle/diag/tnslsnr/vc7-19/listener/alert/log.xml
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=vc7-19.localdomain)(PORT=1522)))
Listening on: (DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1522)))
Connecting to (DESCRIPTION=(ADDRESS=(PROTOCOL=TCP)(HOST=vc7-19.localdomain)(PORT=1522)))
STATUS of the LISTENER
------------------------
Alias LISTENER
Version TNSLSNR for Linux: Version 19.0.0.0.0 - Production
Start Date 20-AUG-2021 03:06:07
Uptime 0 days 0 hr. 0 min. 0 sec
Trace Level off
Security ON: Local OS Authentication
SNMP OFF
Listener Parameter File /oracle2/app/oracle/product/192/network/admin/listener.ora
Listener Log File /oracle2/app/oracle/diag/tnslsnr/vc7-19/listener/alert/log.xml
Listening Endpoints Summary...
(DESCRIPTION=(ADDRESS=(PROTOCOL=tcp)(HOST=vc7-19.localdomain)(PORT=1522)))
(DESCRIPTION=(ADDRESS=(PROTOCOL=ipc)(KEY=EXTPROC1522)))
The listener supports no services
The command completed successfully
- database 확인
(testVM2)/oracle2/app/oracle/product/192/network/admin> sqlplus /nolog
SQL*Plus: Release 19.0.0.0.0 - Production on Fri Aug 20 03:08:51 2021
Version 19.3.0.0.0
Copyright (c) 1982, 2019, Oracle. All rights reserved.
SQL> conn /as sysdba
Connected.
SQL> select name
2 from v$database;
NAME
------------------
TESTVM2
- 변경 후 database 재확인
(testVM2)/oracle2/app/oracle/product/192/network/admin> cd /oracle/app/oracle/product/192
(testVM2)/oracle/app/oracle/product/192> . ./.profile
(ORCL)/oracle/app/oracle/product/192> sqlplus /nolog
SQL*Plus: Release 19.0.0.0.0 - Production on Fri Aug 20 03:14:31 2021
Version 19.11.0.0.0
Copyright (c) 1982, 2020, Oracle. All rights reserved.
SQL> conn /as sysdba
Connected.
SQL> select name
2 from v$database;
NAME
---------
ORCL
728x90
'Dev > Oracle' 카테고리의 다른 글
[Oracle] 실행 계획 - EXPLAIN PLAN, SET AUTOTRACE (0) | 2022.07.20 |
---|---|
[Oracle] Oracle Database 생성 (0) | 2022.07.14 |
[Oracle] VirtualBox Oracle 서버 연결 (0) | 2022.07.12 |
[Oracle] Rollback Transaction 모니터링 (0) | 2022.07.07 |
[Oracle] Lock 확인 (0) | 2022.07.06 |
댓글