Oracle Solaris Server VMSTAT

本文探讨了Oracle Solaris环境下使用VMSTAT工具进行内存管理的方法。深入解析了虚拟内存的工作原理,包括页面置换算法及如何避免频繁的页交换操作以提高Oracle数据库性能。

Oracle Solaris Server VMSTAT

Memory management in UNIX

Most operating systems today possess what is commonly called virtual memory.  In a virtual memory configuration it is possible to extend the existing RAM memory with the use of special swap disk areas.  Memory management in UNIX is critical to the performance of any Oracle database.  As we may know from out Oracle DBA 101 training, the RAM regions of Oracle are designed to improve the speed of data access by several orders of magnitude. 

In other words, RAM is more than 10,000 times faster to access that going to a disk device for the data.  Hence, we are very concerned that our RAM memory always stays within the actual RAM cache, and is not swapped out to the swap dis. Let’s take a close look at how this works.

Virtual memory in UNIX

Virtual memory is an internal “trick” that relies on the fact that not every executing task is always referencing it’s RAM memory region.  Since all RAM regions are not constantly in-use, UNIX has developed a paging algorithm that move RAM memory pages to the swap disk when it appears that they will not be needed in the immediate future (Figure 2-5)

Figure 5: RAM demand paging in UNIX

As memory regions are created, UNIX will not refuse a new task whose RAM requests exceeds the amount of RAM. Rather, UNIX will page out the least recently referenced RAM memory page to the swap disk to make room for the incoming request. When the physical limit of the RAM is exceeded UNIX can wipe-out RAM regions because they have already been written to the swap disk. 

When the RAM region is been removed to swap, any subsequent references by the originating program require UNIX copy page in the RAM region to make the memory accessible.  UNIX page in operations involve disk I/O and are a source of slow performance. Hence, avoiding UNIX page in operations is an important concern for the Oracle DBA.

The page out operation

UNIX will commonly page out RAM pages in anticipation of additional demands on the RAM memory region.  This asynchronous writing of RAM pages is generally done for all memory regions that are marked as swappable.  For details on making the Oracle SGA non-swappable, please see the special init.ora parameters described later in this chapter.

In sum, a page-out does not cause the RAM memory region to be physically moved out of the RAM, and it is only a preparatory phase.  In case UNIX decides to flush the region from RAM, he will have already copied the RAM contents to the swap disk.

Now let’s look at what happens when a RAM memory page is purged from physical RAM.

The page-in operation

As we noted a page out is no cause for concern because UNIX has not yet decided to actually remove the region from RAM.  However, then UNIX performs a page in, disk I/O is involved, and the requesting tasks will have to wait a long time (milliseconds) while UNIX fetches the region from the swap disk and re-loads it into the RAM region.

Hence, RAM page in operations can be disastrous to the performance of Oracle tasks, and the Oracle DBA must constantly be on the lookout for page in’s and take appropriate action to remedy the problem.

A following section in this chapter on the vmstat utility will show you how to detect page in operations, and we can remedy page in operations in several ways:

1 – Add additional RAM to the UNIX server.

2 – Reduce the SGA size for our database by lowering the size of the data block buffers.

3 – Mark the critical RAM regions (such as the Oracle SGA) as non-swappable

Now that we understand the basics of RAM management in Oracle, let’s take a close look at UNIX commands to manage processes in UNIX.


 

#

vmstat

2

5

kthr

memory

page

disk

r

b

w

swap

free

re

mf

pi

po

fr

de

sr

m0

m1

m3

m4

in

faults

cpu

2

2

30

12759232

1902464

2203

0:00

20455

129

205

117560

1576

1

11

1

2

2528

sy

cs

us

sy

id

23

25

223

4884328

75992

1665

0:00

17973

4010

9051

85712

212978

11

604

0

9

3136

27

23

223

4883448

70648

2214

0:00

22224

5143

6510

69432

176826

19

570

4

8

3163

7014

4062

48

18

34

18

29

222

4878968

59776

1757

0:00

28272

3672

15563

56336

206942

13

622

6

5

3458

4214

3625

40

60

0

11

24

221

4881464

71944

2363

0:00

30116

3383

10990

115448

213999

12

587

0

10

3745

5148

4037

40

60

0

kthr

memory

page

disk

3970

41

59

0

r

b

w

swap

free

re

mf

pi

po

fr

de

sr

m0

m1

m3

m4

in

4845

44

55

1

2

2

30

12751752

1900488

2206

0:00

20486

133

213

84168

1643

1

11

1

2

2530

faults

12

2

127

7822184

131800

821

0:00

9608

893

1275

115448

375

0

11

0

0

3355

sy

14

4

127

7804656

131480

424

0:00

7591

3954

8754

93520

7083

0

96

0

0

2888

7022

11

7

127

7802064

132408

762

0:00

11248

2947

4190

115448

2423

0

44

0

0

3667

9791

12

5

127

7795632

130320

813

0:00

11777

2742

3338

93520

10067

2

32

0

0

3507

8016

cpu

17

5

127

7797128

135440

770

0:00

11624

436

436

75752

0

7

56

0

0

2978

7323

cs

us

sy

id

12

6

127

7796952

134544

1013

0:00

14234

614

614

61368

0

0

0

0

0

3390

7290

4064

48

18

34

8

6

127

7797448

146864

2270

0:00

26125

16

16

128272

0

0

0

0

0

2937

6163

5776

74

26

0

11

4

127

7780816

137976

997

0:00

13167

16

16

103904

0

0

0

0

2

3312

6677

5134

65

35

0

8

10

127

7770608

131104

278

0:00

4002

2925

6580

115448

43077

0

24

0

0

3760

6032

5095

67

33

0

 Page-ins are common, normal and are not a cause for concern. For example, when an application first starts up, its executable image and data are paged-in. This is normal behavior.

Page-outs, however, can be a sign of trouble. When the kernel detects that memory is running low, it attempts to free up memory by paging out. Though this may happen briefly from time to time, if page-outs are plentiful and constant, the kernel can reach a point where it's actually spending more time managing paging activity than running the applications, and system performance suffers. This woeful state is referred to as thrashing.

Using swap space is not inherently bad. Rather, it's intense paging activity that's problematic. For instance, if your most-memory-intensive application is idle, it's fine for portions of it to be set aside when another large job is active. Memory pages belonging to an idle application are better set aside so the kernel can use physical memory for disk buffering.

 

 

  • Reference:

http://www.princeton.edu/~unix/Solaris/troubleshoot/vmstat.html

http://www.bga.org/~lessem/psyc5112/usail/man/solaris/vmstat.1.html

http://www.dba-oracle.com/unix_linux/memory_management.htm

 

 

 

来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/26136400/viewspace-716999/,如需转载,请注明出处,否则将追究法律责任。

转载于:http://blog.itpub.net/26136400/viewspace-716999/

下载方式:https://pan.quark.cn/s/a4b39357ea24 在纺织制造领域中,纱线的品质水平对最终制成品的整体质量具有决定性作用。 鉴于消费者对于产品规格和样式要求的不断变化,纺织制造工艺的执行过程日益呈现为一种更为复杂的操作体系,进而导致对纱线质量进行预测的任务变得更加困难。 在众多预测技术中,传统的预测手段在面对多变量间相互交织的复杂关系时,往往显得力不从心。 因此,智能计算技术在预测纱线质量的应用场景中逐渐占据核心地位,其中人工神经网络凭借其卓越的非线性映射特性以及自适应学习机制,成为了众多预测方法中的一种重要选择。 在智能计算技术的范畴内,粒子群优化算法(PSO)和反向传播神经网络(BP神经网络)是两种被广泛采用的技术方案。 粒子群优化算法是一种基于群体智能理念的优化技术,它通过模拟鸟类的群体觅食行为来寻求最优解,该算法因其操作简便、执行高效以及具备优秀的全局搜索性能,在函数优化、神经网络训练等多个领域得到了普遍应用。 反向传播神经网络则是一种由多层节点构成的前馈神经网络,它通过误差反向传播的机制来实现网络权重和阈值的动态调整,从而达成学习与预测的目标。 在实际操作层面,反向传播神经网络因其架构设计简洁、实现过程便捷,因此被广泛部署于各类预测和分类任务之中。 然而,该方法也存在一些固有的局限性,例如容易陷入局部最优状态、网络收敛过程缓慢等问题。 而粒子群优化算法在参与神经网络优化时,能够显著增强神经网络的全局搜索性能并提升收敛速度,有效规避神经网络陷入局部最优的困境。 将粒子群优化算法与反向传播神经网络相结合形成的PSO-BP神经网络,通过运用粒子群优化算法对反向传播神经网络的权值和阈值进行精细化调整,能够在预测纱线断裂强度方面,显著提升预测结果的...
植物实例分割数据集 一、基础信息 数据集名称:植物实例分割数据集 图片数量: - 训练集:9,600张图片 - 验证集:913张图片 - 测试集:455张图片 总计:10,968张图片 分类类别:59个类别,对应数字标签0至58,涵盖多种植物状态或特征。 标注格式:YOLO格式,适用于实例分割任务,包含多边形标注点。 数据格式:图像文件,来源于植物图像数据库,适用于计算机视觉任务。 二、适用场景 • 农业植物监测AI系统开发:数据集支持实例分割任务,帮助构建能够自动识别植物特定区域并分类的AI模型,辅助农业专家进行精准监测和分析。 • 智能农业应用研发:集成至农业管理平台,提供实时植物状态识别功能,为作物健康管理和优化种植提供数据支持。 • 学术研究与农业创新:支持植物科学与人工智能交叉领域的研究,助力发表高水平农业AI论文。 • 农业教育与培训:数据集可用于农业院校或培训机构,作为学生学习植物图像分析和实例分割技术的重要资源。 三、数据集优势 • 精准标注与多样性:标注采用YOLO格式,确保分割区域定位精确;包含59个类别,覆盖多种植物状态,具有高度多样性。 • 数据量丰富:拥有超过10,000张图像,大规模数据支持模型充分学习和泛化。 • 任务适配性强:标注兼容主流深度学习框架(如YOLO、Mask R-CNN等),可直接用于实例分割任务,并可能扩展到目标检测或分类等任务。
室内物体实例分割数据集 一、基础信息 • 数据集名称:室内物体实例分割数据集 • 图片数量: 训练集:4923张图片 验证集:3926张图片 测试集:985张图片 总计:9834张图片 • 训练集:4923张图片 • 验证集:3926张图片 • 测试集:985张图片 • 总计:9834张图片 • 分类类别: 床 椅子 沙发 灭火器 人 盆栽植物 冰箱 桌子 垃圾桶 电视 • 床 • 椅子 • 沙发 • 灭火器 • 人 • 盆栽植物 • 冰箱 • 桌子 • 垃圾桶 • 电视 • 标注格式:YOLO格式,包含实例分割的多边形标注,适用于实例分割任务。 • 数据格式:图片为常见格式如JPEG或PNG。 二、适用场景 • 实例分割模型开发:适用于训练和评估实例分割AI模型,用于精确识别和分割室内环境中的物体,如家具、电器和人物。 • 智能家居与物联网:可集成到智能家居系统中,实现自动物体检测和场景理解,提升家居自动化水平。 • 机器人导航与交互:支持机器人在室内环境中的物体识别、避障和交互任务,增强机器人智能化应用。 • 学术研究与教育:用于计算机视觉领域实例分割算法的研究与教学,助力AI模型创新与验证。 三、数据集优势 • 类别多样性:涵盖10个常见室内物体类别,包括家具、电器、人物和日常物品,提升模型在多样化场景中的泛化能力。 • 精确标注质量:采用YOLO格式的多边形标注,确保实例分割边界的准确性,适用于精细的物体识别任务。 • 数据规模充足:提供近万张标注图片,满足模型训练、验证和测试的需求,支持稳健的AI开发。 • 任务适配性强:标注格式兼容主流深度学习框架(如YOLO系列),便于快速集成到实例分割项目中,提高开发效率。
评论
成就一亿技术人!
拼手气红包6.0元
还能输入1000个字符  | 博主筛选后可见
 
红包 添加红包
表情包 插入表情
 条评论被折叠 查看
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值