Oracle View user Action SQL statements and database logs

Source: Internet
Author: User

--View Log files

Select member from V$logfile;

--View Table space usage

SELECT SUM (bytes)/(1024x768 * 1024x768) as free_space, Tablespace_name
From Dba_free_space 
GROUP bytablespace_name; Selecta.tablespace_name, 
a.bytes total, 
b.bytes used, 
C.bytes Free, 
(b.bytes *)/a.bytes "% used", (c.bytes *)/a.bytes "% free"  
Fromsys.sm$ts_avail A, sys.sm$ts_used B, Sys.sm$ts_free c 
Wherea.tablespace_name = B.tablespace_name 
Anda.tablespace_name = C.tablespace_name; 
!--[If!supportlinebreaknewline]-->--view the rollback segment name and size!--[endif ]-->

select segment_name, 
Tablespace_name, 
R.status, 
(initial_extent/1024) initialextent, 
(next_extent/1024) nextextent, 
Max_extents, 
V.curext curextent 
FROMdba_ Rollback_segs R, V$rollstat v 
WHERE r.segment_id= V.usn (+)  
ORDER bysegment_name;

Oracle View User Action SQL statements and database logs

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.