OracleÓû§¡¢½ÇÉ«¡¢È¨ÏÞºÍϵͳ×ÊÔ´¹ÜÀí³£ÓòÙ×÷
²éѯÓû§ÐÅÏ¢
SELECT USERNAME,DEFAULT_TABLESPACE, TEMPORARY_TABLESPACE, PROFILE, ACCOUNT_STATUS, CREATED from dba_users; ²éѯÓû§¿Õ¼äʹÓúÍÉÏÏÞÇé¿ö
SELECT username, tablespace_name, bytes/1024/1024 space_used_in_mb, max_bytes/1024/1024 max_space_in_mb from dba_ts_quotas; ´´½¨Óû§
CREATE USER Óû§Ãû IDENTIFIED BY ¿ÚÁî DEFAULT TABLESPACE ±í¿Õ¼äÃû TEMPORARY TABLESPACE ±í¿Õ¼äÃû QUOTA {ÕýÕûÊý[K|M] | UNLIMITED} ON ±í¿Õ¼äÃû PASSWORD EXPIRE PROFILE ¸ÅÒªÎļþÃû ¸Ä±äÓû§±í¿Õ¼äÅä¶î
ALTER USER Óû§Ãû QUOTA 38M ON ±í¿Õ¼äÃû; ɾ³ýÓû§. É÷ÓÃ,Óû§Ïà¹Ø¶ÔÏóÒ²½«Ïûʧ.
DROP USER Óû§Ãû [CASCADE]; Ëø¶¨ºÍ½âËøÓû§
ALTER USER ̞ ACCOUNT UNLOCK|LOCK;
ÆôÓÃ×ÊÔ´ÏÞÖÆ.·ñÔò¸ÅÒªÎļþÖеĶ¨Òå²»Æð×÷ÓÃ.
a.)Ð޸IJÎÊýÎļþ, RESOURCE_LIMIT = TRUE
b.)ʹÓÃÃüÁî, ALTER SYSTEM SET RESOURCE_LIMIT = TRUE; ²éѯ¸ÅÒªÎļþÇé¿ö. RESOURCE_TYPEΪKERNELʱ¼´ÊÇ×ÊÔ´ÏÞÖÆ.PASSWORDΪ¿ÚÁȫÏÞÖÆ.
SELECT * from dba_profiles; ´´½¨×ÊÔ´ÏÞÖƵĸÅÒªÎļþ. ×î´óÖµ¿ÉΪÕýÕûÊý,UNLIMITED»òDEFAULT.
CREATE PROFILE ¸ÅÒªÎļþÃû LIMIT
[SESSIONS_PER_USER ×î´óÖµ]
[CPU_PER_SESSION ×î´óÖµ] --×ܹ²µÄCPUʹÓÃʱ¼ä.µ¥Î»ÊÇ°Ù·ÖÖ®Ò»Ãë
[CONNECT_TIME ×î´óÖµ] --Á¬½Óʱ¼ä,µ¥Î»ÊÇ·ÖÖÓ
[IDLE_TIME ×î´óÖµ] --·þÎñÆ÷¶Ë½ø³ÌµÄÏÞÖÆʱ¼ä,µ¥Î»ÊÇ·ÖÖÓ
[LOGICAL_READS_PER_SESSION ×î´óÖµ] --´ÅÅ̺ÍÄÚ´æ×î´ó¶ÁÈ¡Êý¾Ý¿éÊý
[CPU_PER_CALL ×î´óÖµ]
[LOGICAL_READS_PER_CALL ×î´óÖµ] ´´½¨¿ÚÁîÏÞÖƵĸÅÒªÎļþ.¿ÉÒÔÓë×ÊÔ´ÏÞÖÆΪͬһ¸ÅÒªÎļþ.ÆäÖÐPASSWORD_REUSE_MAXºÍPASSWORD_REUSE_TIME
Ïà¹ØÎĵµ£º
¹éµµÈÕÖ¾Îļþ£ºÊÇ´¦Óڷǻ£¨INACTIVE£©µÄ״̬µÄÖØ×öÈÕÖ¾ÎļþµÄ±¸·Ý¡£Ëü¶ÔORACLEÊý¾Ý¿âµÄ±¸·ÝºÍ»Ö¸´ÆðÖÁ¹ØÖØÒªµÄ×÷Óá£ÊÇÁª»úÖØ×öÈÕÖ¾ÎļþµÄÒ»¸ö¸±±¾£¬Óë±»¸´ÖƵijÉÔ±Íê³ÉÒ»Ñù£¬¼´ÖØ×ö¼Ç¼Ïàͬ£¬ÈÕÖ¾ÐòÁкÅÏàͬ¡£
Ò»¡¢Êý¾Ý¿âµÄ¹éµµÓë·Ç¹éµµÄ£Ê½£º
1£® µ±Êý¾Ý¿â´¦ÓÚNOACRCHIVELOGģʽʱ£¬²»¶ÔÖØ×öÈÕÖ¾Îļþ½ ......
Ò»¡¢×¼±¸¹¤×÷
1.1 ÉèÖÃÖ÷¿âµÄforce loggingģʽ
SQL> alter database force logging;
Database altered.
1.2 ´´½¨Ö÷¿âÃÜÂëÎļþ
$ orapwd file=orapw$ORACLE_SID password=thunis entries=4
1.3 ÅäÖÃÖ÷¿âstandby redo log£¬²¢ÑéÖ¤½á¹û
SQL> alter database add standby logfile group 4('/u01/app/oradata/guar ......
Ò»¡¢ÔÚUnixÏ´´½¨Êý¾Ý¿â
1.È·¶¨Êý¾Ý¿âÃû¡¢Êý¾Ý¿âʵÀýÃûºÍ·þÎñÃû
¹ØÓÚÊý¾Ý¿âÃû¡¢Êý¾Ý¿âʵÀýÃûºÍ·þÎñÃû£¬ÎÒ֮ǰÓÐרÃÅÓÃһƪÀ´Ïêϸ½éÉÜ¡£ÕâÀï¾Í²»ÔÙ˵Ã÷ÁË¡£
2.´´½¨²ÎÊýÎļþ
²ÎÊýÎļþºÜÈ·¶¨ÁËÊý¾Ý¿âµÄ×ÜÌå½á¹¹¡£Oracle10gÓÐÁ½ÖÖ²ÎÊýÎļþ£¬Ò»¸öÊÇÎı¾²ÎÊýÎļþ£¬Ò»ÖÖÊÇ·þÎñÆ÷²ÎÊýÎļþ¡£ÔÚ´´½¨Ê ......
1.ʲôÊÇRMAN£¿
¡¡¡¡RMAN¿ÉÒÔÓÃÀ´±¸·ÝºÍ»¹ÔÊý¾Ý¿âÎļþ¡¢¹éµµÈÕÖ¾ºÍ¿ØÖÆÎļþ¡£ËüÒ²¿ÉÒÔÓÃÀ´Ö´ÐÐÍêÈ«»ò²»ÍêÈ«µÄÊý¾Ý¿â»Ö¸´¡£
¡¡¡¡×¢Ò⣺RMAN²»ÄÜÓÃÓÚ±¸·Ý³õʼ»¯²ÎÊýÎļþºÍ¿ÚÁîÎļþ¡£
¡¡¡¡RMANÆô¶¯Êý¾Ý¿âÉϵÄOracle·þÎñÆ÷½ø³ÌÀ´½øÐб¸·Ý»ò»¹Ô¡£±¸·Ý¡¢»¹Ô¡¢»Ö¸´ÊÇÓÉÕâЩ½ø³ÌÇý¶¯µÄ¡£
¡¡¡¡RMAN¿ÉÒÔÓÉOEMµÄBackup Manager ......