Oracle 初始化参数的管理

 orale中一个重要的视图v$parameter,我们知道知道多少呢?官方解释如下:

V$PARAMETER displays information about the initialization parameters that are currently in effect for the session. A new session inherits parameter values from the instance-wide values displayed by the V$SYSTEM_PARAMETER view.

ColumnDatatypeDescription
NUMNUMBERParameter number
NAMEVARCHAR2(80)Name of the parameter
TYPENUMBERParameter type:
  • 1 - Boolean

  • 2 - String

  • 3 - Integer

  • 4 - Parameter file

  • 5 - Reserved

  • 6 - Big integer

VALUEVARCHAR2(4000)Parameter value for the session (if modified within the session); otherwise, the instance-wide parameter value
DISPLAY_VALUEVARCHAR2(4000)Parameter value in a user-friendly format. For example, if the VALUE column shows the value 262144 for a big integer parameter, then the DISPLAY_VALUE column will show the value 256K.
ISDEFAULTVARCHAR2(9)Indicates whether the parameter is set to the default value (TRUE) or the parameter value was specified in the parameter file (FALSE)
ISSES_MODIFIABLEVARCHAR2(5)Indicates whether the parameter can be changed with ALTER SESSION (TRUE) or not (FALSE)
ISSYS_MODIFIABLEVARCHAR2(9)Indicates whether the parameter can be changed with ALTER SYSTEM and when the change takes effect:
  • IMMEDIATE - Parameter can be changed with ALTER SYSTEM regardless of the type of parameter file used to start the instance. The change takes effect immediately.

  • DEFERRED - Parameter can be changed with ALTER SYSTEM regardless of the type of parameter file used to start the instance. The change takes effect in subsequent sessions.

  • FALSE - Parameter cannot be changed with ALTER SYSTEM unless a server parameter file was used to start the instance. The change takes effect in subsequent instances.

ISINSTANCE_MODIFIABLEVARCHAR2(5)For parameters that can be changed with ALTER SYSTEm, indicates whether the value of the parameter can be different for every instance (TRUE) or whether the parameter must have the same value for all Real Application Clusters instances (FALSE). If the ISSYS_MODIFIABLE column is FALSE, then this column is always FALSE.
ISMODIFIEDVARCHAR2(10)Indicates whether the parameter has been modified after instance startup:
  • MODIFIED - Parameter has been modified with ALTER SESSION

  • SYSTEM_MOD - Parameter has been modified with ALTER SYSTEM (which causes all the currently logged in sessions' values to be modified)

  • FALSE - Parameter has not been modified after instance startup

ISADJUSTEDVARCHAR2(5)Indicates whether Oracle adjusted the input value to a more suitable value (for example, the parameter value should be prime, but the user input a non-prime number, so Oracle adjusted the value to the next prime number)
ISDEPRECATEDVARCHAR2(5)Indicates whether the parameter has been deprecated (TRUE) or not (FALSE)
ISBASICVARCHAR2(5)Indicates whether the parameter is a basic parameter (TRUE) or not (FALSE)
DESCRIPTIONVARCHAR2(255)Description of the parameter
UPDATE_COMMENTVARCHAR2(255)Comments associated with the most recent update
HASHNUMBERHash value for the parameter name

 

 

Oracle 初始化参数的管理
查看修改的参数
select name
,      value
from   v$parameter
where  ismodified != 'FALSE'
/


查看过期不推荐使用的参数
select name
,      value
from   v$parameter
where  isdeprecated = 'TRUE'
/


查看非默认的参数
set pages 999 lines 100
col name format a30
col value format a50
select 	name
,	value
from	v$parameter
where	isdefault = 'FALSE'
and	value is not null
order	by name
/

以name=value形式显示参数信息
set pages 999 lines 100
select 	name || '=' || decode(type, 2, '''') || value 
	|| decode(type, 2, '''') parameter
from	v$parameter
where	isdefault = 'FALSE'
and	value is not null
order	by name
/

重置初始化参数(当使用不推荐过期参数,oracle报错的时候,可以使用这个语句重置)
alter system reset <parameter> scope=spfile sid='*'
/


 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值