SELECT * FROM V$LOG;
select GROUP#,MEMBER,TYPE from v$logfile order by 1 ;
ALTER DATABASE ADD LOGFILE GROUP 5 ('/oracle/sid/origlogA/log_g15m1.dbf','/oracle/sid/origlogA/log_g15m2.dbf') size 100M;
alter database drop logfile group 5;
--------------------veya;
ALTER DATABASE ADD LOGFILE GROUP 5 ('/oracle/sid/origlogA/log_g15m1.dbf') size 100M;
alter database add logfile member '/oracle/sid/origlogA/log_g15m2.dbf' to group 5 ;
alter database drop logfile member '/oracle/sid/origlogA/log_g15m2.dbf'
-----------------------
ALTER DATABASE CLEAR LOGFILE GROUP 5;
If the corrupt redo log file has not been archived, use the UNARCHIVED keyword in the statement.
ALTER DATABASE CLEAR UNARCHIVED LOGFILE GROUP 3;
http://www.filibeto.org/sun/lib/nonsun/oracle/11.1.0.6.0/B28359_01/server.111/b28310/onlineredo003.htm
14 Nisan 2010 Çarşamba
Oracle - iostat, vmstat , filestat ve çift kayıt silme
http://adminschoice.com/iostat-vmstat-netstat
http://vsbabu.org/oracle/sect02.html
http://www.dba-oracle.com/art_disk_iostat.htm
https://netfiles.uiuc.edu/jstrode/www/oraview/V$FILESTAT.html
http://download-uk.oracle.com/docs/cd/F49540_01/DOC/server.815/a67775/ch20_io.htm#2688
------------------------------
create table SAPSR3.zTPALOG as select * from SAPSR3.TPALOG
SAPSR3.CSMCLSMAP
WHERE ROWID IN (
SELECT t.ROWID AS targetrowid
FROM TEST t,
(SELECT tst_id, tst_name, MAX (ROWID) AS maxrowid
FROM SAPSR3.TPALOG
GROUP BY tst_id, tst_name
HAVING COUNT (*) > 1) m
WHERE t.ROWID != m.maxrowid AND t.tst_id = m.tst_id)
SELECT MAX (ROWID) AS maxrowid
FROM SAPSR3.TPALOG
SELECT TRTIME, TRKORR, TARSYSTEM,TRCLI,TRSTEP,ALLCLI,PROJECT,TRUSER,RETCODE,HOST,ADMIN,TPSTAT_KEY,LINESeQUENCE
FROM SAPSR3.TPALOG
GROUP BY TRTIME, TRKORR, TARSYSTEM,TRCLI,TRSTEP,ALLCLI,PROJECT,TRUSER,RETCODE,HOST,ADMIN,TPSTAT_KEY,LINESeQUENCE
HAVING count('x') > 1;
create table SAPSR3.TPALOG as
create table SAPSR3.TPALOG2 as select distinct * from SAPSR3.TPALOG
create table SAPSR3.TPALOG tablespace PSAPSR3 as select distinct * from SAPSR3.TPALOG2
drop table SAPSR3.TPALOG
rename SAPSR3.TPALOG2 to SAPSR3.TPALOG;
select * from sapsr3.CSMCLSMAP
http://vsbabu.org/oracle/sect02.html
http://www.dba-oracle.com/art_disk_iostat.htm
https://netfiles.uiuc.edu/jstrode/www/oraview/V$FILESTAT.html
http://download-uk.oracle.com/docs/cd/F49540_01/DOC/server.815/a67775/ch20_io.htm#2688
------------------------------
create table SAPSR3.zTPALOG as select * from SAPSR3.TPALOG
SAPSR3.CSMCLSMAP
WHERE ROWID IN (
SELECT t.ROWID AS targetrowid
FROM TEST t,
(SELECT tst_id, tst_name, MAX (ROWID) AS maxrowid
FROM SAPSR3.TPALOG
GROUP BY tst_id, tst_name
HAVING COUNT (*) > 1) m
WHERE t.ROWID != m.maxrowid AND t.tst_id = m.tst_id)
SELECT MAX (ROWID) AS maxrowid
FROM SAPSR3.TPALOG
SELECT TRTIME, TRKORR, TARSYSTEM,TRCLI,TRSTEP,ALLCLI,PROJECT,TRUSER,RETCODE,HOST,ADMIN,TPSTAT_KEY,LINESeQUENCE
FROM SAPSR3.TPALOG
GROUP BY TRTIME, TRKORR, TARSYSTEM,TRCLI,TRSTEP,ALLCLI,PROJECT,TRUSER,RETCODE,HOST,ADMIN,TPSTAT_KEY,LINESeQUENCE
HAVING count('x') > 1;
create table SAPSR3.TPALOG as
create table SAPSR3.TPALOG2 as select distinct * from SAPSR3.TPALOG
create table SAPSR3.TPALOG tablespace PSAPSR3 as select distinct * from SAPSR3.TPALOG2
drop table SAPSR3.TPALOG
rename SAPSR3.TPALOG2 to SAPSR3.TPALOG;
select * from sapsr3.CSMCLSMAP
Oracle -audit komutları
select * from SYS.AUD$
select * from DBA_AUDIT_TRAIL
DELETE FROM SYS.AUD$;
SELECT sql_text FROM dba_common_audit_trail;
-------------------------------
AUDIT ALL BY sapsr3
AUDIT SESSION BY sapsr3 by access;
AUDIT SELECT TABLE, UPDATE TABLE BY SAPSR3 BY ACCESS;
AUDIT select ANY TABLE;
AUDIT SELECT, INSERT, DELETE
ON sapsr3.vbak
BY ACCESS
WHENEVER SUCCESSFUL;
----------------------------
select * from sys.fga_log$
AUDIT SESSION
BY SAPSR3
NOAUDIT session;
NOAUDIT ALL;
SELECT * FROM DBA_PRIV_AUDIT_OPTS; -- aktif auditleri gosterir.
http://download-uk.oracle.com/docs/cd/B19306_01/network.102/b14266/cfgaudit.htm
select * from DBA_AUDIT_TRAIL
DELETE FROM SYS.AUD$;
SELECT sql_text FROM dba_common_audit_trail;
-------------------------------
AUDIT ALL BY sapsr3
AUDIT SESSION BY sapsr3 by access;
AUDIT SELECT TABLE, UPDATE TABLE BY SAPSR3 BY ACCESS;
AUDIT select ANY TABLE;
AUDIT SELECT, INSERT, DELETE
ON sapsr3.vbak
BY ACCESS
WHENEVER SUCCESSFUL;
----------------------------
select * from sys.fga_log$
AUDIT SESSION
BY SAPSR3
NOAUDIT session;
NOAUDIT ALL;
SELECT * FROM DBA_PRIV_AUDIT_OPTS; -- aktif auditleri gosterir.
http://download-uk.oracle.com/docs/cd/B19306_01/network.102/b14266/cfgaudit.htm
Oracle - session, process sayisi
http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:5671284058977
ps -auxww | grep
set autotrace on statistics;
select username from v$session where username is not
null;
(1.1*processes)+5. That means process=415 will give me sessions=461
300 - 335
ps -eaf
-------------------------------------------
the number of dirty buffers that are waiting to be written;
select dirty, count(*) from v$bh group by dirty;
update big_table.big_table set id=id where rownum < 1000;
select dirty, count(*) from v$bh group by dirty;
alter system checkpoint;
select dirty, count(*) from v$bh group by dirty;
-------------------------------------------------
alter session set sql_trace=true;
select p.spid
from v$session s, v$process p
where s.paddr = p.addr
and s.audsid = userenv('sessionid');
---------------------------------
select username,count(*)
from v$session
group by username;
select *
from v$resource_limit
where resource_name in ('processes','sessions');
ps -auxww | grep
set autotrace on statistics;
select username from v$session where username is not
null;
(1.1*processes)+5. That means process=415 will give me sessions=461
300 - 335
ps -eaf
-------------------------------------------
the number of dirty buffers that are waiting to be written;
select dirty, count(*) from v$bh group by dirty;
update big_table.big_table set id=id where rownum < 1000;
select dirty, count(*) from v$bh group by dirty;
alter system checkpoint;
select dirty, count(*) from v$bh group by dirty;
-------------------------------------------------
alter session set sql_trace=true;
select p.spid
from v$session s, v$process p
where s.paddr = p.addr
and s.audsid = userenv('sessionid');
---------------------------------
select username,count(*)
from v$session
group by username;
select *
from v$resource_limit
where resource_name in ('processes','sessions');
Kaydol:
Kayıtlar (Atom)