- select sum(bytes)/1024/1024 from dba_data_files; 로 확인
- df -h 로 백업받을 공간 확인
- 불필요한 백업 삭제
- n4: level 0 백업 받기
- SID 맞춰주기
- n5: export ORACLE_SID로 맞춰주기
- backup spfile
- rman> set dbid=n4의dbid
- rman> restore spfile
- startup force (open된 상태에서 abort하고 재startup)
- create pfile 생성 후 spfile은 백업으로 파일명 바꾸기
- restore spfile from 'directory'
- startup mount pfile='directory';
- (restore datafile << ASM에서~~~)
#!/bin/bash
$ORACLE_HOME/bin/rman target / nocatalog << EOF
run {
allocate channel c1 device type disk;
allocate channel c2 device type disk;
allocate channel c3 device type disk;
allocate channel c4 device type disk;
# level 0
backup
incremental level 0
database
not backed up 1 times
format '/BSJ/BACKUP/dbf.%t_%s_%d_%U'
section size 10g
filesperset 2;
# archivelog
sql 'alter system archive log current';
backup (archivelog all format '/BSJ/BACKUP/arc.%t_%s_%d' DELETE ALL INPUT);
# controlfile
backup format '/BSJ/BACKUP/ctl.%t_%s_%d_%U'(current controlfile);
release channel c1;
release channel c2;
release channel c3;
release channel c4;
}
exit
EOF
find /u01/app/oracle/product/19c/dbhome_1/dbs -type f -daystart -mtime 0 -exec rm -f {} \;
find /u01/app/oracle/product/19c/dbhome_1/dbs -type f -daystart -mtime 0 -exec rm -f {} \;
SID ps -ef 로 확인했을 때 잘못된 거 못찾고 변경 못하고 있던 것
OS 메모리와 sga_target 메모리 사이즈 변경
cat /proc/meminfo
free -h
[BasicStep.handleNonIgnorableError:470] ORA-27104: system-defined limits for
shared memory was misconfigured