Как я нахожу первопричину отказа давления Памяти на SQL-сервере 2008?

На основе Ваших правил перезаписи то, которые соответствуют Вашему URL:

RewriteRule ^vehicles/([^/]+)/([^/]+)/([^/]+)$ /store/product/list.php?make=$1&model=$2&year=$3&%{QUERY_STRING} [L,NC]  

Это - rewitten как:

/store/product/list.php?make=Chevrolet&model=Uplander&year=2006&

Как larsks и другие указал в этой точке, Вы должны:

Позвольте регистрироваться, переписывают правила через RewriteLog и RewriteLogLevel. Это должно помочь Вам разыскать проблему. – larsks Jan 11 в 16:50

Таким образом, Вы будете видеть то, что происходит, и можно затем отправить здесь журналы, чтобы иметь дальнейшую справку.

Затем знайте, что код mod_rewrite выполнен для каждого Запроса HTTP, который получает доступ к файлу в или ниже каталога, где код находится, таким образом, это могло быть корнем Вашей проблемы.

Можно использовать следующий код, который тестирует, если URL не закончится в .php и если он не сделает, то он пропустит следующие 6 RewriteRules.

RewriteRule !\.php$ - [S=6]
RewriteRule ^battery/([^/]+)$ /browser/product?sku=BATTERY+$1&type=battery
RewriteRule ^vehicles/([^/]+)/([^/]+)/([^/]+)/product([0-9]+)$ /browser/index.php?make=$1&model=$2&id=$3&%{QUERY_STRING} [L,NC]  
RewriteRule ^vehicles/([^/]+)/([^/]+)/([^/]+)/([0-9]+)$ /browser/product.php?make=$1&model=$2&year=$3&id=$4&%{QUERY_STRING} [L,NC]
RewriteRule ^vehicles/([^/]+)/([^/]+)/([^/]+)$ /store/product/list.php?make=$1&model=$2&year=$3&%{QUERY_STRING} [L,NC]
RewriteRule ^vehicles/([^/]+)/([^/]+)$ /vehicle/make/model/year/list.php?make=$1&model=$2&%{QUERY_STRING} [L,NC]
RewriteRule ^vehicles/([^/]+)$ /vehicle/make/model/list.php?make=$1&%{QUERY_STRING} [L,NC]

Надежда это помогает

3
задан 17 July 2013 в 23:41
3 ответа

To properly diagnose this, we need more information.

SQL server is like any other Windows process; it's virtual address space can be far larger than physical RAM. It can even be larger than RAM + paging files, if any part of it uses memory mapped files.

The tuning parameter in SQL server is a way to tell it to never use more than 'x' MB. You have to look at the peak commit charge of all other services on the box, subtract this from your physical RAM figure, and then give the remainder to SQL Server. As far as I'm aware, the memory cap only applies to the RDBMS, not the menagerie of related SQL server services. I could be wrong here.

So, we'd need more figures for the remaining processes. For example, you've got an IIS worker process consuming 273MB; is there just one worker process? Do you have anti-virus or backup software installed?

You could use WSRM to profile what's going on, and then consider applying memory caps. Alternatively, and it'd be my recommendation, install more RAM.

To get a graphical view of where your memory is going, have a nose at Microsoft SysInternals' RAMMap utility.

1
ответ дан 3 December 2019 в 05:44

Is there a way to effectively stop this issue from occurring?

The glib answer would be to suggest you buy more memory. That might not solve your problem, but it probably wouldn't hurt.

SQL Server likes memory. SQL Server likes to cache your database, or chunks of your databases, in memory so they'll be accessed faster. If you want to see what's in your memory right now, you can get that information out of the DMV: http://www.mssqltips.com/sqlservertip/2393/determine-sql-server-memory-use-by-database-and-object/. One of my coworkers once received a vendor recommendation that database size for their product's DB never exceed the size of the server's memory. That's impractical for most people, but if you're trying to serve up a heavily queried 10TB database with 16GB of RAM, that might be a problem.

Try running sp_blitz on your server--it's a stored procedure that checks your server for problems. http://www.brentozar.com/blitz/

Also try perfmon: http://www.brentozar.com/archive/2006/12/dba-101-using-perfmon-for-sql-performance-tuning/

That should help you track down the cause.

2
ответ дан 3 December 2019 в 05:44

Возможно, вам потребуется увеличить размер файла подкачки, чтобы иметь возможность обрабатывать периодические всплески в размере фиксации памяти. У нас часто возникает эта проблема в вычислениях Azure, где для файла подкачки по умолчанию установлено слишком низкое значение для приложений, интенсивно использующих память.

Подробнее см. Здесь: http://mvolo.com/low-pagefile-can-cause -503-service-unavailable-on-azure-web-roles /

Это не решит проблему, если вашему экземпляру SQL требуется намного больше памяти, чем у вас, но это может помочь лучше выдержать временные всплески.

2
ответ дан 3 December 2019 в 05:44

Теги

Похожие вопросы