<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.iis.net/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/" xmlns:cs="http://blogs.iis.net/"><channel><title>Extending Microsoft.Web.Administration through PowerShell  (Part II)</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx</link><description>In my previous post , I showed you how easy it was to leverage your knowledge of the IIS 7 managed SDK in Windows PowerShell. We loaded the IIS 7 managed assemblies and then traversed the object model to display site information and stop application pools</description><dc:language>en</dc:language><generator>CommunityServer 2007 SP1 (Build: 20510.895)</generator><item><title>PowerShell and IIS 7</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx#2090063</link><pubDate>Fri, 04 Jan 2008 10:06:51 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:2090063</guid><dc:creator>PowerShell for Everyone</dc:creator><description>&lt;p&gt;The introduction of IIS 7 with Windows 2008 brings a managed code (.NET) API for IIS. This means we can administer it through PowerShell. Add the remoting features of V2 and you have a very powerful ...&lt;/p&gt;
&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=2090063" width="1" height="1"&gt;</description></item><item><title>【收藏】本周ASP.NET英文技术文章推荐[12/03 - 12/09]（</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx#1982341</link><pubDate>Wed, 31 Oct 2007 03:08:49 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1982341</guid><dc:creator>Jacky_xu</dc:creator><description>&lt;p&gt;摘要&lt;/p&gt;
&lt;p&gt;昨天诸事不顺，早晨起来肠胃开始不舒服。下午坚持写好本篇推荐文章之后，还没发布居然鬼使神差一般就把草稿删除了？！WindowsLiveWriter处理数据安全方面确实有一套，删除的草稿无论用...&lt;/p&gt;
&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=1982341" width="1" height="1"&gt;</description></item><item><title>IIS7 - post #27 - Powershell &amp; Microsoft IIS Web.administration blog</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx#1531497</link><pubDate>Sun, 14 Jan 2007 05:59:35 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1531497</guid><dc:creator>Steve Schofield Weblog</dc:creator><description>&lt;p&gt;Found this blog by Tobin Titus . Definitely check it out! &lt;a rel="nofollow" target="_new" href="http://blogs.iis.net/tobintitus/archive/2006/11/30/powershell-and-microsoft-web-administration.aspx"&gt;http://blogs.iis.net/tobintitus/archive/2006/11/30/powershell-and-microsoft-web-administration.aspx&lt;/a&gt;&lt;/p&gt;
&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=1531497" width="1" height="1"&gt;</description></item><item><title>re: Extending Microsoft.Web.Administration through PowerShell  (Part II)</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx#1484207</link><pubDate>Sun, 03 Dec 2006 05:47:42 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1484207</guid><dc:creator>TobinTitus</dc:creator><description>&lt;P&gt;I've been playing around with the bugs in my PowerShell code and have made some updates to the article. If you are interested, aside from the problems I listed above, I was not getting good matches because the $args[0] inside the Where-Object statement are not honored. I changed function definition to:&lt;/P&gt;
&lt;DIV style="FONT-FAMILY:courier;"&gt;&lt;STRONG&gt;function findsite { $name=$args[0]; (New-Object Microsoft.Web.Administration.ServerManager).Sites | Where-Object {$_.Name -match $name}; }&lt;/STRONG&gt;&lt;/DIV&gt;
&lt;P&gt;This appears to have fixed the problem.&lt;/P&gt;&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=1484207" width="1" height="1"&gt;</description></item><item><title>I have got the power!!</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx#1483697</link><pubDate>Sat, 02 Dec 2006 05:46:07 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1483697</guid><dc:creator>Server: Microsoft-IIS/7.0\r\n </dc:creator><description>&lt;p&gt;Hehe :) Not just me! You have got the power as well.... to manage IIS via PowerShell. Honestly, I'm not&lt;/p&gt;
&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=1483697" width="1" height="1"&gt;</description></item><item><title>re: Extending Microsoft.Web.Administration through PowerShell  (Part II)</title><link>http://blogs.iis.net/tobintitus/archive/2006/12/01/more-on-iis-7-administration-with-powershell.aspx#1483416</link><pubDate>Fri, 01 Dec 2006 20:47:29 GMT</pubDate><guid isPermaLink="false">50bcf3b4-f6fe-4638-adff-0c150e922e99:1483416</guid><dc:creator>TobinTitus</dc:creator><description>&lt;p&gt;In my haste to get this post out before a meeting, I neglected to make some disclaimers. &amp;nbsp;While the code above is meant as an example of a few things you can do with IIS, this is by no means &amp;quot;production ready&amp;quot;. In fact, I ran into a few problems last night with regards to the global variables. &amp;nbsp;For instance, since we are assigning those variables when PowerShell starts, any changes we make to the objects may not be reflected in our output. &amp;nbsp;The $iissites is a great addition if all we ever do in powershell is view site state. &amp;nbsp;However, consider what would happen if you did the following:&lt;/p&gt;
&lt;p&gt;(findsite default*).Name = &amp;quot;Test&amp;quot;;$iismgr.CommitChanges();&lt;/p&gt;
&lt;p&gt;Doing a search for the &amp;quot;Default Web Site&amp;quot; again would return the same website even though we've renamed it. That's because it still has the old cache. &amp;nbsp;We might be better off defining findsite as:&lt;/p&gt;
&lt;p&gt;function findsite { $iismgr.Sites | Where-Object {$_.Name -match $args[0]} }&lt;/p&gt;
&lt;p&gt;Once again, this is conjecture and I haven't tested the code, so please do not consider this production-ready. Test your scripts thoroughly to validate that they are updating your data properly before you put your reputation behind them!&lt;/p&gt;
&lt;img src="http://blogs.iis.net/aggbug.aspx?PostID=1483416" width="1" height="1"&gt;</description></item></channel></rss>