{"id":158943,"date":"2012-11-16T16:57:03","date_gmt":"2012-11-16T12:57:03","guid":{"rendered":"http:\/\/savepearlharbor.com\/?p=158943"},"modified":"-0001-11-30T00:00:00","modified_gmt":"-0001-11-29T21:00:00","slug":"","status":"publish","type":"post","link":"https:\/\/savepearlharbor.com\/?p=158943","title":{"rendered":"<span class=\"post_title\">\u0422\u043e\u043f 7 Powershell \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u043e\u0432 \u0434\u043b\u044f \u043d\u043e\u0432\u0438\u0447\u043a\u043e\u0432<\/span>"},"content":{"rendered":"<div class=\"content html_format\">       \u041d\u0430\u0432\u0435\u0440\u043d\u043e\u0435, \u0432\u0441\u0435 \u0441\u043b\u044b\u0448\u0430\u043b\u0438 \u043e PowerShell, \u043d\u043e \u043d\u0430\u0432\u0435\u0440\u043d\u044f\u043a\u0430 \u043d\u0435 \u0432\u0441\u0435\u043c \u0434\u043e\u0432\u0435\u043b\u043e\u0441\u044c \u0441 \u043d\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c. \u0414\u043b\u044f \u0442\u0435\u0445, \u043a\u0442\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442 \u043f\u0440\u043e\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0442\u044c \u0441\u0432\u043e\u0439 \u043f\u0443\u0442\u044c \u0432 \u0434\u0435\u0431\u0440\u0438 PowerShell, \u043c\u044b \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u043c \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u043f\u043e\u0441\u0442\u0430, \u0432\u044b\u0448\u0435\u0434\u0448\u0435\u0433\u043e \u043d\u0430 \u043f\u043e\u0440\u0442\u0430\u043b\u0435 <a href=\"http:\/\/4sysops.com\/archives\/top-7-powershell-commands-for-beginners\/\">4sysops.com<\/a>. \u0412 \u043d\u0435\u043c \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u043d\u043e \u043e 7 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u0445, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043c\u043e\u0433\u0443\u0442 \u0442\u0435\u043c, \u043a\u0442\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0430\u043b \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 PowerShell. \u0417\u0430 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e\u0441\u0442\u044f\u043c\u0438 \u2013 \u0434\u043e\u0431\u0440\u043e \u043f\u043e\u0436\u0430\u043b\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0434 \u043a\u0430\u0442.<br \/>  <a name=\"habracut\"><\/a><\/p>\n<h4>GET-HELP<br \/>  <\/h4>\n<p>\u0421\u0430\u043c\u044b\u0439 \u043f\u0435\u0440\u0432\u044b\u0439 \u0438 \u0441\u0430\u043c\u044b\u0439 \u0433\u043b\u0430\u0432\u043d\u044b\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 PowerShell \u2013 \u0432\u044b\u0437\u043e\u0432 \u0441\u043f\u0440\u0430\u0432\u043a\u0438. \u0421 \u043f\u043e\u043c\u043e\u0449\u044c\u044e \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u0430 Get-Help \u043c\u043e\u0436\u043d\u043e \u043f\u0440\u043e\u0432\u0435\u0440\u0438\u0442\u044c \u0441\u0438\u043d\u0442\u0430\u043a\u0441\u0438\u0441, \u043f\u043e\u0441\u043c\u043e\u0442\u0440\u0435\u0442\u044c \u043f\u0440\u0438\u043c\u0435\u0440\u044b \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u043d\u0438\u044f \u0438 \u0434\u0435\u0442\u0430\u043b\u044c\u043d\u043e\u0435 \u043e\u043f\u0438\u0441\u0430\u043d\u0438\u0435 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440\u043e\u0432 \u043b\u044e\u0431\u043e\u0433\u043e PowerShell \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u0430. \u042d\u0442\u043e\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 \u043f\u0440\u0438\u043c\u0435\u0447\u0430\u0442\u0435\u043b\u0435\u043d \u0442\u0435\u043c, \u0447\u0442\u043e \u0432\u044b \u043f\u0440\u043e\u0441\u0442\u043e \u043c\u043e\u0436\u0435\u0442\u0435 \u043d\u0430\u0431\u0440\u0430\u0442\u044c Get-Help Services, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043f\u0438\u0441\u043e\u043a \u0432\u0441\u0435\u0445 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u0434\u0445\u043e\u0434\u044f\u0442 \u0434\u043b\u044f \u0440\u0430\u0431\u043e\u0442\u044b \u0441\u043e \u0441\u043b\u0443\u0436\u0431\u0430\u043c\u0438. <br \/>  \u041f\u0440\u0438\u043c\u0435\u0440:   <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Help Service <\/code><\/pre>\n<p>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/4be\/ae5\/ce7\/4beae5ce76c2cf9986eec6e03a5594d5.jpg\"\/><\/p>\n<p>  \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0432\u044b\u0431\u0440\u0430\u0442\u044c \u043b\u044e\u0431\u043e\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 \u0438\u0437 \u0441\u043f\u0438\u0441\u043a\u0430, \u0432\u044b\u0432\u0435\u0434\u0435\u043d\u043d\u043e\u0433\u043e \u043f\u043e \u0437\u0430\u043f\u0440\u043e\u0441\u0443 \u0432\u044b\u0448\u0435, \u0447\u0442\u043e\u0431\u044b \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0441\u043f\u0440\u0430\u0432\u043a\u0443 \u043e \u043d\u0435\u043c. \u041d\u0430\u043f\u0440\u0438\u043c\u0435\u0440,  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Help -Name Get-Service  <\/code><\/pre>\n<p>  \u0412\u044b \u043f\u043e\u043b\u0443\u0447\u0430\u0435\u0442\u0435 \u0432\u0441\u044e \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u0435 Get-Service (\u0431\u0443\u0434\u0435\u0442 \u0440\u0430\u0441\u0441\u043c\u043e\u0442\u0440\u0435\u043d \u043d\u0438\u0436\u0435).<br \/>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/7b1\/37f\/f16\/7b137ff16c28dd1caea8aea8306e7938.jpg\"\/><\/p>\n<h4>GET-CONTENT<\/h4>\n<p>  \u0427\u0442\u0435\u043d\u0438\u0435 \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0433\u043e \u0444\u0430\u0439\u043b\u043e\u0432 \u2013 \u043d\u0430\u0438\u0431\u043e\u043b\u0435\u0435 \u0447\u0430\u0441\u0442\u043e\u0435 \u0442\u0440\u0435\u0431\u043e\u0432\u0430\u043d\u0438\u0435 \u0434\u043b\u044f \u043d\u043e\u0432\u0438\u0447\u043a\u043e\u0432, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u044b\u0442\u0430\u044e\u0442\u0441\u044f \u0432\u044b\u0443\u0447\u0438\u0442\u044c PowerShell. \u041f\u0440\u043e\u0446\u0435\u0434\u0443\u0440\u0430 \u0447\u0442\u0435\u043d\u0438\u044f \u0444\u0430\u0439\u043b\u043e\u0432 \u0441 PowerShell \u0443\u043f\u0440\u043e\u0449\u0430\u0435\u0442\u0441\u044f. \u0414\u0430\u0436\u0435 \u043d\u0435\u0441\u043f\u0435\u0446\u0438\u0430\u043b\u0438\u0441\u0442 \u043c\u043e\u0436\u0435\u0442 \u0447\u0438\u0442\u0430\u0442\u044c \u0441\u043e\u0434\u0435\u0440\u0436\u0438\u043c\u043e\u0435 \u0444\u0430\u0439\u043b\u0430, \u043f\u0440\u043e\u0441\u0442\u043e \u043f\u0435\u0440\u0435\u0434\u0430\u0432 \u0435\u0433\u043e \u0432 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 Get-Content.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440.   <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Content C:\\scripts\\Computers.txt mytestpc1 techibee.com dummynotresolvinghost.com PS C:\\&gt; <\/code><\/pre>\n<p>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/40f\/0d7\/0a6\/40f0d70a60d7d013d2a85dd4e477eb7c.jpg\"\/><\/p>\n<p>  \u041d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0431\u043e\u043b\u044c\u0448\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u0435? \u0412\u043e\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0439\u0442\u0435\u0441\u044c Get-Help:  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Help Get-Content -Detailed  <\/code><\/pre>\n<h4>GET-SERVICE<\/h4>\n<p>  \u042d\u0442\u043e\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 \u043f\u0435\u0440\u0435\u0447\u0438\u0441\u043b\u044f\u0435\u0442 \u0432\u0441\u0435 \u0441\u043b\u0443\u0436\u0431\u044b, \u0443\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u043d\u044b\u0435 \u043d\u0430 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435. \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043a\u043e\u043d\u043a\u0440\u0435\u0442\u043d\u043e\u0439 \u0441\u043b\u0443\u0436\u0431\u0435, \u0441\u043e\u0432\u043e\u043a\u0443\u043f\u043d\u043e\u0441\u0442\u0438 \u0441\u043b\u0443\u0436\u0431 \u0438\u043b\u0438 \u043f\u0440\u043e\u0441\u0442\u043e \u043e\u0431\u043e \u0432\u0441\u0435\u0445 \u0441\u043b\u0443\u0436\u0431\u0430\u0445 \u043d\u0430 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440:  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Service wwansvc, spooler Status Name DisplayName ------ ---- ----------- Running spooler Print Spooler Stopped wwansvc WWAN AutoConfig PS C:\\&gt;    <\/code><\/pre>\n<p>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/5b7\/b0d\/5eb\/5b7b0d5ebb5aa1efa2c31972ec49c14b.jpg\"\/><br \/>  \u0417\u0434\u0435\u0441\u044c \u043c\u044b \u0437\u0430\u043f\u0440\u043e\u0441\u0438\u043b\u0438 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u0434\u0432\u0443\u0445 \u0441\u043b\u0443\u0436\u0431\u0430\u0445 wwansvc \u0438 spooler<br \/>  \u0412\u044b\u0432\u043e\u0434\u0438\u0442\u0441\u044f \u0442\u0430\u0431\u043b\u0438\u0446\u0430 \u0441\u043e \u0441\u0442\u0430\u0442\u0443\u0441\u043e\u043c \u0441\u043b\u0443\u0436\u0431\u044b, \u0435\u0435 \u0438\u043c\u0435\u043d\u0435\u043c \u0438 \u043e\u0442\u043e\u0431\u0440\u0430\u0436\u0430\u0435\u043c\u044b\u043c \u0438\u043c\u0435\u043d\u0435\u043c.<br \/>  \u041c\u044b \u043c\u043e\u0436\u0435\u043c \u0432\u0438\u0434\u0435\u0442\u044c \u0447\u0442\u043e \u0441\u043b\u0443\u0436\u0431\u0430 spooler \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u0430, \u0430 wwansvc \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0435\u043d\u0430<\/p>\n<h4>STOP-SERVICE \u0418 START-SERVICE<br \/>  <\/h4>\n<p>  \u0417\u0430\u043f\u0443\u0441\u043a \u0438 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0441\u043b\u0443\u0436\u0431 \u2013 \u0434\u043e\u0441\u0442\u0430\u0442\u043e\u0447\u043d\u043e \u0432\u0430\u0436\u043d\u044b\u0439 \u043c\u043e\u043c\u0435\u043d\u0442 \u0432 \u0440\u0430\u0431\u043e\u0442\u0435 \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u0430 Windows. \u0412 PowerShell \u0438\u043c\u0435\u044e\u0442\u0441\u044f \u0432\u0441\u0442\u0440\u043e\u0435\u043d\u043d\u044b\u0435 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u044b, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u0443\u043f\u0440\u043e\u0449\u0430\u044e\u0442 \u0440\u0430\u0431\u043e\u0442\u0443 \u0430\u0434\u043c\u0438\u043d\u0438\u0441\u0442\u0440\u0430\u0442\u043e\u0440\u0430, \u043d\u0435 \u0442\u0440\u0435\u0431\u0443\u044f \u043e\u0442\u043a\u0440\u044b\u0442\u0438\u044f \u043a\u043e\u043d\u0441\u043e\u043b\u0438 MMC. \u0418\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u044d\u0442\u0438 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u044b \u0412\u044b \u043c\u043e\u0436\u0435\u0442\u0435 \u043e\u0441\u0442\u0430\u043d\u0430\u0432\u043b\u0438\u0432\u0430\u0442\u044c\/\u0437\u0430\u043f\u0443\u0441\u043a\u0430\u0442\u044c \u0441\u043b\u0443\u0436\u0431\u044b \u043a\u0430\u043a \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0445, \u0442\u0430\u043a \u0438 \u043d\u0430 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0445 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430\u0445. <br \/>  \u041f\u0440\u0438\u043c\u0435\u0440\u044b:<br \/>  <b>\u0417\u0430\u043f\u0443\u0441\u043a\/\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0441\u043b\u0443\u0436\u0431\u044b \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435 (\u043d\u0430 \u043f\u0440\u0438\u043c\u0435\u0440\u0435 \u0441\u043b\u0443\u0436\u0431\u044b spooler):<\/b>  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Stop-Service -Name Spooler PS C:\\&gt; Start-Service -Name Spooler <\/code><\/pre>\n<p>  <b>\u0417\u0430\u043f\u0443\u0441\u043a\/\u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043a\u0430 \u0441\u043b\u0443\u0436\u0431\u044b \u043d\u0430 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435 (spooler):<\/b>  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; $ServiceObj = Get-Service -ComputerName MyPC1 -Name spooler PS C:\\&gt; Stop-Service -InputObj $ServiceObj PS C:\\&gt; Start-Service -InputObj $ServiceObj <\/code><\/pre>\n<h4>GET-PROCESS<br \/>  <\/h4>\n<p>  \u042d\u0442\u043e\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 \u043f\u043e\u0437\u0432\u043e\u043b\u044f\u0435\u0442 \u0431\u044b\u0442\u044c \u0432 \u043a\u0443\u0440\u0441\u0435, \u043a\u0430\u043a\u0438\u0435 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u044b \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u044b \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u044b\u0445 \u0438\u043b\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0445 \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430\u0445. \u041f\u043e\u043a\u0430\u0437\u044b\u0432\u0430\u044e\u0442\u0441\u044f \u0438\u043c\u044f \u0438 ID \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430, \u0430 \u0442\u0430\u043a\u0436\u0435 \u043f\u0443\u0442\u044c \u043a \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u043e\u043c\u0443 \u0444\u0430\u0439\u043b\u0443, \u0438\u043c\u044f \u043a\u043e\u043c\u043f\u0430\u043d\u0438\u0438, \u0432\u0435\u0440\u0441\u0438\u044f \u0438\u0441\u043f\u043e\u043b\u043d\u044f\u0435\u043c\u043e\u0433\u043e \u0444\u0430\u0439\u043b\u0430 \u0438 \u043f\u0430\u043c\u044f\u0442\u044c, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u0435\u043c\u0430\u044f \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u043c. <br \/>  \u041f\u0440\u0438\u043c\u0435\u0440\u044b:<br \/>  <b>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430\u0445, \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u044b\u0445 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435:<\/b><\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Process <\/code><\/pre>\n<p>  <img decoding=\"async\" src=\"http:\/\/habrastorage.org\/storage2\/176\/fbf\/255\/176fbf255651b96d3b5f7b61f123498f.jpg\"\/><\/p>\n<p>  \u0412\u0432\u0435\u0434\u0438\u0442\u0435 \u0441\u043b\u0435\u0434\u0443\u044e\u0449\u0438\u0439 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 \u0434\u043b\u044f \u043f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u044f \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e\u0439 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430\u0445  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Process | Format-List * -Force  <\/code><\/pre>\n<p>  <b>\u041f\u043e\u043b\u0443\u0447\u0435\u043d\u0438\u0435 \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u0438 \u043e \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430\u0445, \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u044b\u0445 \u043d\u0430 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435<\/b>:  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Get-Process -ComputerName MYPC1 | Format-List * -Force  <\/code><\/pre>\n<p>  MYPC1 \u043d\u0435\u043e\u0431\u0445\u043e\u0434\u0438\u043c\u043e \u0437\u0430\u043c\u0435\u043d\u0438\u0442\u044c \u043d\u0430 \u0438\u043c\u044f \u0442\u043e\u0433\u043e \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0430, \u0441 \u043a\u043e\u0442\u043e\u0440\u043e\u0433\u043e \u0432\u044b \u0445\u043e\u0442\u0438\u0442\u0435 \u043f\u043e\u043b\u0443\u0447\u0438\u0442\u044c \u0438\u043d\u0444\u043e\u0440\u043c\u0430\u0446\u0438\u044e \u043e \u0437\u0430\u043f\u0443\u0449\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430\u0445. <\/p>\n<h4>STOP-PROCESS<br \/>  <\/h4>\n<p>  \u042d\u0442\u043e\u0442 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442 \u043e\u0441\u0442\u0430\u043d\u043e\u0432\u043b\u0438\u0432\u0430\u0435\u0442 \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u0438\u043b\u0438 \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435. \u041e\u043d \u0431\u0435\u0440\u0435\u0442 \u0438\u043c\u044f \u0438\u043b\u0438 ID \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u0430 \u0438 \u0437\u0430\u0432\u0435\u0440\u0448\u0430\u0435\u0442 \u044d\u0442\u043e\u0442 \u043f\u0440\u043e\u0446\u0435\u0441\u0441. \u042d\u0442\u043e \u043f\u043e\u043b\u0435\u0437\u043d\u043e \u0432 \u0442\u0435\u0445 \u0441\u043b\u0443\u0447\u0430\u044f\u0445, \u043a\u043e\u0433\u0434\u0430 \u043f\u0440\u0438\u043b\u043e\u0436\u0435\u043d\u0438\u0435 \u043d\u0435 \u043e\u0442\u0432\u0435\u0447\u0430\u0435\u0442.<br \/>  \u041f\u0440\u0438\u043c\u0435\u0440:<br \/>  <b>\u041e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u043f\u0440\u043e\u0446\u0435\u0441\u0441 \u0441 ID 22608 \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435:<\/b>  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Stop-Process -Id 22608 <\/code><\/pre>\n<p>  <b>\u041e\u0441\u0442\u0430\u043d\u043e\u0432\u0438\u0442\u044c \u0432\u0441\u0435 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u044b Excel \u043d\u0430 \u043b\u043e\u043a\u0430\u043b\u044c\u043d\u043e\u043c \u043a\u043e\u043c\u043f\u044c\u044e\u0442\u0435\u0440\u0435:<\/b>  <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; Stop-Process -name excel  <\/code><\/pre>\n<p>  <b>\u0421\u043e\u0432\u0435\u0442<\/b>: \u0425\u043e\u0442\u044f \u0443 \u043a\u043e\u043c\u0430\u043d\u0434\u043b\u0435\u0442\u0430 Stop-Process \u043e\u0442\u0441\u0443\u0442\u0441\u0442\u0432\u0443\u0435\u0442 \u043f\u0430\u0440\u0430\u043c\u0435\u0442\u0440 -ComputerName, \u0412\u044b \u0432\u0441\u0435 \u0440\u0430\u0432\u043d\u043e \u043c\u043e\u0436\u0435\u0442\u0435 \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u043e\u0432\u0430\u0442\u044c \u0435\u0433\u043e \u0434\u043b\u044f \u0437\u0430\u0432\u0435\u0440\u0448\u0435\u043d\u0438\u044f \u0443\u0434\u0430\u043b\u0435\u043d\u043d\u044b\u0445 \u043f\u0440\u043e\u0446\u0435\u0441\u0441\u043e\u0432, \u0438\u0441\u043f\u043e\u043b\u044c\u0437\u0443\u044f \u043f\u0440\u0435\u0434\u043b\u043e\u0436\u0435\u043d\u043d\u044b\u0439 \u043d\u0438\u0436\u0435 \u0441\u043e\u0432\u0435\u0442:   <\/p>\n<pre><code class=\"vbscript\">PS C:\\&gt; $Obj = Get-Process -Name excel -ComputerName MYPC1 PS C:\\&gt; Stop-Process -InputObject $Obj  <\/code><\/pre>\n<p>  <i>\u041a\u043e\u043d\u0435\u0446 \u043f\u0435\u0440\u0435\u0432\u043e\u0434\u0430.<\/i><\/p>\n<p>  P.S. \u0421\u043c\u043e\u0442\u0440\u0438\u0442\u0435 \u0442\u0430\u043a\u0436\u0435 \u0438\u043d\u0442\u0435\u0440\u0435\u0441\u043d\u044b\u0435 \u043f\u043e\u0441\u0442\u044b \u043d\u0430 \u0425\u0430\u0431\u0440\u0435, \u043f\u043e\u0441\u0432\u044f\u0449\u0435\u043d\u043d\u044b\u0435 \u0440\u0430\u0431\u043e\u0442\u0435 \u0441 PowerShell<br \/>  <a href=\"http:\/\/habrahabr.ru\/post\/150149\/\">\u0410\u0443\u0434\u0438\u0442 \u0434\u043e\u0441\u0442\u0443\u043f\u0430 \u043a \u0444\u0430\u0439\u043b\u0430\u043c<\/a><br \/>  \u0410\u0443\u0434\u0438\u0442 Active Directory (\u0427\u0430\u0441\u0442\u044c <a href=\"http:\/\/habrahabr.ru\/post\/147750\/\">1<\/a> \u0438 <a href=\"http:\/\/habrahabr.ru\/post\/150122\/\">2<\/a>)<br \/>  <a href=\"http:\/\/habrahabr.ru\/post\/132591\/\">\u0410\u043a\u0442\u0443\u0430\u043b\u0438\u0437\u0438\u0440\u0443\u0435\u043c \u0443\u0447\u0435\u0442\u043d\u044b\u0435 \u0434\u0430\u043d\u043d\u044b\u0435 Active Directory<\/a><br \/>  <a href=\"http:\/\/habrahabr.ru\/post\/127935\/\">\u0410\u0443\u0434\u0438\u0442 \u0441\u043e\u0437\u0434\u0430\u043d\u0438\u044f \u0443\u0447\u0435\u0442\u043d\u044b\u0445 \u0437\u0430\u043f\u0438\u0441\u0435\u0439 \u0432 AD<\/a>          \t<\/p>\n<div class=\"clear\"><\/div>\n<\/p><\/div>\n<p> \u0441\u0441\u044b\u043b\u043a\u0430 \u043d\u0430 \u043e\u0440\u0438\u0433\u0438\u043d\u0430\u043b \u0441\u0442\u0430\u0442\u044c\u0438 <a href=\"http:\/\/habrahabr.ru\/company\/netwrix\/blog\/158943\/\"> http:\/\/habrahabr.ru\/company\/netwrix\/blog\/158943\/<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<div class=\"content html_format\">       \u041d\u0430\u0432\u0435\u0440\u043d\u043e\u0435, \u0432\u0441\u0435 \u0441\u043b\u044b\u0448\u0430\u043b\u0438 \u043e PowerShell, \u043d\u043e \u043d\u0430\u0432\u0435\u0440\u043d\u044f\u043a\u0430 \u043d\u0435 \u0432\u0441\u0435\u043c \u0434\u043e\u0432\u0435\u043b\u043e\u0441\u044c \u0441 \u043d\u0438\u043c \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c. \u0414\u043b\u044f \u0442\u0435\u0445, \u043a\u0442\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0438\u043d\u0430\u0435\u0442 \u043f\u0440\u043e\u043a\u043b\u0430\u0434\u044b\u0432\u0430\u0442\u044c \u0441\u0432\u043e\u0439 \u043f\u0443\u0442\u044c \u0432 \u0434\u0435\u0431\u0440\u0438 PowerShell, \u043c\u044b \u043f\u0440\u0438\u0432\u043e\u0434\u0438\u043c \u043f\u0435\u0440\u0435\u0432\u043e\u0434 \u043f\u043e\u0441\u0442\u0430, \u0432\u044b\u0448\u0435\u0434\u0448\u0435\u0433\u043e \u043d\u0430 \u043f\u043e\u0440\u0442\u0430\u043b\u0435 <a href=\"http:\/\/4sysops.com\/archives\/top-7-powershell-commands-for-beginners\/\">4sysops.com<\/a>. \u0412 \u043d\u0435\u043c \u0440\u0430\u0441\u0441\u043a\u0430\u0437\u0430\u043d\u043e \u043e 7 \u043a\u043e\u043c\u0430\u043d\u0434\u0430\u0445, \u043a\u043e\u0442\u043e\u0440\u044b\u0435 \u043f\u043e\u043c\u043e\u0433\u0443\u0442 \u0442\u0435\u043c, \u043a\u0442\u043e \u0442\u043e\u043b\u044c\u043a\u043e \u043d\u0430\u0447\u0430\u043b \u0440\u0430\u0431\u043e\u0442\u0430\u0442\u044c \u0441 PowerShell. \u0417\u0430 \u043f\u043e\u0434\u0440\u043e\u0431\u043d\u043e\u0441\u0442\u044f\u043c\u0438 \u2013 \u0434\u043e\u0431\u0440\u043e \u043f\u043e\u0436\u0430\u043b\u043e\u0432\u0430\u0442\u044c \u043f\u043e\u0434 \u043a\u0430\u0442.  <\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[],"tags":[],"class_list":["post-158943","post","type-post","status-publish","format-standard","hentry"],"_links":{"self":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/158943","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=158943"}],"version-history":[{"count":0,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=\/wp\/v2\/posts\/158943\/revisions"}],"wp:attachment":[{"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=158943"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=158943"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/savepearlharbor.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=158943"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}