<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Thomas Maurer (tm) &#187; Windows Powershell</title>
	<atom:link href="http://www.thomasmaurer.ch/tag/windows-powershell/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.thomasmaurer.ch</link>
	<description>Just another private cloud weblog</description>
	<lastBuildDate>Wed, 08 Feb 2012 17:42:29 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>PowerShell 3.0: Show-Command</title>
		<link>http://www.thomasmaurer.ch/2011/11/powershell-3-0-show-command/</link>
		<comments>http://www.thomasmaurer.ch/2011/11/powershell-3-0-show-command/#comments</comments>
		<pubDate>Fri, 18 Nov 2011 07:54:48 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 8]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Windows Server 8]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[PowerShell 3.0]]></category>
		<category><![CDATA[Show-Command]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2896</guid>
		<description><![CDATA[Just a simple note about a new cmdlet in PowerShell 3.0. Show-Command is something very useful if you try out a new PowerShell Command. It shows all the options and possible parameters you have with the cmdlet. Show-Command Get-Childitem &#160;]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/powershell1.png" rel="lightbox[2896]"><img class="aligncenter size-medium wp-image-2607" title="Powershell" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/powershell1-300x95.png" alt="Powershell" width="300" height="95" /></a></p>
<p>Just a simple note about a new cmdlet in PowerShell 3.0. Show-Command is something very useful if you try out a new PowerShell Command. It shows all the options and possible parameters you have with the cmdlet.</p>
<pre>Show-Command Get-Childitem</pre>
<p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/11/Show-Command.png" rel="lightbox[2896]"><img class="aligncenter size-medium wp-image-2897" title="Show-Command" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/11/Show-Command-300x223.png" alt="Show-Command" width="300" height="223" /></a></p>
<p>&nbsp;</p>
<div class="shr-publisher-2896"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/11/powershell-3-0-show-command/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Windows Management Framework 3.0 Community Technology Preview</title>
		<link>http://www.thomasmaurer.ch/2011/09/windows-management-framework-3-0-community-technology-preview/</link>
		<comments>http://www.thomasmaurer.ch/2011/09/windows-management-framework-3-0-community-technology-preview/#comments</comments>
		<pubDate>Mon, 26 Sep 2011 14:56:29 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 7]]></category>
		<category><![CDATA[Windows 8]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Windows Server 2008 R2]]></category>
		<category><![CDATA[Windows Server 8]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[CTP]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[PowerShell 3.0]]></category>
		<category><![CDATA[version]]></category>
		<category><![CDATA[Windows Management Framework]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2603</guid>
		<description><![CDATA[&#160; Some days ago the Microsoft Powershell Team released the Community Technology Preview of the Windows Management Framework 3.0 which includes Windows PowerShell v3. You can download the the CTP1 here and it requires Windows 7 SP1 or Windows Server &#8230; <a href="http://www.thomasmaurer.ch/2011/09/windows-management-framework-3-0-community-technology-preview/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p>&nbsp;</p>
<p><img class="aligncenter size-full wp-image-2607" title="Powershell" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/powershell1.png" alt="Powershell" width="541" height="172" /></p>
<p>Some days ago the Microsoft Powershell Team released the Community Technology Preview of the Windows Management Framework 3.0 which includes Windows PowerShell v3. You can <a title="Windows Management Framework CPT download" href="http://www.microsoft.com/download/en/details.aspx?id=27548" target="_blank">download the the CTP1 here</a> and it requires Windows 7 SP1 or Windows Server 2008 R2 with SP1.</p>
<p>You can use very easy both PowerShell versions sie by site.</p>
<pre>
powershell.exe -Version 3.0

powershell.exe -Version 2.0
</pre>
<p>But the Windows Management Framework 3.0 CTP1 does not only includes PowerShell 3, it also contains new versions of WMI, WinRM and the new Windows PowerShell Webservice.</p>
<h1>Windows PowerShell 3.0</h1>
<ul>
<li><strong>Workflows </strong><br />
Workflows that run long-running activities (in sequence or in parallel) to perform complex, larger management tasks, such as multi-machine application provisioning. Using the Windows Workflow Foundation at the command line, Windows PowerShell workflows are repeatable, parallelizable, interruptible, and recoverable.</li>
<li><strong>Robust Sessions </strong><br />
Robust sessions that automatically recover from network failures and interruptions and allow you to disconnect from the session, shut down the computer, and reconnect from a different computer without interrupting the task.</li>
<li><strong>Scheduled Jobs<br />
</strong>Scheduled jobs that run regularly or in response to an event.</li>
<li><strong>Delegated Administration</strong><br />
Commands that can be executed with a delegated set of credentials so users with limited permissions can run critical jobs</li>
<li><strong>Simplified Language Syntax<br />
</strong>Simplified language syntax that make commands and scripts look a lot less like code and a lot more like natural language.</li>
<li><strong>Cmdlet Discovery</strong><br />
Improved cmdlet discovery and automatic module loading that make it easier to find and run any of the cmdlets installed on your computer.</li>
<li><strong>Show-Command</strong><br />
Show-Command, a cmdlet and ISE Add-On that helps users find the right cmdlet, view its parameters in a dialog box, and run it.</li>
</ul>
<h1>WMI</h1>
<ul>
<li><strong>A new provider development model</strong><br />
This new model brings down the cost of provider development and removes the dependency on COM.</li>
<li><strong>A new MI Client API to perform standard CIM operations. </strong><br />
The API can be used to interact with any standard WsMan + CIMOM implementation, allowing management applications on Windows to manage non-Windows computers.</li>
<li><strong>The ability to write Windows PowerShell cmdlets in native code</strong><br />
The new WMI Provider APIs supports an extended Windows PowerShell semantics API allowing you to provide rich Windows PowerShell semantics. e.g., Verbose, Error, Warning, WhatIf, Confirm, Progress</li>
</ul>
<h1>WinRM</h1>
<ul>
<li><strong>Connections are more robust </strong><br />
Session disconnect and reconnect, with or without client session reconstruction, allows long-running tasks to continue even when the session in which they were started is closed and the client computer is shut down. This feature also allows administrators to reconnect from different computers to check the status of remote running tasks and get results.</li>
<li><strong>Connections are more resilient</strong><br />
In Windows PowerShell 3.0 CTP1, connections can survive short-term network failures; the client-server connection is not severed at the first sign of trouble. If network problems persist, the client is safely disconnected and can reconnect by using the Connect-PSSession or Receive-PSSession cmdlets.</li>
</ul>
<h1>Windows PowerShell Web Service</h1>
<p>Windows PowerShell Web Service enables an administrator to expose a set of PowerShell cmdlets as a RESTful web endpoint accessible via the Open Data Protocol (OData). This provides remote access to invoke cmdlets from both Windows and non-Windows clients.</p>
<p>You can get more Information about the Windows Management Framework 3.0 Community Technology Preview on the <a title="Powershell Team Blo" href="http://blogs.msdn.com/b/powershell/archive/2011/09/20/windows-management-framework-3-0-community-technology-preview-ctp-1-available-for-download.aspx" target="_blank">Windows PowerShell Team Blog</a>.</p>
<div class="shr-publisher-2603"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/09/windows-management-framework-3-0-community-technology-preview/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Hyper-V: &#8220;Version 3 kills them all&#8221;</title>
		<link>http://www.thomasmaurer.ch/2011/09/hyper-v-version-3-kills-them-all/</link>
		<comments>http://www.thomasmaurer.ch/2011/09/hyper-v-version-3-kills-them-all/#comments</comments>
		<pubDate>Mon, 19 Sep 2011 15:12:18 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[Cloud]]></category>
		<category><![CDATA[Hardware]]></category>
		<category><![CDATA[Hyper-V]]></category>
		<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Virtualization]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 8]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[Build]]></category>
		<category><![CDATA[build8]]></category>
		<category><![CDATA[Cluster]]></category>
		<category><![CDATA[Clustering]]></category>
		<category><![CDATA[features]]></category>
		<category><![CDATA[Hyper-V 3]]></category>
		<category><![CDATA[Hypervisor]]></category>
		<category><![CDATA[Microsoft Hyper-v]]></category>
		<category><![CDATA[Microsoft Hyper-V 3]]></category>
		<category><![CDATA[Module]]></category>
		<category><![CDATA[Network]]></category>
		<category><![CDATA[Networking]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[Powershell 3]]></category>
		<category><![CDATA[Storage]]></category>
		<category><![CDATA[Storage Spaces]]></category>
		<category><![CDATA[Virtual Machine]]></category>
		<category><![CDATA[VM]]></category>
		<category><![CDATA[Windows Powershell]]></category>
		<category><![CDATA[Windows Server 8]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2537</guid>
		<description><![CDATA[Microsoft showed the latest version of Hyper-V at build conference together with Windows 8 and Windows Server 8. Microsoft showed a lot of new Hyper-V features which turn Hyper-V in really powerful hypervisor. Some days ago I posted a blog post about new features &#8230; <a href="http://www.thomasmaurer.ch/2011/09/hyper-v-version-3-kills-them-all/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv04.png" rel="lightbox[2537]"><img class="aligncenter size-large wp-image-2574" title="Windows Server 8 Server Manager Dashboard" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv04-1024x859.png" alt="Windows Server 8 Server Manager Dashboard" width="584" height="489" /></a></p>
<p>Microsoft showed the latest version of Hyper-V at <a href="http://www.buildwindows.com" target="_blank">build conference</a> together with Windows 8 and Windows Server 8. Microsoft showed a lot of new Hyper-V features which turn Hyper-V in really powerful hypervisor.</p>
<p>Some days ago I posted a blog post about new features which Microsoft showed before the build conference, now it&#8217;s time to extend the list of new features. There are a lot of even more powerful features than the once <a title="Awesome – Building Windows 8: Hyper-V" href="http://www.thomasmaurer.ch/2011/09/awesome-building-windows-8-hyper-v/" target="_blank">I posted back then</a>.</p>
<h1>Windows Server 8 as Cloud OS</h1>
<p>First let&#8217;s start with Windows Server 8 as the base of Microsoft Cloud strategy. Microsofts focus in Windows Server 8 was to make it easy for all to build public and private cloud solutions. There are a lot of improvements to manageability, security, scalability, extensibility, predictability and reliability which will also improve the possibilities with Hyper-V. In technical terms Microsoft made a lot of improvements how you can manage a lot of servers and services, Storage, Networking and Powershell. Of course there is a lot more, but this are the parts I think are the most important. And here are some keywords to the improvements in Windows Server 8:</p>
<ul>
<li>Storage improvements &#8211; SMB 2.2, SMB transparent Failover, Data deduplication, Storage Spaces, online filesystem repairs, 64TB NTFS volume etc.</li>
<li>NIC Teaming</li>
<li>Powershell v3 &#8211; You can now just do everything in Powershell and even more with 23000 PowerShell cmdlets.</li>
<li>Server Dashboard &#8211; The new Dashboard lets you manage all servers, or even better, all Services from one place.</li>
<li>Multi-tenant &#8211; everything seems to be made for that</li>
<li>Performance Counters</li>
</ul>
<p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv02.png" rel="lightbox[2537]"><img class="aligncenter size-medium wp-image-2575" title="Windows Server 8 Hyper-V Manager" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv02-300x227.png" alt="Windows Server 8 Hyper-V Manager" width="300" height="227" /></a></p>
<h1>Hyper-V Host improvements</h1>
<p>Hyper-V gets not only a lot of improvements to Virtual Machine, also the Hyper-V Hosts get some new limit improvements.</p>
<ul>
<li>up to 160 logical CPUs</li>
<li>supports up to 2TB RAM</li>
<li>no more vCPU:pCPU ration limit</li>
</ul>
<h1>Hyper-V Virtual Machine improvements</h1>
<p>Microsoft did a lot to extend the existing Virtual Machine hardware to support even high workload Virtual Machines. I will not write a lot about this because the facts here will tell more that a lot of words.</p>
<ul>
<li>VHDX Format &#8211; supports up to 16TB Virtual Disks</li>
<li>32 CPUs per VM</li>
<li>512GB RAM per VM</li>
<li>Support for Fibre Channel Adapters</li>
<li>Supporting Virtual Active Directory Servers</li>
</ul>
<h1>Hyper-V Networking improvements</h1>
<p>Hyper-V got a lot of improvements in terms of networking. Microsoft realized that networking features are really important if you start to create private and public cloud scenarios and now even create a mix of public and private cloud scenarios without creating a lot of work for the IT teams to reconfigure Virtual Machines.</p>
<ul>
<li>QoS and flexible bandwidth allocation</li>
<li>Support for SR-IOV (Direct Access to the physical Network adapter)</li>
<li>Network Virtualization</li>
<li>PVLAN support</li>
<li>Dynamic Virtual Machine Queue (D-VMQ)</li>
<li>Receive Side Coalescing (RSC)</li>
<li>DHCP Guard</li>
<li>Extensible virtual switch</li>
<li>IPsec Task offload</li>
</ul>
<h1>Hyper-V Clustering improvements</h1>
<p>Hyper-V gets also a lot of Cluster improvements. But you have to be aware that Clusters are for really high availability and this adds a lot of costs to projects and solutions. Microsoft is working on Cloud solutions which will give great availability to low cost. For example Hyper-V Replica or Live Migration to another host over the Ethernet without the need for a shared storage. But if you need real HA you will need the Failover Cluster.</p>
<ul>
<li>supporting up to 4000 VMs per cluster</li>
<li>supporting up to 63 Cluster nodes</li>
<li>improved Cluster Manager Console</li>
<li>VM Monitoring &#8211; Application health detection inside the virtual machine</li>
<li>New Placement policies &#8211; Virtual Machine Priority and enhanced placement</li>
<li>Storage Live Migration</li>
<li>Hyper-V Replica supporting clustering</li>
<li>No need for Block Storage &#8211; you can use SMB Shares</li>
<li>Support for Storage Spaces</li>
<li>Automated Node Draining &#8211; like Maintenance mode in SCVMM</li>
<li>Cluster Aware Updating</li>
<li>Cluster Shared Volume Improvements &#8211; BitLocker support, a lot of performance improvements, Self-Healing</li>
<li>Live Migration Queing</li>
<li>Migrate multiple Virtual Machine at the same time</li>
</ul>
<p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv03.png" rel="lightbox[2537]"><img class="aligncenter size-medium wp-image-2576" title="Windows Server 8 Hyper-V VM Move" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv03-300x221.png" alt="Windows Server 8 Hyper-V VM Move" width="300" height="221" /></a></p>
<h1>Hyper-V Storage improvements</h1>
<p>A I mentioned earlier Microsoft made a lot of improvements in terms of storage in Windows Server 8 and Hyper-V can take advantage of those which are quiet impressive. For example with the new features in SMB 2.2 you can now use SMB file shares to store your Virtual Machines.</p>
<ul>
<li>VHDX</li>
<li>ODX</li>
<li>RDMA</li>
<li>SMB 2.2 &#8211; Transparent Failover</li>
<li>4K native disk support</li>
<li>Data Deduplication</li>
<li>Virtual Fiber Channel</li>
<li>VM boot from SAN</li>
</ul>
<h1>Hyper-V Management Improvements</h1>
<p>As everywhere in Windows Server 8 PowerShell is the key. And the new Server Manager Dashboard Microsoft enable to create Server Groups to manage multiple servers from a single console.</p>
<ul>
<li>Powershell for Hyper-V</li>
<li>Powershell Workflows &#8211; Commands and Tasks across servers</li>
<li>Hyper-V Extensible Switch &#8211; lets vendors to create &#8220;plugins&#8221;. Could be very interesting for Cisco UCS installations.</li>
<li>Server Manager Dashboard &#8211; lets you manage multiple Hyper-V host from a single console.</li>
<li>SCVMM 2012 &#8211; not a part of Windows Server 8 but will add great management solutions</li>
</ul>
<p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv05powershell.png" rel="lightbox[2537]"><img class="aligncenter size-medium wp-image-2578" title="Windows Server 8 Hyper-V Powershell" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/09/hyperv05powershell-247x300.png" alt="Windows Server 8 Hyper-V Powershell" width="247" height="300" /></a></p>
<h1>Hyper-V HA and Data Protection</h1>
<p>Now I think this is maybe the greatest new feature. You can now live migrate a Virtual Machine from one Hyper-V Host to another without Shared Storage or Cluster configuration. And with this option Microsoft also included a new feature called Hyper-V Replica which includes the option to replicate Virtual Machine to another host which can be hosted in the same network or even in the cloud.</p>
<ul>
<li>Live Migration</li>
<li>Live Storage Migration</li>
<li>Live Migration to another Hosts (Not clustered) over the Ethernet</li>
<li>Hyper-V Replica &#8211; Replicated Virtual Machines to another Hyper-V host on-premise or public cloud</li>
<li>BitLocker support for CSV</li>
</ul>
<p>This are not all of the new features Windows Server 8 Hyper-V has to offer but I tried to list the important ones. And if Microsoft sticks with their licensing model, it will be a really strong competitor to the VMWare vShpere 5.</p>
<p>&nbsp;</p>
<div class="shr-publisher-2537"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/09/hyper-v-version-3-kills-them-all/feed/</wfw:commentRss>
		<slash:comments>9</slash:comments>
		</item>
		<item>
		<title>SCVMM Snapshot Reminder with Powershell</title>
		<link>http://www.thomasmaurer.ch/2011/09/scvmm-snapshot-reminder-with-powershell/</link>
		<comments>http://www.thomasmaurer.ch/2011/09/scvmm-snapshot-reminder-with-powershell/#comments</comments>
		<pubDate>Thu, 08 Sep 2011 14:25:05 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[Hosting]]></category>
		<category><![CDATA[Hyper-V]]></category>
		<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[System Center]]></category>
		<category><![CDATA[System Center Virtual Machine Manager 2012]]></category>
		<category><![CDATA[System Center Virtual Machine Mananger 2008 R2]]></category>
		<category><![CDATA[Virtualization]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Windows Server 2008 R2]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[Checkpoints]]></category>
		<category><![CDATA[E-Mail]]></category>
		<category><![CDATA[Get-VMCheckpoint]]></category>
		<category><![CDATA[Get-VMMServer]]></category>
		<category><![CDATA[Mail]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[Reminder]]></category>
		<category><![CDATA[SCVMM]]></category>
		<category><![CDATA[SCVMM 2008 R2]]></category>
		<category><![CDATA[SCVMM 2012]]></category>
		<category><![CDATA[Snapshots]]></category>
		<category><![CDATA[System Center Virtual Machine Manager]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2504</guid>
		<description><![CDATA[I have created a small Powershell Script which will you remind of existing VM Snapshots. You can use this and create a scheduled task for example each morning and it will send you an email with all existing VM snapshots &#8230; <a href="http://www.thomasmaurer.ch/2011/09/scvmm-snapshot-reminder-with-powershell/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/08/997_13017113876PJ6.jpg" rel="lightbox[2504]"><img class="aligncenter size-medium wp-image-2468" title="Hyper-V" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/08/997_13017113876PJ6-235x300.jpg" alt="Hyper-V" width="235" height="300" /></a></p>
<p>I have created a small Powershell Script which will you remind of existing VM Snapshots. You can use this and create a scheduled task for example each morning and it will send you an email with all existing VM snapshots or checkpoints. The Script uses the Powershell Commands of System Center Virtual Machine Manager 2008 R2 but should also work with System Center Virtual Machine Manager 2012.</p>
<pre>

# Check for Virtual Machine Manager Snapin
$PSSnapin = Get-PSSnapin | Where-Object { $_.Name -eq "Microsoft.SystemCenter.VirtualMachineManager" }
if($PSSnapin -eq $null)
{
	Add-PSSnapin Microsoft.SystemCenter.VirtualMachineManager
}

# Connect to SCVMM Server
Get-VMMServer localhost

# Get Snapshots
$snapshots = Get-VMCheckpoint

# Check for existing Snapshots
if ($snapshots.count -gt 0){

	# Create the List of Snapshots
	$info = $snapshots | Format-Table VM, AddedTime, Name -auto | Out-String 

	# Mail Configuration
	# ==================

 	# Configuration
	$emailFrom = "user@mydomain.com"
 	$emailTo = "user@yourdomain.com"
 	$emailSubject = "VM Snapshot Reminder"
 	$emailMessage = "You have still some snapshots: `n `n" + $info + "`n Greetings your SCVMM Server"
 	$smtpServer = "mail.server.com"
 	$smtpUserName = "username" # This could be also in e-mail address format
 	$smtpPassword = "password"
	$smtpDomain = ""

	# SMTP Object
	$smtp = New-Object System.Net.Mail.SmtpClient($smtpServer)
	$mailCredentials = New-Object System.Net.NetworkCredential
 	$mailCredentials.Domain = $smtpDomain
 	$mailCredentials.UserName = $smtpUserName
 	$mailCredentials.Password = $smtpPassword
 	$smtp.Credentials = $mailCredentials  

 	# Send E-Mail
 	$smtp.Send($emailFrom, $emailTo, $emailSubject, $emailMessage)
 }
</pre>
<div class="shr-publisher-2504"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/09/scvmm-snapshot-reminder-with-powershell/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Send E-Mail from Powershell</title>
		<link>http://www.thomasmaurer.ch/2011/09/send-e-mail-from-powershell/</link>
		<comments>http://www.thomasmaurer.ch/2011/09/send-e-mail-from-powershell/#comments</comments>
		<pubDate>Wed, 07 Sep 2011 14:32:52 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[Credentials]]></category>
		<category><![CDATA[email]]></category>
		<category><![CDATA[Mail]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[Send Mail]]></category>
		<category><![CDATA[SMTP]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2501</guid>
		<description><![CDATA[This is a small script which you can use to send E-Mail from Windows Powershell. This script has an hardcoded password variable because this solution is mostly used for automation. But you could also use the get-credentials command to get &#8230; <a href="http://www.thomasmaurer.ch/2011/09/send-e-mail-from-powershell/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><img class="aligncenter size-medium wp-image-621" title="Powershell Header" src="http://www.thomasmaurer.ch/wp-content/uploads/2010/05/Screen-shot-2010-05-30-at-13.08.42-300x70.png" alt="Powershell Header" width="300" height="70" /></p>
<p>This is a small script which you can use to send E-Mail from Windows Powershell. This script has an hardcoded password variable because this solution is mostly used for automation. But you could also use the get-credentials command to get the credentials from a user.</p>
<pre>
# Configuration
$emailFrom = "user@mydomain.com"
$emailTo = "user@yourdomain.com"
$emailSubject = "my subject"
$emailMessage = "my message"
$smtpServer = "mail.server.com"
$smtpUserName = "username" # This could be also in e-mail address format
$smtpPassword = "password"
$smtpDomain = ""

# SMTP Object
$smtp = New-Object System.Net.Mail.SmtpClient($smtpServer)
$mailCredentials = New-Object System.Net.NetworkCredential
$mailCredentials.Domain = $smtpDomain
$mailCredentials.UserName = $smtpUserName
$mailCredentials.Password = $smtpPassword
$smtp.Credentials = $mailCredentials

# Send E-Mail
$smtp.Send($emailFrom, $emailTo, $emailSubject, $emailMessage)
</pre>
<p>Update:</p>
<p>Thanks to <a href="http://jdhitsolutions.com/blog/" target="_blank">Jeffery Hicks</a> for correcting me, since Powershell v2 there is a much easier way to send a Mail with the Send-MailMessage cmdlet. <a href="http://go.microsoft.com/fwlink/?LinkID=135256">http://go.microsoft.com/fwlink/?LinkID=135256</a></p>
<p>&nbsp;</p>
<div class="shr-publisher-2501"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/09/send-e-mail-from-powershell/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Powershell: Copy files and additional files with different name</title>
		<link>http://www.thomasmaurer.ch/2011/07/powershell-copy-files-and-additional-files-with-different-name/</link>
		<comments>http://www.thomasmaurer.ch/2011/07/powershell-copy-files-and-additional-files-with-different-name/#comments</comments>
		<pubDate>Tue, 26 Jul 2011 12:41:24 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[Copy Files]]></category>
		<category><![CDATA[file]]></category>
		<category><![CDATA[files]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[Select-String]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2384</guid>
		<description><![CDATA[This maybe helps some people which need to copy mutiple files. In my example I search for Contoso in files called info_*****.txt I need to copy them and also copy the file data_*****.txt. $sourceFolder = "E:\temp\source" $destinationFolder = "E:\temp\folder1" $files &#8230; <a href="http://www.thomasmaurer.ch/2011/07/powershell-copy-files-and-additional-files-with-different-name/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><img class="aligncenter size-medium wp-image-621" title="Powershell Header" src="http://www.thomasmaurer.ch/wp-content/uploads/2010/05/Screen-shot-2010-05-30-at-13.08.42-300x70.png" alt="Powershell Header" width="300" height="70" /></p>
<p>This maybe helps some people which need to copy mutiple files. In my example I search for Contoso in files called info_*****.txt I need to copy them and also copy the file data_*****.txt.</p>
<pre>
$sourceFolder = "E:\temp\source"
$destinationFolder = "E:\temp\folder1"

$files = Get-ChildItem $sourceFolder -Filter *.txt -Recurse | Select-String "Contoso" # Get all Files with Contoso
Write-Host "Files found: " $files.count # Number of files found
foreach ($file in $files){
Get-Childitem $sourceFolder | Where-Object { $_.name -eq $file.filename } | Copy-Item -Destination $destinationFolder # copy all info_*****.txt files
$name = $file.filename -replace "info_", "data_"
Get-Childitem $sourceFolder | Where-Object { $_.name -eq $name } | Copy-Item -Destination $destinationFolder # copy all data_*****.txt files
}
</pre>
<p>More Infos about <a title="Powershell: Search for String or grep for Powershell" href="http://www.thomasmaurer.ch/2011/03/powershell-search-for-string-or-grep-for-powershell/">Select-String</a> and <a title="Powershell: Copy Logfiles with Date and Content" href="http://www.thomasmaurer.ch/2011/04/powershell-copy-logfiles-with-date-and-content/">file copy</a></p>
<div class="shr-publisher-2384"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/07/powershell-copy-files-and-additional-files-with-different-name/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Office 365 &#8211; How to connect with Powershell</title>
		<link>http://www.thomasmaurer.ch/2011/07/office-365-how-to-connect-with-powershell/</link>
		<comments>http://www.thomasmaurer.ch/2011/07/office-365-how-to-connect-with-powershell/#comments</comments>
		<pubDate>Thu, 07 Jul 2011 13:52:45 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[Cloud]]></category>
		<category><![CDATA[Hosting]]></category>
		<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Office365]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[connect]]></category>
		<category><![CDATA[Module]]></category>
		<category><![CDATA[MsOnline]]></category>
		<category><![CDATA[Office]]></category>
		<category><![CDATA[Office 365]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2332</guid>
		<description><![CDATA[In Office 365 you can do and automate a lot with Windows Powershell. Now this small post shows you how you can connect to Office 365 with Powershell. Install the Microsoft Online Services Sign-In Assistant 32-bit 64-bit Install the Microsoft &#8230; <a href="http://www.thomasmaurer.ch/2011/07/office-365-how-to-connect-with-powershell/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><a href="http://www.thomasmaurer.ch/wp-content/uploads/2011/07/office365-powershell.png" rel="lightbox[2332]"><img src="http://www.thomasmaurer.ch/wp-content/uploads/2011/07/office365-powershell-300x171.png" alt="office365 powershell" title="office365 powershell" width="300" height="171" class="aligncenter size-medium wp-image-2334" /></a></p>
<p>In Office 365 you can do and automate a lot with Windows Powershell. Now this small post shows you how you can connect to Office 365 with Powershell.</p>
<ol>
<li>Install the Microsoft Online Services Sign-In Assistant<br />
<a href="http://g.microsoftonline.com/0bd00en-us/568" target="_blank">32-bit</a><br />
<a href="http://g.microsoftonline.com/0bd00en-us/569" target="_blank">64-bit</a></li>
<li>Install the Microsoft Online Services Module for Windows PowerShell<br />
<a href="http://g.microsoftonline.com/0BX10EN/230" target="_blank">32-bit</a><br />
<a href="http://g.microsoftonline.com/0BX10EN/423" target="_blank">64-bit</a></li>
<li>Open Powershell and import the MsOnline Module or use the desktop shortcut which was created by the installer.
<pre>Import-Module MsOnline</pre>
</li>
<li>Connect to your Microsoft Office 365 account
<pre>Connect-MsolService</pre>
<p>Use your Office 365 LiveID to login (for example <a href="mailto:bob@bobscompany.onmicrosoft.com">bob@bobscompany.onmicrosoft.com</a>)</li>
<li>Now you can start working with Windows Powershell in your Office 365 account, if you need some more help about the available Powershell cmdlets you can list them with
<pre>Get-Command -Module MsOnline</pre>
</li>
</ol>
<div class="shr-publisher-2332"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/07/office-365-how-to-connect-with-powershell/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Powershell: How to export Windows Eventlogs with Powershell</title>
		<link>http://www.thomasmaurer.ch/2011/05/powershell-how-to-export-windows-eventlogs-with-powershell/</link>
		<comments>http://www.thomasmaurer.ch/2011/05/powershell-how-to-export-windows-eventlogs-with-powershell/#comments</comments>
		<pubDate>Thu, 26 May 2011 15:14:26 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[Events]]></category>
		<category><![CDATA[Hyper-V]]></category>
		<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Server Core]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows 7]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Windows Server 2003]]></category>
		<category><![CDATA[Windows Server 2008]]></category>
		<category><![CDATA[Windows Server 2008 R2]]></category>
		<category><![CDATA[Windows Vista]]></category>
		<category><![CDATA[Windows XP]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[.evt]]></category>
		<category><![CDATA[Application]]></category>
		<category><![CDATA[Backup]]></category>
		<category><![CDATA[Backupeventlog]]></category>
		<category><![CDATA[cleanup]]></category>
		<category><![CDATA[Delete]]></category>
		<category><![CDATA[Eventlog]]></category>
		<category><![CDATA[Eventlogs]]></category>
		<category><![CDATA[Export]]></category>
		<category><![CDATA[export eventlog]]></category>
		<category><![CDATA[Extension]]></category>
		<category><![CDATA[logfile]]></category>
		<category><![CDATA[logfiles]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[ps]]></category>
		<category><![CDATA[Remove]]></category>
		<category><![CDATA[System]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=2142</guid>
		<description><![CDATA[This is a little dirty Windows Powershell script which exports or backups Windows Eventlogs. The script creates a .evt file which can be used with the Windows Eventlog Viewer. # Config $logFileName = "Application" # Add Name of the Logfile &#8230; <a href="http://www.thomasmaurer.ch/2011/05/powershell-how-to-export-windows-eventlogs-with-powershell/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><img class="aligncenter" title="Powershell Header" src="http://www.thomasmaurer.ch/wp-content/uploads/2010/05/Screen-shot-2010-05-30-at-13.08.42.png" alt="Powershell Header" width="440" height="104" /></p>
<p>This is a little dirty Windows Powershell script which exports or backups Windows Eventlogs. The script creates a .evt file which can be used with the Windows Eventlog Viewer.</p>
<pre>
# Config
$logFileName = "Application" # Add Name of the Logfile (System, Application, etc)
$path = "C:\temp\" # Add Path, needs to end with a backsplash

# do not edit
$exportFileName = $logFileName + (get-date -f yyyyMMdd) + ".evt"
$logFile = Get-WmiObject Win32_NTEventlogFile | Where-Object {$_.logfilename -eq $logFileName}
$logFile.backupeventlog($path + $exportFileName)
</pre>
<p>And with the next code it cleans up older exported Eventlogs.</p>
<pre>
# Deletes all .evt logfiles in $path
# Be careful, this script removes all files with the extension .evt not just the selfcreated logfiles
$Daysback = "-7"

$CurrentDate = Get-Date
$DatetoDelete = $CurrentDate.AddDays($Daysback)
Get-ChildItem $Path | Where-Object { ($_.LastWriteTime -lt $DatetoDelete) -and ($_.Extension -eq ".evt") } | Remove-Item
</pre>
<p><strong>UPDATE:</strong> If you wanna clean the Eventlog after the export you can do that by using the Clear-Eventlog cmdlet. (Thanks to Michel from <a href="http://www.server-talk.eu">server-talk.eu</a>)</p>
<pre>
Clear-Eventlog -LogName $logFileName
</pre>
<p>And here the whole &#8220;script&#8221;</p>
<pre>
# Config
$logFileName = "Application" # Add Name of the Logfile (System, Application, etc)
$path = "C:\temp\" # Add Path, needs to end with a backsplash

# do not edit
$exportFileName = $logFileName + (get-date -f yyyyMMdd) + ".evt"
$logFile = Get-WmiObject Win32_NTEventlogFile | Where-Object {$_.logfilename -eq $logFileName}
$logFile.backupeventlog($path + $exportFileName)

# Deletes all .evt logfiles in $path
# Be careful, this script removes all files with the extension .evt not just the selfcreated logfiles
$Daysback = "-7"

$CurrentDate = Get-Date
$DatetoDelete = $CurrentDate.AddDays($Daysback)
Get-ChildItem $Path | Where-Object { ($_.LastWriteTime -lt $DatetoDelete) -and ($_.Extension -eq ".evt") } | Remove-Item
Clear-Eventlog -LogName $logFileName
</pre>
<div class="shr-publisher-2142"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/05/powershell-how-to-export-windows-eventlogs-with-powershell/feed/</wfw:commentRss>
		<slash:comments>5</slash:comments>
		</item>
		<item>
		<title>Microsoft Office 365</title>
		<link>http://www.thomasmaurer.ch/2011/05/microsoft-office-365/</link>
		<comments>http://www.thomasmaurer.ch/2011/05/microsoft-office-365/#comments</comments>
		<pubDate>Mon, 09 May 2011 14:36:00 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[Cloud]]></category>
		<category><![CDATA[Exchange Server]]></category>
		<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Office]]></category>
		<category><![CDATA[Office365]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Sharepoint]]></category>
		<category><![CDATA[Sharepoint 2010]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Web]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[Beta]]></category>
		<category><![CDATA[Exchange]]></category>
		<category><![CDATA[Exchange Online]]></category>
		<category><![CDATA[Lync]]></category>
		<category><![CDATA[Lync Online]]></category>
		<category><![CDATA[Microsoft Office]]></category>
		<category><![CDATA[Microsoft Office 365]]></category>
		<category><![CDATA[Office 365]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[SharePoint Online]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=1927</guid>
		<description><![CDATA[In the last days I started to work with the Microsoft beta of Office 365. After testing it for a while I think this could be a great solution for small &#38; medium businesses. And its a really hard competitor &#8230; <a href="http://www.thomasmaurer.ch/2011/05/microsoft-office-365/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p style="text-align: center;"><img class="aligncenter size-full wp-image-1928" title="office365" src="http://www.thomasmaurer.ch/wp-content/uploads/2011/05/office365.jpg" alt="office365" width="418" height="250" /></p>
<p style="text-align: left;">In the last days I started to work with the <a title="Office365" href="http://www.office365.com" target="_blank">Microsoft beta of Office 365</a>. After testing it for a while I think this could be a great solution for small &amp; medium businesses. And its a really hard competitor to Google Apps. There are a lot of advantage which Office 365 has agains Google Apps and I think because it is a Microsoft Solution for a lot of companys this is the better way to go, if they already used Microsoft Products or have a Microsoft enviroment.</p>
<ul>
<li>
<div style="text-align: left;">More options and features instead of  Google Apps, for example in Exchange or Forfront which protects Exchange and SharePoint Online for free.</div>
</li>
<li>
<div style="text-align: left;">Microsoft Solutions &#8211; the most people and companys already use them.</div>
</li>
<li>
<div style="text-align: left;">Powershell - This is a really cool feature. You can administrate  the whole Office365 online serivce with Windows Powershell.</div>
</li>
</ul>
<p style="text-align: left;">In the next few weeks I will post some blog post about how to use Office 365 and some Powershell How To posts.</p>
<div class="shr-publisher-1927"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/05/microsoft-office-365/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		</item>
		<item>
		<title>Powershell: Create a tempfile with Powershell</title>
		<link>http://www.thomasmaurer.ch/2011/04/powershell-create-a-tempfile-with-powershell/</link>
		<comments>http://www.thomasmaurer.ch/2011/04/powershell-create-a-tempfile-with-powershell/#comments</comments>
		<pubDate>Tue, 26 Apr 2011 14:45:01 +0000</pubDate>
		<dc:creator>Thomas Maurer</dc:creator>
				<category><![CDATA[IT]]></category>
		<category><![CDATA[Microsoft]]></category>
		<category><![CDATA[Powershell]]></category>
		<category><![CDATA[Software]]></category>
		<category><![CDATA[Windows]]></category>
		<category><![CDATA[Windows Server]]></category>
		<category><![CDATA[Work]]></category>
		<category><![CDATA[.NET]]></category>
		<category><![CDATA[Create tempfile]]></category>
		<category><![CDATA[PowerShell]]></category>
		<category><![CDATA[System.IO.path]]></category>
		<category><![CDATA[Tempfile]]></category>
		<category><![CDATA[Windows Powershell]]></category>

		<guid isPermaLink="false">http://www.thomasmaurer.ch/?p=1837</guid>
		<description><![CDATA[Sometimes you need to save some data in to a tempfile. And instead of creating a ownen file for this you could use the .NET function to create a really tempfile in the tempfile directory. This is the how you &#8230; <a href="http://www.thomasmaurer.ch/2011/04/powershell-create-a-tempfile-with-powershell/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<!-- Start Shareaholic LikeButtonSetTop Automatic --><!-- End Shareaholic LikeButtonSetTop Automatic --><p><img class="aligncenter size-full wp-image-621" title="Powershell Header" src="http://www.thomasmaurer.ch/wp-content/uploads/2010/05/Screen-shot-2010-05-30-at-13.08.42.png" alt="Powershell Header" width="440" height="104" /></p>
<p>Sometimes you need to save some data in to a tempfile. And instead of creating a ownen file for this you could use the .NET function to create a really tempfile in the tempfile directory.</p>
<p>This is the how you can create a new tempfile:</p>
<pre>$tempFile = [System.IO.Path]::GetTempFileName()</pre>
<p>And now you can parse data into this file.</p>
<div class="shr-publisher-1837"></div><!-- Start Shareaholic LikeButtonSetBottom Automatic --><!-- End Shareaholic LikeButtonSetBottom Automatic -->]]></content:encoded>
			<wfw:commentRss>http://www.thomasmaurer.ch/2011/04/powershell-create-a-tempfile-with-powershell/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

