初始化参数文件的默认位置
UNIX and Linux:
默认命名规范:initORACLE_SID .ora
默认位置:ORACLE_HOME/ dbs
Windows :
默认命名规范:initORACLE_SID .ora
默认位置:ORACLE_HOME\ database
参数设置格式:
■ For parameters that accept only a single value:
parameter_name=value
■ For parameters that accept one or more values (such as the CONTROL_FILES parameter):
parameter_name=(value [,value ] ...)
eg:
control_files='/u01/app/oracle/oradata/orcl/control01.ctl'
control_files='/u01/app/oracle/oradata/orcl/control02.ctl'
control_files='/u01/app/oracle/oradata/orcl/control03.ctl'
control_files=(/u01/app/oracle/oradata/orcl/control01.ctl,/u01/app/oracle/oradata/orcl/control01.ctl,/u01/app/oracle/oradata/orcl/control01.ctl)
初始化参数文件的样例:
$ORACLE_HOME/dbs/initORCL.ora
The following is the content of the sample file:
##############################################################################
# Example INIT.ORA file
#
# This file is provided by Oracle Corporation to help you start by providing
# a starting point to customize your RDBMS installation for your site.
#
# NOTE: The values that are used in this file are only intended to be used
# as a starting point. You may want to adjust/tune those values to your
# specific hardware and needs. You may also consider using Database
# Configuration Assistant tool (DBCA) to create INIT file and to size your
# initial set of tablespaces based on the user input.
###############################################################################
# Change '<ORACLE_BASE>' to point to the oracle base (the one you specify at
# install time)
db_name='ORCL'
memory_target=1G
processes = 150
audit_file_dest='<ORACLE_BASE>/admin/orcl/adump'
audit_trail ='db'
db_block_size=8192
db_domain=''
db_recovery_file_dest='<ORACLE_BASE>/flash_recovery_area'
db_recovery_file_dest_size=2G
diagnostic_dest='<ORACLE_BASE>'
dispatchers='(PROTOCOL=TCP) (SERVICE=ORCLXDB)'
open_cursors=300
remote_login_passwordfile='EXCLUSIVE'
undo_tablespace='UNDOTBS1'
# You may want to ensure that control files are created on separate physical
# devices
control_files = (ora_control1, ora_control2)
compatible ='11.2.0'
更改global_name
global_name=db_name+db_domain
db_name不能多于8个字符
ALTER DATABASE RENAME GLOBAL_NAME to
LOG_ARCHIVE_DEST 与 LOG_ARCHIVE_DUPLEX_DEST 与FRA设置相冲突( LOG_ARCHIVE_DEST_1 隐式指向FRA)
即设置了以上两个参数,就不能设置db_recovery_file_dest 与 db_recovery_file_dest_size这两个参数
在RAC环境下各个节点这两个参数必须一样。
如何查看那个进程使用内存资源最多:
# top -c
然后 shift m
eg:top - 22:14:32 up 1 day, 8:34, 3 users, load average: 0.01, 0.14, 0.22
Tasks: 145 total, 1 running, 144 sleeping, 0 stopped, 0 zombie
Cpu(s): 0.0%us, 0.7%sy, 0.0%ni, 99.3%id, 0.0%wa, 0.0%hi, 0.0%si, 0.0%st
Mem: 438828k total, 362560k used, 76268k free, 2400k buffers
Swap: 917496k total, 120484k used, 797012k free, 248848k cached
PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND
16815 oracle 20 0 378m 68m 67m S 0.0 16.0 0:01.43 ora_smon_mynewdb
16853 oracle 20 0 376m 36m 32m S 0.0 8.4 0:03.95 ora_cjq0_mynewdb
16809 oracle 20 0 378m 35m 35m S 0.0 8.3 0:01.43 ora_dbw0_mynewdb
16819 oracle 20 0 379m 34m 31m S 0.0 8.0 0:02.49 ora_mmon_mynewdb
2807 root 10 -10 26608 25m 1720 S 0.0 6.1 0:00.24 iscsiuio
16839 oracle 20 0 405m 21m 5656 S 0.0 5.0 0:02.05 ora_arc3_mynewdb
16908 oracle 20 0 376m 15m 12m S 0.0 3.5 0:00.29 oraclemynewdb (DESCRIPTION=(LOCAL=YES)(ADDRESS=(PROTOCOL=beq)))
17305 oracle 20 0 374m 14m 12m S 0.0 3.3 0:00.02 ora_w000_mynewdb
16855 oracle 20 0 374m 13m 13m S 0.0 3.2 0:00.25 ora_q000_mynewdb
16801 oracle 20 0 374m 11m 11m S 0.3 2.8 0:00.44 ora_dbrm_mynewdb
16821 oracle 20 0 374m 10m 10m S 0.0 2.6 0:07.01 ora_mmnl_mynewdb
16817 oracle 20 0 374m 9.8m 9708 S 0.0 2.3 0:00.18 ora_reco_mynewdb
16805 oracle 20 0 374m 7996 7176 S 0.0 1.8 0:04.73 ora_dia0_mynewdb
16811 oracle 20 0 389m 7988 7556 S 0.0 1.8 0:02.75 ora_lgwr_mynewdb
16813 oracle 20 0 374m 7952 7584 S 0.0 1.8 0:02.99 ora_ckpt_mynewdb
16791 oracle 20 0 374m 7280 6968 S 0.0 1.7 0:02.00 ora_pmon_mynewdb
16807 oracle 20 0 374m 7068 6908 S 0.0 1.6 0:00.32 ora_mman_mynewdb
16857 oracle 20 0 374m 6480 6424 S 0.0 1.5 0:00.16 ora_q001_mynewdb
16841 oracle 20 0 374m 6040 5888 S 0.0 1.4 0:00.18 ora_qmnc_mynewdb
17219 oracle 20 0 374m 5828 4544 S 0.3 1.3 0:01.97 ora_vkrm_mynewdb
16837 oracle 20 0 389m 5384 5032 S 0.0 1.2 0:00.31 ora_arc2_mynewdb
16835 oracle 20 0 405m 5324 5024 S 0.0 1.2 0:01.75 ora_arc1_mynewdb
16833 oracle 20 0 389m 5308 4916 S 0.0 1.2 0:00.20 ora_arc0_mynewdb
16869 oracle 20 0 374m 5276 5104 S 0.0 1.2 0:00.46 ora_smco_mynewdb
16803 oracle 20 0 374m 4716 4540 S 0.0 1.1 0:00.40 ora_psp0_mynewdb
16797 oracle 20 0 374m 4616 4456 S 0.0 1.1 0:00.28 ora_gen0_mynewdb
16793 oracle 20 0 374m 4392 4292 S 0.0 1.0 0:02.67 ora_vktm_mynewdb
16799 oracle 20 0 374m 4368 4292 S 0.0 1.0 0:00.55 ora_diag_mynewdb
16825 oracle 20 0 374m 3972 3752 S 0.0 0.9 0:00.17 ora_s000_mynewdb
16823 oracle 20 0 375m 3920 3704 S 0.0 0.9 0:00.18 ora_d000_mynewdb
2812 root 10 -10 2824 2816 1892 S 0.0 0.6 0:14.82 iscsid
3831 root 39 19 25952 2344 1016 S 0.0 0.5 0:00.70 /usr/bin/python -tt /usr/sbin/yum-updatesd
16907 oracle 20 0 37404 2256 852 S 0.0 0.5 0:00.18 sqlplus as sysdba
2667 root 20 0 27880 1740 1464 S 0.3 0.4 2:21.17 /usr/sbin/vmtoolsd
3341 haldaemo 20 0 7200 1416 940 S 0.0 0.3 0:18.56 hald
16728 root 20 0 10216 1368 1076 S 0.3 0.3 0:01.58 sshd: root@pts/3,pts/1
17077 root 20 0 4768 1308 992 S 0.0 0.3 0:00.22 -bash
3825 root 20 0 43444 1120 904 S 0.0 0.3 1:00.96 /usr/bin/Xorg :0 -br -audit 0 -auth /var/gdm/:0.Xauth -nolisten tcp vt7
[root@oracle11g trace]#
[root@oracle11g trace]#