MERCADOS FINANCIEROS

sábado, 11 de julio de 2020

ALTER TABLESPACE READ ONLY ALTER TABLESPACE READ WRITE

SQL> alter tablespace example read only;

Tablespace altered.


SQL> alter tablespace example read write;

Tablespace altered.

SQL> alter tablespace example nologging;

RMAN> backup database skip readonly;

Starting backup at 11-JUL-20
using target database control file instead of recovery catalog
allocated channel: ORA_DISK_1
channel ORA_DISK_1: SID=59 device type=DISK
channel ORA_DISK_1: starting full datafile backup set
channel ORA_DISK_1: specifying datafile(s) in backup set
input datafile file number=00003 name=+DATA/ACME/DATAFILE/sysaux.258.1044478471
input datafile file number=00001 name=+DATA/ACME/DATAFILE/system.266.1044480131
input datafile file number=00002 name=+DATA/ACME/DATAFILE/example.257.1044478425
input datafile file number=00005 name=+DATA/ACME/DATAFILE/tbs_1.268.1043868835
input datafile file number=00004 name=+DATA/ACME/DATAFILE/undotbs1.260.848598093
input datafile file number=00006 name=+DATA/ACME/DATAFILE/users.259.848598091
channel ORA_DISK_1: starting piece 1 at 11-JUL-20

VALIDAR QUE ESTA EL TABLESPACE EN MODE READ ONLY

SQL> alter table hr.prueba move tablespace example;
alter table hr.prueba move tablespace example
               *
ERROR at line 1:
ORA-01647: tablespace 'EXAMPLE' is read-only, cannot allocate space in it


SQL> alter tablespace example read write;

Tablespace altered.

SQL> alter table hr.prueba move tablespace example;

Table altered.

SQL> 



No hay comentarios: