<?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>Search results for 'app:weblogs' matching tags 'advanced' and 'performance'</title><link>http://powershell.com/cs/search/SearchResults.aspx?q=app:weblogs&amp;tag=advanced,performance&amp;orTags=0&amp;o=DateDescending</link><description>Search results for 'app:weblogs' matching tags 'advanced' and 'performance'</description><dc:language>en-US</dc:language><generator>CommunityServer 2008.5 (Build: 30929.2835)</generator><item><title>2012 Scripting Games Advanced Event 10: Create a CSV Log File</title><link>http://powershell.com/cs/blogs/hey-scriptingguy/archive/2012/04/13/2012-scripting-games-advanced-event-10-create-a-csv-log-file.aspx</link><pubDate>Fri, 13 Apr 2012 05:00:00 GMT</pubDate><guid isPermaLink="false">f421715f-7aba-45f0-8a8d-44de5318a3a7:15955</guid><dc:creator>Anonymous</dc:creator><description>&lt;p&gt;&amp;nbsp;&lt;a href="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-76-18/8203.hsg_2D00_2_2D00_4_2D00_12_2D00_1.png"&gt;&lt;img title="2012 Scripting Games badge" alt="2012 Scripting Games badge" src="http://blogs.technet.com/resized-image.ashx/__size/150x0/__key/communityserver-blogs-components-weblogfiles/00-00-00-76-18/8203.hsg_2D00_2_2D00_4_2D00_12_2D00_1.png" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Summary&lt;/b&gt;: &amp;nbsp;In Advanced Event 10, you want to create a CSV log file of all the counters in the &lt;b&gt;Processor&lt;/b&gt; counter set.&lt;/p&gt;
&lt;p class="TableNum-Title"&gt;&lt;strong&gt;About this event&lt;/strong&gt;&lt;/p&gt;
&lt;table cellspacing="0" cellpadding="0"&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;p class="TableText"&gt;Division&lt;/p&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;p class="TableText"&gt;Advanced&lt;/p&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;p class="TableText"&gt;Date of Event&lt;/p&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;p class="TableText"&gt;4/13/2012 12:01 AM&lt;/p&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
&lt;p class="TableText"&gt;Due Date&lt;/p&gt;
&lt;/td&gt;
&lt;td&gt;
&lt;p class="TableText"&gt;4/20/2012 12:01 AM&lt;/p&gt;
&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;
&lt;h2&gt;Event scenario&lt;/h2&gt;
&lt;p&gt;You are a server admin, and you are concerned about the processor performance of one particular server. You decide to use Windows PowerShell to create a CSV log file of all the counters in the &lt;b&gt;Processor&lt;/b&gt; counter set. You decide to take the counter snapshot at two-second intervals for a total of ten snapshots. You plan to analyze the data in a Microsoft Excel spreadsheet. An acceptable output is shown in the figure that follows. Create the CSV file in the &lt;i&gt;Documents &lt;/i&gt;special folder for the current logged-on user. The file name should be &lt;i&gt;servername_processorCounters.csv.&lt;/i&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://blogs.technet.com/cfs-file.ashx/__key/communityserver-blogs-components-weblogfiles/00-00-00-76-18/0160.adv_2D00_10_2D00_2012.png"&gt;&lt;img src="http://blogs.technet.com/resized-image.ashx/__size/550x0/__key/communityserver-blogs-components-weblogfiles/00-00-00-76-18/0160.adv_2D00_10_2D00_2012.png" alt="Image of command output" title="Image of command output" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;h2&gt;Design points&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Make sure that you include all of the counters for all instances of the processor object.&lt;/li&gt;
&lt;li&gt;Make sure that the saved CSV file is readable from within Microsoft Excel.&lt;/li&gt;
&lt;li&gt;Make sure that you get the number of snapshots with the prescribed time between snapshots.&lt;/li&gt;
&lt;li&gt;This can be a &amp;ldquo;one liner&amp;rdquo; single logical command. Do not write complex, difficult-to-understand script because you will lose points.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;2012 Scripting Games links&lt;/h2&gt;
&lt;p style="padding-left:30px;"&gt;&lt;a href="http://blogs.technet.com/b/heyscriptingguy/archive/2012/02/04/the-2012-windows-powershell-scripting-games-all-links-on-one-page.aspx" target="_blank"&gt;&lt;strong&gt;2012 Scripting Games: All Links on One Page&lt;/strong&gt;&lt;/a&gt;&lt;b&gt;&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;I invite you to follow me on&amp;nbsp;&lt;a href="http://bit.ly/scriptingguystwitter" target="_blank"&gt;Twitter&lt;/a&gt;&amp;nbsp;and&amp;nbsp;&lt;a href="http://bit.ly/scriptingguysfacebook" target="_blank"&gt;Facebook&lt;/a&gt;. If you have any questions, send email to me at&amp;nbsp;&lt;a href="mailto:scripter@microsoft.com"&gt;scripter@microsoft.com&lt;/a&gt;, or post your questions on the&amp;nbsp;&lt;a href="http://bit.ly/scriptingforum" target="_blank"&gt;Official Scripting Guys Forum&lt;/a&gt;. Good luck as you compete in this year&amp;rsquo;s Scripting Games. We wish you well.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Ed Wilson, Microsoft Scripting Guy&lt;/b&gt;&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.technet.com/aggbug.aspx?PostID=3487521" width="1" height="1" alt="" /&gt;</description></item></channel></rss>