Automatic scheduled restart of SQL Server recycle memory

Source: Internet
Author: User

Intermediary transaction http://www.aliyun.com/zixun/aggregation/6858.html ">seo diagnose Taobao guest cloud host technology Hall

Recently increased memory for the database server reached the maximum support of 8G, the database is MSSQL 2005, before the memory has been 4G, there is no memory large and 32-bit operating system conflicts, 32-bit operating system single process to support the largest 2G of memory, such as the memory on the white Plus, how to do?

Search the Internet for a lot of information, found that Microsoft offers a temporary solution, using AWE to allocate memory, so that the memory of the child SQL Server can basically reach the total system memory. However, after a period of operation, found a problem, is when the memory footprint increased to a certain amount (such as 6G), the memory will continue to increase, so long time will cause the memory run out, even may cause the server when the machine, courseware download Forum database server because of this in the evening of their own crash, caused access to be interrupted. The reason is that AWE does not automatically reclaim memory.

So an idea came out, because SQL Server restarts automatically reclaims memory, then the problem becomes a timed restart of SQL Server, and everyone knows that SQL Server has automatic backup functions, but there is no automatic restart function. When I suddenly thought of the scheduled task of Windows, could we use the scheduled task to restart SQL Server regularly?

Now the context is basically clear, based on the normal restart of SQL Server often prompted to turn off the automatic backup feature (that is, SQL Server Agent), so I create a new Notepad, and then renamed to Sql.bat, right-click Edit Enter the following content

net stop SQLServerAgent

net stop MSSQLServer

NET start MSSQLServer

Net start SQLServerAgent

Based on such content, the automatic operation will not appear any prompts, do not believe you can try to replace or cut down the above 4 statements, after the run should be prompted, need manual operation can.

Here is a new task in the Control Panel, which is omitted.

I started admin5 webmaster nets, reproduced please specify the source http://www.kejianxiazai.com.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.