关于maxfilop参数和get snapshot for db输出中‘Database files closed'的关系
字数 1516阅读 1815评论 0赞 0
问题: 根据一个资料上提供的信息,说使用db2 "get snapshot for database on DBNAME"可以查看到当前数据库的database files closed值,依次来查看数据库所能打开的最大文件数,但我执行此语句后,发现根本没找到database files closed这一项,我数据库为DB2 9.7 ,谁能帮我解释下,多谢了。 回答: Try to use 'grep -i' to ignore character case.
Here is a sample.
db2 get snapshot for database on edwdvdb4|grep -i file
File system ID = 9223372079804448772
File system used space (bytes) = 567136579584
File system total space (bytes) = 1803483611136
Database files closed = 0
File number of first active log = 2243
File number of last active log = 2292
File number of current active log = 2244
File number of log being archived = Not applicable 据我所知,db2中没有显示当前打开文件数的地方。但是通过db cfg
中的maxfilop参数可以控制数据库可打开的最多文件数。当数据库要打开多于maxfilop个数的文件时,它必须先关闭已开文件。而关闭的文件的个
数可以从‘db2 get snapshot for database on db_name' 中的’Database files closed
= x'来查到。 如果database files
closed的个数过大,表明maxfilop设置的过小,可以根据file close数来增大maxfilop
添加新评论0 条评论