`
夜乡晨
  • 浏览: 37515 次
  • 性别: Icon_minigender_1
  • 来自: 重庆
社区版块
存档分类
最新评论
阅读更多

AWE Memory

If you are using SQL Server 2000 Standard Edition under Windows NT 4.0, Windows 2000 (any version), or Windows 2003 (any version), or are running SQL Server 2000 Enterprise Edition under the Standard Edition Windows NT 4.0, Windows 2000, or Windows 2003, or if your server has 4GB or less of RAM, the “awe enabled ” option should always be left to the default value of 0, which means that AWE memory is not being used.

The AWE (Advanced Windowing Extensions) API allows applications (that are written to use the AWE API) to run under Windows 2000 Advanced Server or Windows 2000 Datacenter Server (or Windows 2003 Enterprise and Datacenter Editions) to access more than 4GB of RAM.

SQL Server 2000 and SQL Server 2005 Enterprise Edition (not SQL Server 2000 or 2005 Standard Edition) are AWE-enabled and can take advantage of RAM in a server of 4GB or more.

If the operating system is Windows 2000 Advanced Server, SQL Server 2000 Enterprise Edition can us up to 8GB of RAM. If the operating system is Windows 2000 Datacenter Server, SQL Server 2000 Enterprise can use up to 64GB of RAM.

SQL Server 2005 Enterprise Edition supports AWE memory, allowing the use of physical memory over 4 gigabytes (GB) on 32-bit versions of Microsoft Windows operating systems. Up to 64 GB of physical memory is supported.

In order for the operating system and SQL Server 2000 or SQL Server 2005 Enterprise Edition to take advantage of the additional RAM, two steps must be completed.

Exactly how you configure AWE memory support depends on how much RAM your server has. To configure Windows 2000 or 2003, you must enter one of the following switches in the boot line of the boot.ini file, and reboot the server:

·         4GB RAM:  /3GB (AWE support is not used)

·         8GB RAM:  /3GB /PAE

·         16GB RAM:  /3GB /PAE

·         16GB + RAM:  /PAE

The /3GB switch is used to tell SQL Server to take advantage of 3GB out of the base 4GB of RAM that Windows 2000 supports natively. If you don’t specify this option, then SQL Server will only take advantage of 2GB of the first 4GB of RAM in the server, essentially wasting 1GB of RAM.

AWE memory technology is used only for the RAM that exceeds the base 4GB of RAM, that’s why the /3GB switch is needed to use as much of the RAM in your server as possible. If your server has 16GB or less of RAM, then using the /3GB switch is important. But if your server has more than 16GB of RAM, then you must not use the /3GB switch. The reason for this is because the 1GB of additional RAM provided by adding the /3GB switch is needed by the operating system in order to take advantage of all of the extra AWE memory. In other words, the operating system needs 2GB of RAM itself to mange the AWE memory if your server has more than 16GB of RAM. If 16GB or less of RAM is in a server, then the operating system only needs 1GB of RAM, allowing the other 1GB of RAM for use by SQL Server.

Once this step is done, the next step is to set the “awe enabled” option to 1 within SQL Server 2000 or 2005 Enterprise Edition, and then restart the SQL Server service. Only at this point will SQL Server be able to use the additional RAM in the server.

One caution about using the “awe enabled” setting is that after turning it on, SQL Server no longer dynamically manages memory. Instead, it takes all of the available RAM (except about 128MB which is left for the operating system). If you want to prevent SQL Server from taking all of the RAM, you must set the “max server memory” option (described in more detail later in this article) to a figure that limits SQL Server to the amount or RAM you specify. (7.0, 2000, 2005) Updated 1-2-2004

*****

If you find that you are running into a memory bottleneck, and assuming you have the money to spend, SQL Server 2000 and SQL Server 2005 Enterprise Edition can support up to 64GB of RAM . How much RAM SQL Server 2000 or SQL Server 2005 Enterprise Edition can use depends on which version of Windows 2000 or Windows 2003 you are using and how much RAM your server can support. Assuming your server can handle it, SQL Server 2000 Enterprise Edition supports up to 8GB under Windows Advanced Server 2000 and Windows 2003 Enterprise, and up to 64GB under Windows Data Center for both Windows 2000 and Windows 2003.

Normally, 32-bit CPUs, such as the Pentium family of processors, can only support up to 4GB of RAM because of its limited address space. To get around this limitation, SQL Server 2000 and SQL Server 2005 Enterprise Edition supports a feature called AWE (Address Windowing Extensions) that allows up to 64GB of RAM to be addressed.

Assuming you configure the appropriate hardware and software, AWE support is not turned automatically on, you have to do this step manually. To turn AWE support on, you must change the “awe enabled” advanced SQL Server 2000 or 2005  option from 0 to 1. For example, to turn on AWE support:

SP_CONFIGURE ‘show advanced options’, 1 
RECONFIGURE                             
GO

SP_CONFIGURE ‘awe enabled’, 1
RECONFIGURE
GO

AWE memory cannot be dynamically managed, like memory is normally managed in SQL Server. This means that SQL Server will automatically grab all the RAM it can when it starts (except for about 128MB, which is reserved for the operating system), but it will not release any of this RAM until SQL Server is turned off. If your server is a dedicated SQL Server, then this might be OK. But if you are running other software on the server, or are running multiple instances of SQL Server, then you must specify the maximum amount of RAM that SQL Server can grab when it is started. This can be done using the “max server memory” configuration option. If you change this setting, you will have to stop and start the mssqlserver service in order for the new setting to take affect. 

To set the maximum amount of memory that AWE memory can access, you can use SQL Server’s “max server memory” configuration option. For example:

SP_CONFIGURE ‘max server memory’, 4096
RECONFIGURE
GO

In the above example, we are telling SQL Server to only use 4GB of RAM, leaving any other RAM available in the server free for other applications.

While multiple instances of SQL Server can be used with AWE memory, you probably won’t want to, as it can be a headache to manage. In fact, running multiple instances of SQL Server in AWE memory defeats the purpose of more RAM in the first place. Generally, your goal of using AWE memory should be to support a single, very large instance of SQL Server, not lots of smaller instances running on a single server.

分享到:
评论

相关推荐

    微软内部资料-SQL性能优化2

    When used in combination with Intel’s Physical Addressing Extensions (PAE) on Windows 2000, an AWE enabled application can support up to 64 GB of memory Reserved Memory Pages in a processes address...

    SQLServer内存问题与AWE[参考].pdf

    启用AWE需要在boot.ini文件中添加/pae参数,赋予SQL Server进程"Lock Pages in Memory"权限,并在SQL Server配置管理器中设置"AWE Enabled"为1。 启用AWE后,SQL Server会动态管理这部分内存,根据实际需求分配和...

    突破2G内存限制 SQL2005 AWE配置

    ### 突破2G内存限制 SQL2005 AWE配置详解 #### 一、引言 在早期的32位系统环境下,由于寻址能力的限制,单个进程可使用的物理内存被限定在大约2GB左右。这对于运行大型数据库如SQL Server 2005来说是一个明显的...

    SQL语句实现查询SQL Server内存使用状况

    SELECT type,--Clerk的...sum(awe_allocated_kb)as awe_Allocated_kb,--开启AWE后使用的内存 sum(shared_memory_reserved_kb)as sm_Reserved_kb,--共享的保留内存 sum(shared_memory_committed_kb)as sm_Committed_k

    在32位sql server 使用4G以上的内存设置

    在32位操作系统中,SQL Server 2005可以使用 Address Windowing Extensions(AWE)来访问超过4GB的物理内存。AWE是一种机制,可以让32位操作系统访问超过4GB的物理内存,但需要在操作系统和SQL Server中进行特殊配置...

    WINDOWS平台上扩展SGA

    3. **计算 AWE_WINDOW_MEMORY 参数**:AWE_WINDOW_MEMORY 是一个重要的参数,它定义了 Oracle 数据库能够使用的 AWE 窗口的最小内存大小。在 Oracle 8.1.7 版本中,该参数的默认值较小;而在 Oracle 9.2.0 及更高...

    oracle中4G以上内存的使用方法

    - 最小内存池大小(Min AWE Window Memory Size)计算公式为: \[ min(AWE_WINDOW_MEMORY) = (4096 * db_block_size * db_block_lru_latches) / 8 \] 其中`db_block_size`是数据库块大小,`db_block_lru_latches...

    32位Windows上使用超过1.7GB SGA的方法

    3. **配置AWE_WINDOW_MEMORY**:除了启用4GTuning之外,还需要配置Oracle中的AWE(Address Windows Extensions)特性,以充分利用扩展的地址空间。根据不同的Oracle版本,配置AWE_WINDOW_MEMORY参数的方式有所不同。 ...

    ORCALE 在windows 2003 32-bit上的限制.doc

    - **修改注册表**:在HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\HOME0下添加AWE_WINDOW_MEMORY注册表项,并设置值,以指定Oracle使用AWE的内存大小。 - **分配“Lock Pages in Memory”权限**:为了防止Oracle进程中的...

    优化SQL内存(设置SQL3G內存)

    3. **监控内存使用情况**: 使用SQL Server Management Studio (SSMS) 或动态管理视图 (DMV) 如 `sys.dm_os_memory_clerks` 和 `sys.dm_os_process_memory` 监控内存使用,确保设置合理且没有其他系统进程受到负面...

    让windows 2003 x86支持4G以上内存.docx

    sp_configure 'max server memory', 6144; -- 设置最大内存为6GB RECONFIGURE; ``` #### 注意事项 - **仅限特定版本**:只有SQL Server 2005 Enterprise Edition、Standard Edition和Developer Edition支持AWE。 - ...

    xp 识别大内存

    2. **修改注册表**:打开注册表编辑器(regedit),找到`HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Session Manager\Memory Management`,在右侧窗口中创建或修改一个名为`LargeSystemCache`的DWORD值,...

    oracle 在2003下修改使用内存大于1.7G的步骤

    然后,需要修改 Windows 注册表,找到 HKEY_LOCAL_MACHINE\SOFTWARE\ORACLE\HOME0 目录中的 AWE_WINDOW_MEMORY 参数,将其修改为 Oracle 需要的内存大小。 其次,需要修改 Windows 控制面板中的管理工具,加入启 ...

    32位Windows下Oracle使用大内存的方法.pdf

    - 修改注册表,增加Oracle的AWE分配,如在`HKLM\SOFTWARE\ORACLE\KEY_{ORACLE_HOME}`下设置`AWЕ_WINDOW_MEMORY`为1073741824(即1GB)。 - 修改服务器启动参数,开启/PAE和/3GB,编辑C盘根目录的“boot.ini”文件...

    SQL server服务器大内存配置

    - 使用`sp_configure`存储过程来设置`aweenabled`为1,并指定`maxservermemory`值,例如6GB(6144MB)。 - 运行以下T-SQL命令以启用AWE,并设置最大内存使用量: ```sql sp_configure 'showadvancedoptions', 1 ...

    分析SQL server服务器的内存配置

    最后,使用 sp_configure 系统存储过程来设置 max server memory 为所需的值,例如 6144。 在完成以上步骤后,需要重新启动 SQL Server 2000 实例,以使更改生效。启动 SQL Server 服务后,SQL 服务将锁定指定的...

    SQL内存配置[总结].pdf

    4. **PAE和AWE**:物理地址扩展(PAE)和地址窗口化扩展(AWE)是32位操作系统处理超过4GB内存的技术。PAE允许处理器访问更多物理内存,而AWE则允许SQL Server在32位系统上使用超过4GB的内存。但在64位操作系统中,这些...

    配置SQL??32位和64位系统中的内存配置

    SQL Server中的"Maximum Server Memory"和"Minimum Server Memory"配置选项用于控制数据库引擎使用的内存范围。前者定义了SQL Server实例可以使用的最大内存,而后者设置了最小内存,确保系统其他服务能获取足够的...

Global site tag (gtag.js) - Google Analytics