<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://powershell.com/cs/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>PowerShell for Exchange</title><link>http://powershell.com/cs/forums/203.aspx</link><description>Moderated by PowerShell MVP &lt;a href="http://powershell.com/cs/content/experts.aspx#shay-levy"&gt;Shay Levy&lt;/a&gt;</description><dc:language>en</dc:language><generator>CommunityServer 2008.5 (Build: 30929.2835)</generator><item><title>Re: Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14658.aspx</link><pubDate>Tue, 14 Feb 2012 21:46:10 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14658</guid><dc:creator>RSiddaway</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14658.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14658</wfw:commentRss><description>&lt;p&gt;You are very welcome&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14654.aspx</link><pubDate>Tue, 14 Feb 2012 21:39:34 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14654</guid><dc:creator>jwhite</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14654.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14654</wfw:commentRss><description>&lt;p&gt;This is what I&amp;#39;m looking for.&amp;nbsp; Ill post again if i have issues.&amp;nbsp; Cheers.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14652.aspx</link><pubDate>Tue, 14 Feb 2012 21:38:12 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14652</guid><dc:creator>jwhite</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14652.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14652</wfw:commentRss><description>&lt;p&gt;Wonderful!&amp;nbsp; I&amp;#39;m gonna try that.&amp;nbsp; Cheers.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14646.aspx</link><pubDate>Tue, 14 Feb 2012 18:34:25 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14646</guid><dc:creator>RSiddaway</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14646.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14646</wfw:commentRss><description>&lt;p&gt;To recycle an application pool on IIS 7 - Windows 2008/2008 R2&lt;/p&gt;
&lt;p&gt;Get-WmiObject -Namespace &amp;#39;root\webadministration&amp;#39; -Class ApplicationPool -ComputerName &amp;lt;computer name&amp;gt; ` &lt;br /&gt;-Authentication 6 -Filter &amp;quot;Name=&amp;#39;&amp;lt;application pool name&amp;gt;&amp;#39;&amp;quot; |&lt;br /&gt;Invoke-WmiMethod -Name Recycle&lt;/p&gt;
&lt;p&gt;Run this with elevated privileges&lt;/p&gt;
&lt;p&gt;You only need -Authentication 6&amp;nbsp; if you are accessing IIS remotely&lt;/p&gt;
&lt;p&gt;More detail on this and investigating the structure of WMI in PowerShell and WMI - &lt;a href="http://www.manning.com/siddaway2"&gt;www.manning.com/siddaway2&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14645.aspx</link><pubDate>Tue, 14 Feb 2012 18:09:39 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14645</guid><dc:creator>RSiddaway</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14645.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14645</wfw:commentRss><description>&lt;p&gt;To get a full list of WMI namespaces you need a little bit of recursion&lt;/p&gt;
&lt;p&gt;function get-namespace {&lt;br /&gt;param ([string]$name)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Get-WmiObject -Namespace $name -Class &amp;quot;__NAMESPACE&amp;quot; | foreach {&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &amp;quot;$name\&amp;quot; + $_.Name&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; get-namespace $(&amp;quot;$name\&amp;quot; + $_.Name)&lt;br /&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; }&lt;br /&gt;}&lt;br /&gt;&amp;quot;root&amp;quot;&lt;br /&gt;get-namespace &amp;quot;root&amp;quot;&lt;/p&gt;
&lt;p&gt;This starts at the root namespace and for each namespace in root chaecks for any namespaces and so on&lt;/p&gt;
&lt;p&gt;You need to run it with elevated privileges as the security namespaces will throw an error&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Re: Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14636.aspx</link><pubDate>Tue, 14 Feb 2012 07:34:58 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14636</guid><dc:creator>Thomas Lee</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14636.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14636</wfw:commentRss><description>&lt;p&gt;To get a list of namespaces, do this:&lt;/p&gt;
&lt;p&gt;gwmi&amp;nbsp; -namespace root -class __namespace | ft name&lt;/p&gt;
&lt;p&gt;I do not have the relevant namespace on this machine so I can&amp;#39;t help with the second question.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>Recycling an IIS AppPool in powershell...</title><link>http://powershell.com/cs/forums/thread/14634.aspx</link><pubDate>Tue, 14 Feb 2012 03:50:03 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:14634</guid><dc:creator>jwhite</dc:creator><slash:comments>0</slash:comments><comments>http://powershell.com/cs/forums/thread/14634.aspx</comments><wfw:commentRss>http://powershell.com/cs/forums/commentrss.aspx?SectionID=203&amp;PostID=14634</wfw:commentRss><description>&lt;p&gt;I have put together a script that pulls a list of servers in the array and then tests outlook and owa connectivity to each.&amp;nbsp; I also added a menu that allows a restart of selected services on all servers that show an error in connectivity.&amp;nbsp; &lt;/p&gt;
&lt;p&gt;What im wanting to do is be able to recycle or restart an IIS AppPool within the powershell session.&amp;nbsp; So everytime I run get-wmiobject -class IISApplicationPool -namespace root\MicrosoftIISv2 I get the error:&lt;/p&gt;
&lt;p&gt;&amp;quot;Invalid Namespace&amp;quot;.&amp;nbsp; Anyone know how I can 1. get a list of all the namespaces, and 2. recycle an iisapppool using get-wmiobject in powershell?&amp;nbsp; Thanks..&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>