{"id":3114,"date":"2023-12-21T17:25:00","date_gmt":"2023-12-21T13:25:00","guid":{"rendered":"https:\/\/extralan.ru\/?p=3114"},"modified":"2023-12-21T17:41:05","modified_gmt":"2023-12-21T13:41:05","slug":"wsus-reset-server-node-sqlexception-execution-timeout-expired","status":"publish","type":"post","link":"https:\/\/extralan.ru\/?p=3114","title":{"rendered":"WSUS &#8212; Reset Server Node &#8212; SqlException Execution Timeout Expired"},"content":{"rendered":"\n<p>\u041e\u0445 \u0443\u0436 \u044d\u0442\u043e\u0442 WSUS, \u0441\u0442\u043e\u043b\u044c\u043a\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u044a\u0435\u043b \u0437\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u0443\u044e \u0441 \u043d\u0438\u043c 15 \u043b\u0435\u0442\u043d\u044e\u044e \u0436\u0438\u0437\u043d\u044c. \u0412 \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0439 \u0440\u0430\u0437 \u0411\u0414 <strong>SUSDB<\/strong> \u0440\u0430\u0437\u0440\u043e\u0441\u043b\u0430\u0441\u044c \u0434\u043e <strong>52GB<\/strong>, \u043e\u0447\u0438\u0441\u0442\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0447\u0435\u0440\u0435\u0437 MMC \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0438 \u043f\u0440\u0435\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c <strong>System.Data.SqlClient.SqlException &#8212; Execution Timeout Expired<\/strong>.  <strong>Invoke-WsusServerCleanup -CleanupObsoleteUpdates<\/strong> \u043e\u0431\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0442\u0430\u043a\u0438\u043c \u0436\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c \u0438 \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f. \u0421\u0430\u043c\u0430 \u0411\u0414 WSUS \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0430 \u043d\u0430 \u043e\u0442\u0434\u0435\u043b\u044c\u043d\u043e \u0441\u0442\u043e\u044f\u0449\u0435\u043c MS SQL Server 2014, \u0411\u0414 \u0436\u0438\u0432\u0430, \u0432\u043e \u0432\u0440\u0435\u043c\u044f \u043e\u043f\u0435\u0440\u0430\u0446\u0438\u0438 \u043f\u043e \u043e\u0447\u0438\u0441\u0442\u043a\u0435 \u0433\u0440\u0443\u0437\u0438\u0442 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0440 \u0438 \u0434\u0438\u0441\u043a \u043d\u0430 \u043f\u043e\u043b\u043d\u0443\u044e. \u042f \u0442\u0430\u043a \u043f\u043e\u043d\u0438\u043c\u0430\u044e, \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 WSUS \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043d\u0435 \u0434\u043e\u0436\u0438\u0434\u0430\u0435\u0442\u0441\u044f \u043e\u043a\u043e\u043d\u0447\u0430\u043d\u0438\u044f \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u043e\u0434\u043d\u043e\u0433\u043e \u0438\u0437 \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0438 \u0441\u0432\u0430\u043b\u0438\u0432\u0430\u0435\u0442\u0441\u044f \u0432 Timeout.<\/p>\n\n\n\n<p>\u0420\u0430\u0441\u0441\u043b\u0435\u0434\u043e\u0432\u0430\u043d\u0438\u044f, \u043f\u043e\u0438\u0441\u043a \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438, \u043f\u0440\u043e\u0431\u044b \u0432\u0441\u0435\u0433\u043e \u0438 \u0432\u0441\u044f \u0431\u044b\u043b\u0438 \u043a\u0440\u0430\u0439\u043d\u0435 \u0434\u043e\u043b\u0433\u0438\u043c\u0438. \u0422\u0430\u0439\u043c\u0430\u0443\u0442\u044b, \u043b\u0438\u043c\u0438\u0442\u044b \u0438 \u043f\u0440\u043e\u0447\u0435\u0435 \u0431\u044b\u043b\u0438 \u043b\u0438\u0431\u043e \u0443\u0431\u0440\u0430\u043d\u044b, \u043b\u0438\u0431\u043e \u043f\u043e\u0441\u0442\u0430\u0432\u043b\u0435\u043d\u044b \u0432 \u043c\u0430\u043a\u0441\u0438\u043c\u0430\u043b\u044c\u043d\u043e \u0432\u043e\u0437\u043c\u043e\u0436\u043d\u044b\u0435 \u0437\u043d\u0430\u0447\u0435\u043d\u0438\u044f, \u043d\u043e \u044d\u0442\u043e \u043d\u0435 \u043f\u043e\u043c\u043e\u0433\u0430\u043b\u043e. \u0421\u043a\u0440\u0438\u043f\u0442 \u043f\u0435\u0440\u0435\u0441\u0442\u0440\u043e\u0439\u043a\u0438 \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u0432 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u043b\u0441\u044f. \u041d\u0430\u0447\u0430\u043b \u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c, \u043e\u0442\u043a\u0443\u0434\u0430 \u0442\u0430\u043a\u043e\u0439 \u0431\u043e\u043b\u044c\u0448\u043e\u0439 \u0440\u0430\u0437\u043c\u0435\u0440 \u0443 \u0411\u0414. \u0412\u044b\u044f\u0441\u043d\u0438\u043b\u043e\u0441\u044c, \u0447\u0442\u043e \u0442\u0430\u0431\u043b\u0438\u0446\u0430 <strong>tbEventInstance<\/strong> \u0437\u0430\u043d\u0438\u043c\u0430\u043b\u0430 \u0431\u043e\u043b\u044c\u0448\u0435 \u043f\u043e\u043b\u043e\u0432\u0438\u043d\u044b \u0437\u0430\u043d\u044f\u0442\u043e\u0433\u043e \u043f\u0440\u043e\u0441\u0442\u0440\u0430\u043d\u0441\u0442\u0432\u0430, \u0447\u0435\u0440\u0435\u0437 SQL Server Management Studio \u043e\u0442\u043a\u0440\u044b\u043b \u0441\u0432\u043e\u0439\u0441\u0442\u0432\u0430 \u0442\u0430\u0431\u043b\u0438\u0446\u044b:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>Index Space 1&nbsp;916,078 MB\nRow Count 7 720 991\nData Space 39&nbsp;325,508 MB<\/code><\/pre>\n\n\n\n<p>\u041d\u0435\u0434\u043e\u043b\u0433\u0438\u0439 \u043f\u043e\u0438\u0441\u043a \u0432 \u0438\u043d\u0442\u0435\u0440\u043d\u0435\u0442\u0435 \u043f\u0440\u0438\u0432\u0451\u043b \u043a \u0441\u0442\u0430\u0442\u044c\u0435 <a href=\"https:\/\/www.betaarchive.com\/wiki\/index.php\/Microsoft_KB_Archive\/909131\">https:\/\/www.betaarchive.com\/wiki\/index.php\/Microsoft_KB_Archive\/909131<\/a> \u0432 \u043a\u043e\u0442\u043e\u0440\u043e\u0439 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0434\u043e\u0445\u043e\u0434\u0447\u0438\u0432\u043e \u0440\u0430\u0437\u044a\u044f\u0441\u043d\u0435\u043d\u043e: \u043e\u0434\u043d\u0430 \u0438\u0437 \u043f\u0440\u0438\u0447\u0438\u043d \u043e\u0448\u0438\u0431\u043a\u0438 \u0441\u0432\u044f\u0437\u0430\u043d\u0430 \u0441 \u0442\u0435\u043c, \u0447\u0442\u043e \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0442\u0430\u0431\u043b\u0438\u0446\u044b <strong>tbEventInstance<\/strong> \u043f\u0440\u0435\u0432\u044b\u0441\u0438\u043b\u043e 1 \u043c\u0438\u043b\u043b\u0438\u043e\u043d \u0437\u0430\u043f\u0438\u0441\u0435\u0439:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>This problem occurs if the number of reporting events in the tbEventInstance table exceeds 1 million rows.\n\nA WSUS server that is using the recommended hardware can support a maximum number of 15,000 clients by using a default detection cycle of 22 hours. The number of reporting events that is added to the tbEventInstance table depends on the number of clients and on the frequency that is set for each detection cycle. Automatic deletion of rows from the tbEventInstance table starts when a client tries to send a report. The automatic deletion process is initiated only if the reporting events in the tbEventInstance table exceed 1 million rows.\n\nThe automatic deletion process is very slow and blocks the client computers from reporting back to the WSUS server. By default, WSUS is configured to delete events that are older than 15 days on workstations and that are older than 90 days on servers. WSUS deletes old events at the rate of 1,000 events every 12 hours.<\/code><\/pre>\n\n\n\n<p>\u0412\u0438\u0434\u0438\u043c\u043e \u0432 \u043c\u0435\u0445\u0430\u043d\u0438\u0437\u043c\u0435 \u043e\u0447\u0438\u0441\u0442\u043a\u0438 \u0447\u0442\u043e-\u0442\u043e \u0437\u0430\u0441\u0442\u0440\u044f\u043b\u043e, \u043b\u0438\u0431\u043e \u043d\u0435\u043a\u043e\u0440\u0440\u0435\u043a\u0442\u043d\u043e \u043d\u0430\u0441\u0442\u0440\u043e\u0435\u043d\u043e.<\/p>\n\n\n\n<p>\u041e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u043b \u0441\u0435\u0440\u0432\u0435\u0440 WSUS \u0438 \u0432\u0435\u0431 \u0441\u0435\u0440\u0432\u0435\u0440: WSUS Service \u0438 World Wide Web Publishing Service.<\/p>\n\n\n\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043b \u043e\u0447\u0438\u0441\u0442\u043a\u0443 \u0442\u0430\u0431\u043b\u0438\u0446\u044b:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>USE SUSDB;\nTRUNCATE TABLE tbEventInstance;\n<\/code><\/pre>\n\n\n\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043b &#171;\u0443\u043c\u0435\u043d\u044c\u0448\u0435\u043d\u0438\u0435&#187; \u0411\u0414, \u0447\u0442\u043e\u0431\u044b \u043e\u0441\u0432\u043e\u0431\u043e\u0434\u0438\u0442\u044c, \u0445\u043e\u0442\u044f \u0431\u044b \u0432\u0440\u0435\u043c\u0435\u043d\u043d\u043e, \u043c\u0435\u0441\u0442\u043e \u043d\u0430 \u0434\u0438\u0441\u043a\u0435:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>DBCC SHRINKDATABASE ('SUSDB');  <\/code><\/pre>\n\n\n\n<p>\u0411\u0414 \u0441\u0442\u0430\u043b\u0430 \u0437\u0430\u043d\u0438\u043c\u0430\u0442\u044c 5.5 \u0413\u0411 \u0432\u043c\u0435\u0441\u0442\u043e 52 \u0413\u0411.<\/p>\n\n\n\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043b \u043f\u0435\u0440\u0435\u0441\u0442\u0440\u043e\u0435\u043d\u0438\u0435 \u0438 \u0440\u0435\u043e\u0440\u0433\u0430\u043d\u0438\u0437\u0430\u0446\u0438\u044e \u0438\u043d\u0434\u0435\u043a\u0441\u043e\u0432 (\u0441\u043a\u0440\u0438\u043f\u0442 \u043e\u0442 MS):<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>USE SUSDB; \nGO \nSET NOCOUNT ON; \n \n-- Rebuild or reorganize indexes based on their fragmentation levels \nDECLARE @work_to_do TABLE ( \n    objectid int \n    , indexid int \n    , pagedensity float \n    , fragmentation float \n    , numrows int \n) \n \nDECLARE @objectid int; \nDECLARE @indexid int; \nDECLARE @schemaname nvarchar(130);  \nDECLARE @objectname nvarchar(130);  \nDECLARE @indexname nvarchar(130);  \nDECLARE @numrows int \nDECLARE @density float; \nDECLARE @fragmentation float; \nDECLARE @command nvarchar(4000);  \nDECLARE @fillfactorset bit \nDECLARE @numpages int \n \n-- Select indexes that need to be defragmented based on the following \n-- * Page density is low \n-- * External fragmentation is high in relation to index size \nPRINT 'Estimating fragmentation: Begin. ' + convert(nvarchar, getdate(), 121)  \nINSERT @work_to_do \nSELECT \n    f.object_id \n    , index_id \n    , avg_page_space_used_in_percent \n    , avg_fragmentation_in_percent \n    , record_count \nFROM  \n    sys.dm_db_index_physical_stats (DB_ID(), NULL, NULL , NULL, 'SAMPLED') AS f \nWHERE \n    (f.avg_page_space_used_in_percent &lt; 85.0 and f.avg_page_space_used_in_percent\/100.0 * page_count &lt; page_count - 1) \n    or (f.page_count &gt; 50 and f.avg_fragmentation_in_percent &gt; 15.0) \n    or (f.page_count &gt; 10 and f.avg_fragmentation_in_percent &gt; 80.0) \n \nPRINT 'Number of indexes to rebuild: ' + cast(@@ROWCOUNT as nvarchar(20)) \n \nPRINT 'Estimating fragmentation: End. ' + convert(nvarchar, getdate(), 121) \n \nSELECT @numpages = sum(ps.used_page_count) \nFROM \n    @work_to_do AS fi \n    INNER JOIN sys.indexes AS i ON fi.objectid = i.object_id and fi.indexid = i.index_id \n    INNER JOIN sys.dm_db_partition_stats AS ps on i.object_id = ps.object_id and i.index_id = ps.index_id \n \n-- Declare the cursor for the list of indexes to be processed. \nDECLARE curIndexes CURSOR FOR SELECT * FROM @work_to_do \n \n-- Open the cursor. \nOPEN curIndexes \n \n-- Loop through the indexes \nWHILE (1=1) \nBEGIN \n    FETCH NEXT FROM curIndexes \n    INTO @objectid, @indexid, @density, @fragmentation, @numrows; \n    IF @@FETCH_STATUS &lt; 0 BREAK; \n \n    SELECT  \n        @objectname = QUOTENAME(o.name) \n        , @schemaname = QUOTENAME(s.name) \n    FROM  \n        sys.objects AS o \n        INNER JOIN sys.schemas as s ON s.schema_id = o.schema_id \n    WHERE  \n        o.object_id = @objectid; \n \n    SELECT  \n        @indexname = QUOTENAME(name) \n        , @fillfactorset = CASE fill_factor WHEN 0 THEN 0 ELSE 1 END \n    FROM  \n        sys.indexes \n    WHERE \n        object_id = @objectid AND index_id = @indexid; \n \n    IF ((@density BETWEEN 75.0 AND 85.0) AND @fillfactorset = 1) OR (@fragmentation &lt; 30.0) \n        SET @command = N'ALTER INDEX ' + @indexname + N' ON ' + @schemaname + N'.' + @objectname + N' REORGANIZE'; \n    ELSE IF @numrows &gt;= 5000 AND @fillfactorset = 0 \n        SET @command = N'ALTER INDEX ' + @indexname + N' ON ' + @schemaname + N'.' + @objectname + N' REBUILD WITH (FILLFACTOR = 90)'; \n    ELSE \n        SET @command = N'ALTER INDEX ' + @indexname + N' ON ' + @schemaname + N'.' + @objectname + N' REBUILD'; \n    PRINT convert(nvarchar, getdate(), 121) + N' Executing: ' + @command; \n    EXEC (@command); \n    PRINT convert(nvarchar, getdate(), 121) + N' Done.'; \nEND \n \n-- Close and deallocate the cursor. \nCLOSE curIndexes; \nDEALLOCATE curIndexes; \n \n \nIF EXISTS (SELECT * FROM @work_to_do) \nBEGIN \n    PRINT 'Estimated number of pages in fragmented indexes: ' + cast(@numpages as nvarchar(20)) \n    SELECT @numpages = @numpages - sum(ps.used_page_count) \n    FROM \n        @work_to_do AS fi \n        INNER JOIN sys.indexes AS i ON fi.objectid = i.object_id and fi.indexid = i.index_id \n        INNER JOIN sys.dm_db_partition_stats AS ps on i.object_id = ps.object_id and i.index_id = ps.index_id \n \n    PRINT 'Estimated number of pages freed: ' + cast(@numpages as nvarchar(20)) \nEND \nGO \n \n \n--Update all statistics \nPRINT 'Updating all statistics.' + convert(nvarchar, getdate(), 121)  \nEXEC sp_updatestats \nPRINT 'Done updating statistics.' + convert(nvarchar, getdate(), 121)  \nGO<\/code><\/pre>\n\n\n\n<p>\u0417\u0430\u043f\u0443\u0441\u0442\u0438\u043b \u0441\u0435\u0440\u0432\u0438\u0441\u044b WSUS Service \u0438 World Wide Web Publishing Service<\/p>\n\n\n\n<p>\u0418\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044f \u043e \u0441\u0438\u043d\u0445\u0440\u043e\u043d\u0438\u0437\u0430\u0446\u0438\u044f\u0445 \u0438\u0441\u0447\u0435\u0437\u043b\u0430, \u0437\u0430\u043f\u0443\u0441\u0442\u0438\u043b \u0437\u0430\u043d\u043e\u0432\u043e, \u043f\u0440\u043e\u0448\u043b\u0430 \u0431\u044b\u0441\u0442\u0440\u043e \u0438 \u0445\u043e\u0440\u043e\u0448\u043e, \u043d\u0430\u0448\u043b\u0430 5 \u043d\u043e\u0432\u044b\u0445 \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0439 \u0438 \u043f\u043e\u043c\u0435\u0442\u0438\u043b\u0430 5 \u043a\u0430\u043a \u043f\u0440\u043e\u0441\u0440\u043e\u0447\u0435\u043d\u043d\u044b\u0435.<\/p>\n\n\n\n<p>\u0420\u0435\u0437\u0443\u043b\u044c\u0442\u0430\u0442, \u043a\u0430\u043a \u0433\u043e\u0432\u043e\u0440\u0438\u0442\u0441\u044f &#8212; \u043d\u0430 \u043b\u0438\u0446\u043e, \u0411\u0414 \u0441\u0442\u0430\u043b\u0430 \u0437\u0430\u043d\u0438\u043c\u0430\u0442\u044c \u043c\u0435\u043d\u044c\u0448\u0435 \u043c\u0435\u0441\u0442\u0430, \u043f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0430 \u043e\u0447\u0438\u0441\u0442\u043a\u0438 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u043f\u0440\u043e\u0448\u043b\u0430 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0431\u044b\u0441\u0442\u0440\u043e \u0438 \u0431\u0435\u0437 \u043e\u0448\u0438\u0431\u043e\u043a.<\/p>\n\n\n\n<p>\u041d\u0438\u0436\u0435 \u043f\u0440\u0438\u0432\u0435\u0434\u0443 \u043d\u0435\u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043e\u043f\u0446\u0438\u0438 \u0438 \u0437\u0430\u043f\u0440\u043e\u0441\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u043c\u0438 \u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043b\u0441\u044f.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\">\u041f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u0442\u043e\u043f 10 \u0432\u044b\u043f\u043e\u043b\u043d\u044f\u044e\u0449\u0438\u0445\u0441\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432 \u0432 \u0411\u0414<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>SELECT TOP 10 s.session_id,\n           r.status,\n           r.cpu_time,\n           r.logical_reads,\n           r.reads,\n           r.writes,\n           r.total_elapsed_time \/ (1000 * 60) 'Elaps M',\n           SUBSTRING(st.TEXT, (r.statement_start_offset \/ 2) + 1,\n           ((CASE r.statement_end_offset\n                WHEN -1 THEN DATALENGTH(st.TEXT)\n                ELSE r.statement_end_offset\n            END - r.statement_start_offset) \/ 2) + 1) AS statement_text,\n           COALESCE(QUOTENAME(DB_NAME(st.dbid)) + N'.' + QUOTENAME(OBJECT_SCHEMA_NAME(st.objectid, st.dbid)) \n           + N'.' + QUOTENAME(OBJECT_NAME(st.objectid, st.dbid)), '') AS command_text,\n           r.command,\n           s.login_name,\n           s.host_name,\n           s.program_name,\n           s.last_request_end_time,\n           s.login_time,\n           r.open_transaction_count\nFROM sys.dm_exec_sessions AS s\nJOIN sys.dm_exec_requests AS r ON r.session_id = s.session_id CROSS APPLY sys.Dm_exec_sql_text(r.sql_handle) AS st\nWHERE r.session_id != @@SPID\nORDER BY r.cpu_time DESC<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u0423\u0437\u043d\u0430\u0442\u044c \u043a\u043e\u043b\u0438\u0447\u0435\u0441\u0442\u0432\u043e &#171;\u043d\u0435\u043d\u0443\u0436\u043d\u044b\u0445&#187; \u043e\u0431\u043d\u043e\u0432\u043b\u0435\u043d\u0438\u0439<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>USE SUSDB <br>GO <br>EXEC spGetObsoleteUpdatesToCleanup<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u0418\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0438\u043b\u0438 \u0443\u0431\u0440\u0430\u0442\u044c \u0442\u0430\u0439\u043c\u0430\u0443\u0442 \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f \u0437\u0430\u043f\u0440\u043e\u0441\u043e\u0432<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>USE SUSDB;\nGO\nEXEC sp_configure 'remote query timeout', 0 ;\nGO\nRECONFIGURE ;<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u0418\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0438\u043b\u0438 \u0443\u0431\u0440\u0430\u0442\u044c \u0442\u0430\u0439\u043c\u0430\u0443\u0442 \u0432 \u043f\u0443\u043b\u0435 IIS<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-Module WebAdministration\nImport-Module WebAdministration\n\nGet-ChildItem IIS:\\AppPools | ? name -eq \"WsusPool\" |\nselect name, @{Name=\"Timeout\"; Exp={$_.processmodel.idletimeout}} \n\nSet-ItemProperty IIS:\\AppPools\\WsusPool -Name processModel.idleTimeout -Value \"00:00:00\"<\/code><\/pre>\n\n\n\n<h2 class=\"wp-block-heading\">\u0418\u0437\u043c\u0435\u043d\u0438\u0442\u044c \u0438\u043b\u0438 \u0443\u0431\u0440\u0430\u0442\u044c \u043e\u0433\u0440\u0430\u043d\u0438\u0447\u0435\u043d\u0438\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u043e\u0439 \u043f\u0430\u043c\u044f\u0442\u0438 \u0432 \u043f\u0443\u043b\u0435 IIS<\/h2>\n\n\n\n<pre class=\"wp-block-code\"><code>Get-ChildItem IIS:\\AppPools | ? name -eq \"WsusPool\" |\nselect name, @{Name=\"Memory\"; Exp={$_.recycling.periodicrestart.privateMemory}}\n\nSet-ItemProperty IIS:\\AppPools\\WsusPool -Name recycling.periodicrestart.privateMemory -Value 0<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>\u041e\u0445 \u0443\u0436 \u044d\u0442\u043e\u0442 WSUS, \u0441\u0442\u043e\u043b\u044c\u043a\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u044a\u0435\u043b \u0437\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u0443\u044e \u0441 \u043d\u0438\u043c 15 \u043b\u0435\u0442\u043d\u044e\u044e \u0436\u0438\u0437\u043d\u044c. \u0412 \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0439 \u0440\u0430\u0437 \u0411\u0414 SUSDB \u0440\u0430\u0437\u0440\u043e\u0441\u043b\u0430\u0441\u044c \u0434\u043e 52GB, \u043e\u0447\u0438\u0441\u0442\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0447\u0435\u0440\u0435\u0437 MMC \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0438 \u043f\u0440\u0435\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c System.Data.SqlClient.SqlException &#8212; Execution Timeout Expired. Invoke-WsusServerCleanup -CleanupObsoleteUpdates \u043e\u0431\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0442\u0430\u043a\u0438\u043c \u0436\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c \u0438 \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f. \u0421\u0430\u043c\u0430 \u0411\u0414 WSUS \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0430&hellip;<\/p>\n <a href=\"https:\/\/extralan.ru\/?p=3114\" title=\"WSUS &#8212; Reset Server Node &#8212; SqlException Execution Timeout Expired\" class=\"entry-more-link\"><span>Read More<\/span> <span class=\"screen-reader-text\">WSUS &#8212; Reset Server Node &#8212; SqlException Execution Timeout Expired<\/span><\/a>","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"Layout":"","footnotes":""},"categories":[4],"tags":[387,386,385],"class_list":["entry","author-jonnyquest","post-3114","post","type-post","status-publish","format-standard","category-windows","tag-reset-server-node","tag-sqlexception-execution-timeout-expired","tag-wsus"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.5 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>WSUS - Reset Server Node - SqlException Execution Timeout Expired - ExtraLAN.ru<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/extralan.ru\/?p=3114\" \/>\n<meta property=\"og:locale\" content=\"ru_RU\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"WSUS - Reset Server Node - SqlException Execution Timeout Expired - ExtraLAN.ru\" \/>\n<meta property=\"og:description\" content=\"\u041e\u0445 \u0443\u0436 \u044d\u0442\u043e\u0442 WSUS, \u0441\u0442\u043e\u043b\u044c\u043a\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u044a\u0435\u043b \u0437\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u0443\u044e \u0441 \u043d\u0438\u043c 15 \u043b\u0435\u0442\u043d\u044e\u044e \u0436\u0438\u0437\u043d\u044c. \u0412 \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0439 \u0440\u0430\u0437 \u0411\u0414 SUSDB \u0440\u0430\u0437\u0440\u043e\u0441\u043b\u0430\u0441\u044c \u0434\u043e 52GB, \u043e\u0447\u0438\u0441\u0442\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0447\u0435\u0440\u0435\u0437 MMC \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0438 \u043f\u0440\u0435\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c System.Data.SqlClient.SqlException &#8212; Execution Timeout Expired. Invoke-WsusServerCleanup -CleanupObsoleteUpdates \u043e\u0431\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0442\u0430\u043a\u0438\u043c \u0436\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c \u0438 \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f. \u0421\u0430\u043c\u0430 \u0411\u0414 WSUS \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0430&hellip;\" \/>\n<meta property=\"og:url\" content=\"https:\/\/extralan.ru\/?p=3114\" \/>\n<meta property=\"og:site_name\" content=\"ExtraLAN.ru\" \/>\n<meta property=\"article:published_time\" content=\"2023-12-21T13:25:00+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2023-12-21T13:41:05+00:00\" \/>\n<meta name=\"author\" content=\"Jonny Quest\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"\u041d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u0430\u0432\u0442\u043e\u0440\u043e\u043c\" \/>\n\t<meta name=\"twitter:data1\" content=\"Jonny Quest\" \/>\n\t<meta name=\"twitter:label2\" content=\"\u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 \u043c\u0438\u043d\u0443\u0442\u044b\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebPage\",\"@id\":\"https:\/\/extralan.ru\/?p=3114\",\"url\":\"https:\/\/extralan.ru\/?p=3114\",\"name\":\"WSUS - Reset Server Node - SqlException Execution Timeout Expired - ExtraLAN.ru\",\"isPartOf\":{\"@id\":\"https:\/\/extralan.ru\/#website\"},\"datePublished\":\"2023-12-21T13:25:00+00:00\",\"dateModified\":\"2023-12-21T13:41:05+00:00\",\"author\":{\"@id\":\"https:\/\/extralan.ru\/#\/schema\/person\/32aebde038afaea65ab6c7300a21a53f\"},\"breadcrumb\":{\"@id\":\"https:\/\/extralan.ru\/?p=3114#breadcrumb\"},\"inLanguage\":\"ru-RU\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/extralan.ru\/?p=3114\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/extralan.ru\/?p=3114#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430\",\"item\":\"https:\/\/extralan.ru\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"WSUS &#8212; Reset Server Node &#8212; SqlException Execution Timeout Expired\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/extralan.ru\/#website\",\"url\":\"https:\/\/extralan.ru\/\",\"name\":\"ExtraLAN.ru\",\"description\":\"\u0420\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u0437\u0430\u043c\u0435\u0442\u043a\u0438 \u043f\u043e \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/extralan.ru\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"ru-RU\"},{\"@type\":\"Person\",\"@id\":\"https:\/\/extralan.ru\/#\/schema\/person\/32aebde038afaea65ab6c7300a21a53f\",\"name\":\"Jonny Quest\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"ru-RU\",\"@id\":\"https:\/\/extralan.ru\/#\/schema\/person\/image\/\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/46b63f8ca4df27c7c4733a8790610b5b?s=96&d=mm&r=g\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/46b63f8ca4df27c7c4733a8790610b5b?s=96&d=mm&r=g\",\"caption\":\"Jonny Quest\"},\"url\":\"https:\/\/extralan.ru\/?author=1\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"WSUS - Reset Server Node - SqlException Execution Timeout Expired - ExtraLAN.ru","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/extralan.ru\/?p=3114","og_locale":"ru_RU","og_type":"article","og_title":"WSUS - Reset Server Node - SqlException Execution Timeout Expired - ExtraLAN.ru","og_description":"\u041e\u0445 \u0443\u0436 \u044d\u0442\u043e\u0442 WSUS, \u0441\u0442\u043e\u043b\u044c\u043a\u043e \u0432\u0440\u0435\u043c\u0435\u043d\u0438 \u0441\u044a\u0435\u043b \u0437\u0430 \u0441\u043e\u0432\u043c\u0435\u0441\u0442\u043d\u0443\u044e \u0441 \u043d\u0438\u043c 15 \u043b\u0435\u0442\u043d\u044e\u044e \u0436\u0438\u0437\u043d\u044c. \u0412 \u043e\u0447\u0435\u0440\u0435\u0434\u043d\u043e\u0439 \u0440\u0430\u0437 \u0411\u0414 SUSDB \u0440\u0430\u0437\u0440\u043e\u0441\u043b\u0430\u0441\u044c \u0434\u043e 52GB, \u043e\u0447\u0438\u0441\u0442\u043a\u0430 \u0441\u0435\u0440\u0432\u0435\u0440\u0430 \u0447\u0435\u0440\u0435\u0437 MMC \u043a\u043e\u043d\u0441\u043e\u043b\u044c \u043d\u0435 \u0440\u0430\u0431\u043e\u0442\u0430\u0435\u0442 \u0434\u043e \u043a\u043e\u043d\u0446\u0430 \u0438 \u043f\u0440\u0435\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c System.Data.SqlClient.SqlException &#8212; Execution Timeout Expired. Invoke-WsusServerCleanup -CleanupObsoleteUpdates \u043e\u0431\u0440\u044b\u0432\u0430\u0435\u0442\u0441\u044f \u0441 \u0430\u0431\u0441\u043e\u043b\u044e\u0442\u043d\u043e \u0442\u0430\u043a\u0438\u043c \u0436\u0435 \u0441\u043e\u043e\u0431\u0449\u0435\u043d\u0438\u0435\u043c \u0438 \u0432\u0440\u0435\u043c\u0435\u043d\u0435\u043c \u0432\u044b\u043f\u043e\u043b\u043d\u0435\u043d\u0438\u044f. \u0421\u0430\u043c\u0430 \u0411\u0414 WSUS \u0440\u0430\u0441\u043f\u043e\u043b\u043e\u0436\u0435\u043d\u0430&hellip;","og_url":"https:\/\/extralan.ru\/?p=3114","og_site_name":"ExtraLAN.ru","article_published_time":"2023-12-21T13:25:00+00:00","article_modified_time":"2023-12-21T13:41:05+00:00","author":"Jonny Quest","twitter_card":"summary_large_image","twitter_misc":{"\u041d\u0430\u043f\u0438\u0441\u0430\u043d\u043e \u0430\u0432\u0442\u043e\u0440\u043e\u043c":"Jonny Quest","\u041f\u0440\u0438\u043c\u0435\u0440\u043d\u043e\u0435 \u0432\u0440\u0435\u043c\u044f \u0434\u043b\u044f \u0447\u0442\u0435\u043d\u0438\u044f":"2 \u043c\u0438\u043d\u0443\u0442\u044b"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"WebPage","@id":"https:\/\/extralan.ru\/?p=3114","url":"https:\/\/extralan.ru\/?p=3114","name":"WSUS - Reset Server Node - SqlException Execution Timeout Expired - ExtraLAN.ru","isPartOf":{"@id":"https:\/\/extralan.ru\/#website"},"datePublished":"2023-12-21T13:25:00+00:00","dateModified":"2023-12-21T13:41:05+00:00","author":{"@id":"https:\/\/extralan.ru\/#\/schema\/person\/32aebde038afaea65ab6c7300a21a53f"},"breadcrumb":{"@id":"https:\/\/extralan.ru\/?p=3114#breadcrumb"},"inLanguage":"ru-RU","potentialAction":[{"@type":"ReadAction","target":["https:\/\/extralan.ru\/?p=3114"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/extralan.ru\/?p=3114#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"\u0413\u043b\u0430\u0432\u043d\u0430\u044f \u0441\u0442\u0440\u0430\u043d\u0438\u0446\u0430","item":"https:\/\/extralan.ru\/"},{"@type":"ListItem","position":2,"name":"WSUS &#8212; Reset Server Node &#8212; SqlException Execution Timeout Expired"}]},{"@type":"WebSite","@id":"https:\/\/extralan.ru\/#website","url":"https:\/\/extralan.ru\/","name":"ExtraLAN.ru","description":"\u0420\u0430\u0437\u043b\u0438\u0447\u043d\u044b\u0435 \u0437\u0430\u043c\u0435\u0442\u043a\u0438 \u043f\u043e \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0438\u0440\u043e\u0432\u0430\u043d\u0438\u044e","potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/extralan.ru\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"ru-RU"},{"@type":"Person","@id":"https:\/\/extralan.ru\/#\/schema\/person\/32aebde038afaea65ab6c7300a21a53f","name":"Jonny Quest","image":{"@type":"ImageObject","inLanguage":"ru-RU","@id":"https:\/\/extralan.ru\/#\/schema\/person\/image\/","url":"https:\/\/secure.gravatar.com\/avatar\/46b63f8ca4df27c7c4733a8790610b5b?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/46b63f8ca4df27c7c4733a8790610b5b?s=96&d=mm&r=g","caption":"Jonny Quest"},"url":"https:\/\/extralan.ru\/?author=1"}]}},"_links":{"self":[{"href":"https:\/\/extralan.ru\/index.php?rest_route=\/wp\/v2\/posts\/3114"}],"collection":[{"href":"https:\/\/extralan.ru\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/extralan.ru\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/extralan.ru\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/extralan.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=3114"}],"version-history":[{"count":3,"href":"https:\/\/extralan.ru\/index.php?rest_route=\/wp\/v2\/posts\/3114\/revisions"}],"predecessor-version":[{"id":3118,"href":"https:\/\/extralan.ru\/index.php?rest_route=\/wp\/v2\/posts\/3114\/revisions\/3118"}],"wp:attachment":[{"href":"https:\/\/extralan.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=3114"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/extralan.ru\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=3114"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/extralan.ru\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=3114"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}