dba_activities
dba_activities
security:
Account Locking
tablespace quotas
default tablece
resource
Profile:
default
dba created profile
Roles:
default (connect,resource)
dba defined
Privilages:
create tablespace
alter tablespace
drop tablespace
Object:
insert
delete
update
select
SQL:
Create
alter
drop
Authentication:
OS Authentication
DB Authentication
N/w Authentication
Views:
Session_privs
User_sys_privs
Role_role_privs
Role_tab_privs
Role_sys_privs
Whenever user created : identify the tablespace which user nee the store the object
Plan for Quotas for each each tablespace
alter creating the user by following above 4 steps, grant required privilages
or roles (set of privilages) to the user.
Quotas: Tablespace quotas controls the amount of the physical storage assigned to
the user.
Password:
Failed_loggon_attempts
Password_lifetime
Password_lock_time
Password_grace_time
Password_max_reuse
Resources:
Cpue_time
Logical_reads_per_session
Logical_reads_per_call
connect_time
Idle_time
Session_per_user
sys, xusera,yuser
init.ora: resource_limit=ture
init.ora: remote_login_passwordfile=exclusive
>show users
>select * from session_privs;
> =========================================================================
Table Spaces:
views: dba_users
dba_synomyms,v$tempfile,dba_data_files,dba_tablespaces
create,alter,drop,online,offline,small,big,locally/dictionary management
read,read/write,
desc dba_data_files,
desc v$tempfile
desc database_properties
To create tablespace:
create tablespace ts1 datafile 'disk1/oradata/tsb/ts1.db' size 10m;
initdb.ora : db_2k_cache_size=16
>start force
====================
>commit;
>grant create synonym to rajpal;
conn rajpal/rajpal
>select * from session_privs;
>create materialized view mv1 refresh complete with rowid start with sysdate
nexta sysdate +1/(24*60*60)
os select * from emp@link1;
>save mv1.sql
SELECT TABLE_OWNER,TABLE_NAME,
PARTITION_NAME,SUBPARTITION_NAME,NUM_ROWS,TO_CHAR(LAST_ANALYZED,'DD-MON-
YYYY:HH24:MI:SS') LAST_ANALYZED,GLOBAL_STATS FROM DBA_TAB_SUBPARTITIONS
WHERE TABLE_OWNER='TBLUSR'
AND TABLE_NAME='MOTORFOTONG'
AND ROWNUM<11 ORDER BY
TABLE_OWNER,TABLE_NAME,PARTITION_NAME,SUBPARTITION_NAME,LAST_ANALYZED;
prompt$$$$$$$**Welcome to DBsGuru!**Share Learn Grow**$$$$$$$
==================
crontab: df -h:
https://www.cyberciti.biz/tips/shell-script-to-watch-the-disk-space.html
passwd:
https://docs.oracle.com/database/121/DBSEG/authentication.htm#DBSEG0032
Formct Help
tablespace_name,countsegment_name)frcmdba_segmentsgroupbytablespace_name;
--eachsegmentcorrespondstoatable,index,...
distinctsegment_type)fromdba_segmentswhereowner='CONCERTS';selecttablespace_name,co
untsegment_name)frcm
wheresegme1t_type='TABLE'groupbytablespace_na
shouldyieldthesamecountsoftablespertablespace
tablespace_name,counttable_name)fromall_tablesgroupbytablespace_name;
--tables,i1dexes,...containextentsastheyaresizedupwardstomeetdemand.Extentscan
--haveunusedblocks(emptyblocks,emptyspace)
selecttablespace_name,countextent_id)fromcba_extentsgroupbytablespace_name;
escuser_t3bles; I
ciescuser_i1dexes;
selecttablespace_name,countblocks)fromall_tablesgroupbytablespace_name;