<?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>It&#039;s Just Another Layer &#187; PowerCLI</title>
	<atom:link href="http://itsjustanotherlayer.com/tag/powercli/feed/" rel="self" type="application/rss+xml" />
	<link>http://itsjustanotherlayer.com</link>
	<description>Virtualization is a layer in software. What are you abstracting away from?</description>
	<lastBuildDate>Sat, 03 Sep 2011 23:33:00 +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>Using PowerCLI in an enterprise environment</title>
		<link>http://itsjustanotherlayer.com/2010/05/using-powercli-in-an-enterprise-environment/</link>
		<comments>http://itsjustanotherlayer.com/2010/05/using-powercli-in-an-enterprise-environment/#comments</comments>
		<pubDate>Fri, 14 May 2010 03:28:06 +0000</pubDate>
		<dc:creator>iguy</dc:creator>
				<category><![CDATA[VMware]]></category>
		<category><![CDATA[PowerCLI]]></category>
		<category><![CDATA[Proxy]]></category>

		<guid isPermaLink="false">http://itsjustanotherlayer.com/?p=412</guid>
		<description><![CDATA[Most enterprises take security very seriously.   As such it is extremely common to have a webproxy setup by default in your environment.   PowerCLI/Powershell are configured by default to Use System Proxy.   This means that when you attempt to use some &#8230; <a href="http://itsjustanotherlayer.com/2010/05/using-powercli-in-an-enterprise-environment/">Continue reading <span class="meta-nav">&#8594;</span></a>]]></description>
			<content:encoded><![CDATA[<p>Most enterprises take security very seriously.   As such it is extremely common to have a webproxy setup by default in your environment.   PowerCLI/Powershell are configured by default to Use System Proxy.   This means that when you attempt to use some of the cmdlets they will end up being attempted to get routed through the proxy.</p>
<p>Two cmdlets that do not work properly when this is happening are <em>Install-VMHostPatch</em> &amp; <em>Copy-DatastoreItem</em>.  A good indication of the proxy being involved is exceptions that have items like:<br />
<code> Proxy Authentication Required</code></p>
<p>To work around this wrap the code in a <em>Set-PowerCLIConfiguration</em> proxy avoidance.</p>

<div class="wp_syntax"><table><tr><td class="line_numbers"><pre>1
2
3
4
5
6
</pre></td><td class="code"><pre class="powershell" style="font-family:monospace;"><span style="color: #800080;">$CurrentProxyCfg</span> <span style="color: pink;">=</span> Get<span style="color: pink;">-</span>PowerCLIConfiguration
Set<span style="color: pink;">-</span>PowerCLIConfiguration <span style="color: pink;">-</span>ProxyPolicy NoProxy
...
Install<span style="color: pink;">-</span>VMHostPatch <span style="color: #000000;">&#91;</span>...<span style="color: #000000;">&#93;</span>
...
Set<span style="color: pink;">-</span>PowerCLIConfiguration <span style="color: pink;">-</span>ProxyPolicy <span style="color: #800080;">$CurrentProxyCfg</span>.ProxyPolicy</pre></td></tr></table></div>

<p>Thanks to @cshanklin &#038; @lucd for their assistance in aiming me down the right path.  </p>
]]></content:encoded>
			<wfw:commentRss>http://itsjustanotherlayer.com/2010/05/using-powercli-in-an-enterprise-environment/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

