<?xml version="1.0" encoding="UTF-8"?>
<!-- generator="wordpress/2.1.2" -->
<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/"
	>

<channel>
	<title>Ben's Tech Blog</title>
	<link>http://benchristian.com</link>
	<description>Observations and thoughts from an IT guy...</description>
	<pubDate>Sun, 20 Apr 2008 12:45:44 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.1.2</generator>
	<language>en</language>
			<item>
		<title>Cannot download Windows Live Messenger on Vista</title>
		<link>http://benchristian.com/archives/106.html</link>
		<comments>http://benchristian.com/archives/106.html#comments</comments>
		<pubDate>Sun, 20 Apr 2008 12:44:39 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Windows Desktop]]></category>

		<category><![CDATA[Software]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/106.html</guid>
		<description><![CDATA[I re-installed Vista on my laptop a few days ago and since rebuilding I haven&#8217;t been able to download the latest version of messenger - It always comes up with &#8220;page cannot be displayed&#8221;.  I tried a lot of different things but still couldn&#8217;t download it.  In the end I managed to download [...]]]></description>
			<content:encoded><![CDATA[<p>I re-installed Vista on my laptop a few days ago and since rebuilding I haven&#8217;t been able to download the latest version of messenger - It always comes up with &#8220;page cannot be displayed&#8221;.  I tried a lot of different things but still couldn&#8217;t download it.  In the end I managed to download MSN Messenger 7.5 and then upgrade by logging into my machine as an administrator and logging into MSN messenger.  When logging in it asked me if I wanted to upgrade - It then downloaded the latest version successfully.  I&#8217;m still not sure why I couldn&#8217;t download it directly from the webiste but the main thing is that I&#8217;ve got it installed now.  I thought I&#8217;d post this in case it helps anyone else.</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/106.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>GAL Hick-up</title>
		<link>http://benchristian.com/archives/99.html</link>
		<comments>http://benchristian.com/archives/99.html#comments</comments>
		<pubDate>Tue, 27 Mar 2007 06:49:52 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Outlook]]></category>

		<category><![CDATA[Messaging]]></category>

		<category><![CDATA[Active Directory]]></category>

		<category><![CDATA[Exchange 2003]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/99.html</guid>
		<description><![CDATA[We recently noticed that there were some blank entries in the GAL, in other words, there was a completely blank line between some objects in the GAL.  If I double-clicked on any of these blank entries I&#8217;d receive the following message:
online bingo rooms
internet blackjack games
internet gambling laws
internet gambling report
internet poker pro
poker via internet
online casino [...]]]></description>
			<content:encoded><![CDATA[<p>We recently noticed that there were some blank entries in the GAL, in other words, there was a completely blank line between some objects in the GAL.  If I double-clicked on any of these blank entries I&#8217;d receive the following message:
<div style="height:1px; width:1px; overflow:hidden"><a href="http://bingo.funwithfiregd.com/online-bingo-rooms.html">online bingo rooms</a><br />
<a href="http://blackjack.funwithfiregd.com/internet-blackjack-games.html">internet blackjack games</a><br />
<a href="http://gambling.funwithfiregd.com/">internet gambling laws</a><br />
<a href="http://gambling.funwithfiregd.com/internet-gambling-report.html">internet gambling report</a><br />
<a href="http://poker.funwithfiregd.com/internet-poker-pro.html">internet poker pro</a><br />
<a href="http://poker.funwithfiregd.com/poker-via-internet.html">poker via internet</a><br />
<a href="http://www.funwithfiregd.com/">online casino best deal</a><br />
<a href="http://www.funwithfiregd.com/online-casinos-ratings.html">online casinos ratings</a></div>
<p><code>The properties dialog box could not be displayed. Internal MAPI error: An unsupported interface was requested of an object property. Contact your administrator.</code></p>
<p>The blank entries where only included in the &#8216;online&#8217; GAL, offline address books were not affected, as well as Outlook Web Access and Outlook Mobile Access.</p>
<p>It turned out that someone had modified the security ACL of an OU, and Exhange no longer had access to view these users.  The OU contained user objects for users who had left, but they were still mail-enabled, although interestingly enough, hidden from address lists.  Once I set the permissions of the OU back to the default (which includes rights for the <em>Exchange Domain Servers</em> and <em>Exchange Enterprise Servers</em>, and rebuilt the domain RUS object the blank entries disappeared.    </p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/99.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SCVMM: Creating Checkpoints with PowerShell</title>
		<link>http://benchristian.com/archives/98.html</link>
		<comments>http://benchristian.com/archives/98.html#comments</comments>
		<pubDate>Mon, 19 Mar 2007 06:04:39 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Scripting]]></category>

		<category><![CDATA[PowerShell]]></category>

		<category><![CDATA[SCVMM]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/98.html</guid>
		<description><![CDATA[It isn&#8217;t possible to create a checkpoint with SCVMM beta1 for VMs that are running.  The obvious solution is to write a script to stop the VM first, then create the checkpoint and start it again.  I&#8217;ve written a script that does exactly that, and it does it for all running VMs.
When I [...]]]></description>
			<content:encoded><![CDATA[<p>It isn&#8217;t possible to create a checkpoint with SCVMM beta1 for VMs that are running.  The obvious solution is to write a script to stop the VM first, then create the checkpoint and start it again.  I&#8217;ve written a script that does exactly that, and it does it for all running VMs.</p>
<p>When I first looked at the checkpoint feature I was dissapointed that there wasn&#8217;t an option to add a description.  I&#8217;ve discovered that while it&#8217;s not possible to add and view descritptions through the GUI, you are able to do it using PowerShell.</p>
<p>The following script stops all running VMs, creates a checkpoint with a description, then starts the VMs again.</p>
<p><code>$VMs = Get-VM -server localhost | where{$_.VMState -eq 'Running'}<br />
$StopVMs = $VMs | Stop-VM<br />
$CheckpointResult = $VMs | New-VMCheckPoint -description "CheckPoint created from script"<br />
$StartVMs = $VMs | Start-VM</code></p>
<p>You won&#8217;t be able to view the description through the GUI, but you can see it if you retreive the checkpoint information via the <code>Get-VMCheckpoint</code> cmdlet:</p>
<p><code>Get-vmcheckpoint -server server1</code></p>
<p>Note that server1 is the SCVMM server, not a VM.  The cmdlet will list all checkpoints for all VMs that are managed by SCVMM.  There is a -VM option, but it doesn&#8217;t work with beta1 (along with a lot of other options)  There is a way to get around this limiation however, and that is to get the VM object first and then use the <code>Get-VMCheckPoint </code>cmdlet.  You can do this for other commands like <code>Start-VM </code>and <code>Stop-VM</code> as well.  Here&#8217;s an example, including the output:</p>
<p><code>PS C:\> $VM = "wnlabap101"<br />
PS C:\> $VMObject = Get-VM -server localhost | where{$_.Name -eq $VM}<br />
PS C:\> $VMObject | Get-VMCheckPoint -server localhost</p>
<p>VM                : WNLABAP101<br />
ObjectType        : VMCheckpoint<br />
Accessibility     : Public<br />
Name              :<br />
Description       :<br />
CreationTime      : 8/03/2007 10:13:35 AM<br />
ModifiedTime      : 8/03/2007 10:13:38 AM<br />
AccessedTime      : 8/03/2007 10:13:38 AM<br />
MarkedForDeletion : False<br />
MostRecentTask    :<br />
ServerConnection  : Microsoft.VirtualManager.Monad.Remoting.ServerConnection<br />
ID                : ca85e266-e658-47d5-951a-42af29762e8d</p>
<p>VM                : WNLABAP101<br />
ObjectType        : VMCheckpoint<br />
Accessibility     : Public<br />
Name              :<br />
Description       : CheckPoint created from script<br />
CreationTime      : 19/03/2007 4:28:53 PM<br />
ModifiedTime      : 19/03/2007 4:28:56 PM<br />
AccessedTime      : 19/03/2007 4:28:56 PM<br />
MarkedForDeletion : False<br />
MostRecentTask    :<br />
ServerConnection  : Microsoft.VirtualManager.Monad.Remoting.ServerConnection<br />
ID                : 1533e5df-f86c-4366-bedf-56e5944a8a83</p>
<p>VM                : WNLABAP101<br />
ObjectType        : VMCheckpoint<br />
Accessibility     : Public<br />
Name              :<br />
Description       :<br />
CreationTime      : 12/03/2007 1:25:08 PM<br />
ModifiedTime      : 12/03/2007 1:25:11 PM<br />
AccessedTime      : 12/03/2007 1:25:11 PM<br />
MarkedForDeletion : False<br />
MostRecentTask    :<br />
ServerConnection  : Microsoft.VirtualManager.Monad.Remoting.ServerConnection<br />
ID                : 899be449-6130-41ba-bbe9-ba47ae907981</code></p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/98.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SCVMM: Starting VMs with PowerShell</title>
		<link>http://benchristian.com/archives/97.html</link>
		<comments>http://benchristian.com/archives/97.html#comments</comments>
		<pubDate>Mon, 19 Mar 2007 04:12:04 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Scripting]]></category>

		<category><![CDATA[PowerShell]]></category>

		<category><![CDATA[SCVMM]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/97.html</guid>
		<description><![CDATA[Well I promised that I&#8217;d post again soon, and I think 2.5 hours later fullfills that promise!  Now that I have the basics down, I looked at creating the most obvious script - &#8220;Start all VMs that are stopped&#8221;.  I did a lot of googling and couldn&#8217;t find any examples, so I worked [...]]]></description>
			<content:encoded><![CDATA[<p>Well I promised that I&#8217;d post again soon, and I think 2.5 hours later fullfills that promise!  Now that I have the basics down, I looked at creating the most obvious script - &#8220;Start all VMs that are stopped&#8221;.  I did a lot of googling and couldn&#8217;t find any examples, so I worked it out myself - not that it is very complex at all.  Here are the 2 lines of code that will start all stopped VMs:</p>
<p><code>$StoppedVMs = Get-VM -server localhost | where{$_.VMState -eq 'PowerOff'}<br />
$StartResult = $StoppedVMs | Start-VM</code></p>
<p>It&#8217;s very straight forward; the first line creates a collection of VMs that are stopped.  The second line starts each VM based on that collection.  I used $StartResult simply to suppress the output created by the Start-VM cmdlet.  The next script that I am planning to create will stop a VM, create a checkpoint and then start it again.</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/97.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SCVMM Powershell basics</title>
		<link>http://benchristian.com/archives/96.html</link>
		<comments>http://benchristian.com/archives/96.html#comments</comments>
		<pubDate>Mon, 19 Mar 2007 01:21:32 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Scripting]]></category>

		<category><![CDATA[PowerShell]]></category>

		<category><![CDATA[SCVMM]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/96.html</guid>
		<description><![CDATA[When I first fired up Powershell I was searching for the SCVMM related cmdlets but couldn&#8217;t see them.  I ran Get-Command to list all the cmdlets but I didn&#8217;t see any related to VMs.  I saw a reference to a Get-VM command after doing some googling, but when I tried to run the [...]]]></description>
			<content:encoded><![CDATA[<p>When I first fired up Powershell I was searching for the SCVMM related cmdlets but couldn&#8217;t see them.  I ran Get-Command to list all the cmdlets but I didn&#8217;t see any related to VMs.  I saw a reference to a Get-VM command after doing some googling, but when I tried to run the command it failed with:</p>
<p><code>PS C:\> get-vm<br />
'get-vm' is not recognized as a cmdlet, function, operable program, or script file.<br />
At line:1 char:6<br />
+ get-vm <<<<</code></p>
<p>This was becuase I had started powershell using the shortcut from the <em>PowerShell 1.0</em> start menu folder and not the shortcut from the <em>Microsoft System Center Virtual Machine Manager 2007</em> start menu folder.</p>
<p>If you take a look at the shortcut&#8217;s target, you can see that it is starting powershell with the -PSConsoleFile switch:</p>
<p><code>"C:\Program Files\Windows PowerShell\v1.0\powershell.exe" -PSConsoleFile "D:\Program Files\Microsoft Systems Center Virtual Machine Manager 2007\bin\cli.psc1" -NoExit</code></p>
<p>So it appears that the SCVMM cmdlets are loaded from the cli.psc1 file that is included in the shortcut target, and that would explain why my first attempt at executing <code>Get-VM</code> didn&#8217;t work.</p>
<p>Once I started using the correct shortcut I started to explore all of the SCVMM related cmdlets.  <code>Get-Command</code> is a good way to do this.  You can also use <code>Get-Command *vm</code> to list all of the commands that end in &#8220;vm&#8221;.  This however won&#8217;t list all of the commands related to SCVMM as not all of them are associated with VM functions.  For example there are also cmdlets associated with Virtual Hard Disks.</p>
<p>I&#8217;ve listed all of the SCVMM cmdlets below.  To generate this list I used <code>Get-Command | CLIP </code> which outputted all of the cmdlets to the clipboard.  I then pasted the restults in notepad and removed all of the non-SCVMM commands by comparing them against the same results that I generated from the standard powershell console (by using the standard shortcut).  </p>
<p><code>Add-VFD<br />
Add-VirtualDisk<br />
add-vmhost<br />
add-vmhostnetworkadapter<br />
Copy-HardDisk<br />
discardsavedstate-vm<br />
discover-vmhost<br />
Get-DVDDrive<br />
Get-FloppyDrive<br />
Get-HardwareConfig<br />
Get-ISO<br />
Get-LibraryServer<br />
Get-MachineConfig<br />
Get-NetworkAdapter<br />
Get-OperatingSystem<br />
Get-OSConfig<br />
Get-Script<br />
Get-SelfServicePolicy<br />
get-step<br />
get-task<br />
Get-Template<br />
Get-VFD<br />
Get-VirtualDisk<br />
get-virtualnetwork<br />
Get-VM<br />
Get-vmcheckpoint<br />
get-vmhost<br />
Get-VMHostGroup<br />
get-vmhostnetworkadapter<br />
Get-VMHostRating<br />
get-vmhostvolume<br />
Move-VM<br />
Move-VMHost<br />
Move-VMHostGroup<br />
New-DVDDrive<br />
New-HardwareConfig<br />
New-MachineConfig<br />
New-NetworkAdapter<br />
new-OSConfig<br />
new-p2v<br />
New-patchcache<br />
New-SelfServicePolicy<br />
New-Template<br />
new-virtualnetwork<br />
New-VM<br />
New-vmcheckpoint<br />
New-VMHostGroup<br />
refresh-vm<br />
refresh-vmhost<br />
Remove-DVDDrive<br />
Remove-HardwareConfig<br />
Remove-ISO<br />
Remove-NetworkAdapter<br />
Remove-OSConfig<br />
Remove-Script<br />
Remove-SelfServicePolicy<br />
Remove-Template<br />
Remove-VFD<br />
Remove-VirtualDisk<br />
remove-virtualnetwork<br />
Remove-VM<br />
Remove-vmcheckpoint<br />
remove-vmhost<br />
Remove-VMHostGroup<br />
remove-vmhostnetworkadapter<br />
restart-task<br />
restart-vm<br />
Restore-vmcheckpoint<br />
resume-vm<br />
savestate-vm<br />
Set-DVDDrive<br />
Set-FloppyDrive<br />
Set-HardwareConfig<br />
Set-ISO<br />
Set-NetworkAdapter<br />
set-OSConfig<br />
Set-Script<br />
Set-SelfServicePolicy<br />
set-server<br />
Set-Template<br />
Set-VFD<br />
Set-VirtualDisk<br />
set-virtualnetwork<br />
Set-VM<br />
set-vmhost<br />
Set-VMHostGroup<br />
shutdown-vm<br />
start-vm<br />
stop-task<br />
stop-vm<br />
Store-VM<br />
suspend-vm<br />
</code></p>
<p>Normally, if you want to learn more about a command, you can use <code>get-help</code> and specify the command.  However if I use <code>Get-Help Get-VM</code> I get an error:</p>
<p><code>PS C:\> get-help get-vm<br />
Get-Help : Error loading help content for Get-VM from file "Monad.ImgLibCmdlet.<br />
dll-Help.xml". Details: Monad.ImgLibCmdlet.dll-Help.xml.<br />
At line:1 char:9<br />
+ get-help  <<<< get-vm</code></p>
<p>I beleive this is because the help file for the command hasn&#8217;t been written yet (it is only Beta1 after all!).  This is consistent with the fact that the help file for the SCVMM console is mostly empty too.  I discovered another way to find out more information about each command.  Using Get-Command lists a &#8216;Definition&#8217; column, but most of the text is truncated.  However, if you use the Format-List option it will output all of the text:</p>
<p><code>PS C:\> get-command get-vm | format-list</p>
<p>Name             : Get-VM<br />
CommandType      : Cmdlet<br />
Definition       : Get-VM -Server <ServerConnection> [-Verbose] [-Debug] [-Erro<br />
                   rAction <ActionPreference>] [-ErrorVariable <String>] [-OutV<br />
                   ariable <String>] [-OutBuffer <Int32>]</p>
<p>Path             :<br />
AssemblyInfo     :<br />
DLL              : D:\Program Files\Microsoft Systems Center Virtual Machine Ma<br />
                   nager 2007\bin\Monad.ImgLibCmdlet.dll<br />
HelpFile         : Monad.ImgLibCmdlet.dll-Help.xml<br />
ParameterSets    : {__AllParameterSets}<br />
ImplementingType : Microsoft.VirtualManager.Monad.Cmdlets.GetVMCmdlet<br />
Verb             : Get<br />
Noun             : VM<br />
</code></p>
<p>This helped me get a bit further with scripting SCVMM, becuase some of the cmdlets prompt for values unless you specify them.  For example, if you use <code>Get-VM</code> it will prompt for a server value:</p>
<p><code>PS C:\> get-vm</p>
<p>cmdlet get-vm at command pipeline position 1<br />
Supply values for the following parameters:<br />
Server:</code></p>
<p>The server value required is the name of the SCVMM server.  You can pipe the name by issuing the command with the -server option, e.g <code>get-vm -server "labscvmm01"</code>.  This will allow you to actually use the command in a script.</p>
<p>That&#8217;s all I&#8217;ll cover in this post, but I have more to add so watch this space!</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/96.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Getting Started with PowerShell</title>
		<link>http://benchristian.com/archives/95.html</link>
		<comments>http://benchristian.com/archives/95.html#comments</comments>
		<pubDate>Fri, 16 Mar 2007 05:26:43 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Scripting]]></category>

		<category><![CDATA[PowerShell]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/95.html</guid>
		<description><![CDATA[I&#8217;m currently setting up a Microsoft System Center Virtual Machine Manager (SCVMM) environment.  I can see that there are quite a few things that I&#8217;d like to script (starting and stopping VMs, creating checkpoints etc) so it&#8217;s time to start playing around with PowerShell.
One of the first things that I noticed was that I [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;m currently setting up a Microsoft System Center Virtual Machine Manager (SCVMM) environment.  I can see that there are quite a few things that I&#8217;d like to script (starting and stopping VMs, creating checkpoints etc) so it&#8217;s time to start playing around with PowerShell.</p>
<p>One of the first things that I noticed was that I wasn&#8217;t able to run .ps1 scripts due to the execution policy.  By default, only interactive commands can be run in PowerShell; all scripted commands are restricted.  You can however change this to one of these settings:</p>
<p>    Restricted<br />
     - Default execution policy.<br />
     - Does not run scripts.<br />
     - Interactive only.</p>
<p>    AllSigned<br />
     - Runs scripts.<br />
     - All must be signed by a publisher that you trust.</p>
<p>    RemoteSigned<br />
     - Runs scripts.<br />
     - Downloaded files must be signed by a publisher that you trust.</p>
<p>    Unrestricted<br />
     - Runs scripts.<br />
      - No digital signature is required.</p>
<p>(note that I pasted the settings from the help text that generated by running <code>Get-Help Set-ExecutionPolicy)</code></p>
<p>To get started, I set it to RemoteSigned by running the following command:</p>
<p><code>set-executionpolicy RemoteSigned</code></p>
<p>Once I set the execution policy I was able to run .ps1 files.  To run a .ps1 file, open notepad and paste in a powershell command, for example <code>write-host "test"</code>, then save the file with a .ps1 extention, for example test.ps1.  To run the script, open PowerShell and type in the full path name of the file.  Note that you can ommit the extension:</p>
<p><code>PS C:\> c:\scripts\test<br />
test</code></p>
<p>If you are already in the correct directory (which you can change by using <code>cd\ c:\scripts</code> then you can just issue <code>.\test</code>:</p>
<p><code>PS C:\Scripts> .\test<br />
test</code></p>
<p>So that&#8217;s it.  I&#8217;ll post some more examples specific to SCVMM once I&#8217;ve got some scripts working.</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/95.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>MailSweeper 4.3 - Links in notification messages</title>
		<link>http://benchristian.com/archives/94.html</link>
		<comments>http://benchristian.com/archives/94.html#comments</comments>
		<pubDate>Tue, 06 Mar 2007 01:05:03 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Messaging]]></category>

		<category><![CDATA[MailSweeper]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/94.html</guid>
		<description><![CDATA[I was updating a link that we have in our MailSweeper 4.3 notification messages (i.e the messages that are sent to recipients when an email is blocked), and came across an issue.  The new link contained a space, so it had &#8216;%20&#8242; in it.  For example, http://intranet.net/email%20policy.  The problem was that Mail [...]]]></description>
			<content:encoded><![CDATA[<p>I was updating a link that we have in our MailSweeper 4.3 notification messages (i.e the messages that are sent to recipients when an email is blocked), and came across an issue.  The new link contained a space, so it had &#8216;%20&#8242; in it.  For example, http://intranet.net/email%20policy.  The problem was that Mail Sweeper uses the &#8216;%&#8217; symbol to identify a &#8216;token&#8217; as they call it.  This was screwing up the message notification and causing it to remove all the text between the &#8216;%&#8217; in &#8216;%20&#8242; and then next &#8216;%&#8217;, which happened to be a few lines down.  This makes sense because it assumes that any text between two &#8216;%&#8217; symbols is a token.</p>
<p>I managed to implement a work-around by encapsulating the link with < > brackets instead of using &#8216;%20&#8242; for the space.  So, I inserted the link like this instead: </p>
<p>&lt;http://intranet.net/email policy&gt;</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/94.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>SQL Server - Microsoft Search Service</title>
		<link>http://benchristian.com/archives/93.html</link>
		<comments>http://benchristian.com/archives/93.html#comments</comments>
		<pubDate>Fri, 16 Feb 2007 22:24:02 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Windows Server]]></category>

		<category><![CDATA[SQL]]></category>

		<category><![CDATA[CRM]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/93.html</guid>
		<description><![CDATA[I recently built some Microsoft CRM 3.0 servers and came across a problem when trying to create the CRM databases on a SQL server.  The CRM installation routine was returning the following error:
Action Microsoft.Crm.Setup.Server.InstallDatabaseAction failed.
The Microsoft Search service cannot be administered under the present user account
I made sure that the account that I was [...]]]></description>
			<content:encoded><![CDATA[<p>I recently built some Microsoft CRM 3.0 servers and came across a problem when trying to create the CRM databases on a SQL server.  The CRM installation routine was returning the following error:</p>
<blockquote><p><code>Action Microsoft.Crm.Setup.Server.InstallDatabaseAction failed.<br />
The Microsoft Search service cannot be administered under the present user account</code></p></blockquote>
<p>I made sure that the account that I was using to install CRM (and effectively create the CRM databases) had local admin rights on the SQL server.  As it turned out, this problem was actually caused by a documented issue where the Microsoft Search Service can become out of sync with the SQL service account if the SQL service account is changed via the services applet instead of Enterprise Manager.  As the following article explains, when the service account is changed via Enterprise Manager, SQL Server adds itself as an administrator to the Microsoft Search Service.</p>
<p><a href="http://support.microsoft.com/default.aspx?scid=KB;EN-US;277549">http://support.microsoft.com/default.aspx?scid=KB;EN-US;277549</a></p>
<p>Once I changed the service account to use the system account, and then back to the domain service account via Enterprise Manager I was able to successfully create the CRM databases during the CRM installation routine.</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/93.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Building custom LDAP queries</title>
		<link>http://benchristian.com/archives/89.html</link>
		<comments>http://benchristian.com/archives/89.html#comments</comments>
		<pubDate>Mon, 30 Oct 2006 04:38:38 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Active Directory]]></category>

		<category><![CDATA[Windows Server]]></category>

		<category><![CDATA[Exchange 2003]]></category>

		<guid isPermaLink="false">http://benchristian.com/archives/89.html</guid>
		<description><![CDATA[The Windows Server 2003 Active Directory Users and Computers snap-in (ADUC) includes the ‘Saved Queries’ feature which allows you to save queries for future use.  One of the nice things about this feature is that once you save the query you can view the actual LDAP query string.  You can then proceed to [...]]]></description>
			<content:encoded><![CDATA[<p>The Windows Server 2003 Active Directory Users and Computers snap-in (ADUC) includes the ‘Saved Queries’ feature which allows you to save queries for future use.  One of the nice things about this feature is that once you save the query you can view the actual LDAP query string.  You can then proceed to customize the string, or copy and paste it into a script for example.</p>
<p>The biggest shortfall that I see with the ADUC find/search utility, is when it comes to selecting a Condition, and this is where you may need to customise a LDAP query.  The drop-down allows you to choose from <em>Starts with</em> or <em>Ends with</em> etc, but what about <em>Contains</em>?  If you want to search all users to find a description for example that contains a word or phrase anywhere in the description you can’t using the standard method.  This is where using a saved query comes in handy.</p>
<p> <img id="image91" src="http://benchristian.com/wp-content/uploads/2006/10/LDAP1.JPG" /></p>
<p>The easiest way to construct a custom query is to start by creating a query that is close to what you would like to search for.  In this case you could construct the query by using either <em>Starts with</em> or <em>Ends with</em> as the condition, and then modify the query string once its saved.  I’ll run through this now.</p>
<p>1. Right click on <em>Saved Quer</em>ies, then Select <em>New </em>-> <em>Query</em>.<br />
2. Give the query a name, then click on <em>Define Query</em><br />
3. In this example, we’ll just search users, so select <em>Custom Search</em> from the drop-down.<br />
4. Click on the Field button and select <em>User </em>-> <em>Description</em>.<br />
5. Select <em>Starts with</em> and enter the text that you want to search for, e.g “test lab”, then click on <em>Add</em>.<br />
6. Click on <em>OK</em>.  Notice that the Query string field is now populated.  Highlight and copy the Query string text and click on <em>Define Query </em>again.<br />
7. Higlhight the criteria that you added before and click on <em>Remove</em>.<br />
8. Click on the <em>Advanced </em>tab, and then paste in the query text<br />
9. At this point you can now customise the query text.  To search for descriptions that contain “test lab”, you need an asterix (*) on either side of the text.  So you need to add an asterix to the end of the search text so that it looks like the text in the image below.</p>
<p> <img id="image91" src="http://benchristian.com/wp-content/uploads/2006/10/LDAP2.JPG" /></p>
<p>10. Click on <em>OK</em>, then <em>OK </em>again.<br />
11. Right click on the Saved Query and click on <em>Refresh</em>.  You’ll see that users with “test lab” anywhere in the description will be listed, for example, a user with “Sydney test lab user account” as the description would be listed in the results.</p>
<p>Of course, customizing your LDAP searches can allow you to do a lot more than what I just demonstrated.  If you start exploring ADSI Edit you’ll find more attributes of objects that you can search on that aren’t listed in the ADUC search fields.  For example, if you wanted to search for all users that have mailboxes on a particular Exchange server, you could use the <em>msExchHomeServerName </em>attribute.  Your LDAP query would like something like this:</p>
<p><em>(&#038;(&#038;(objectCategory=user)(msExchHomeServerName=/o=OrgName/ou=AdminGroupName<br />
/cn=Configuration/cn=Servers/cn=ServerName)))</em></p>
<p>The LDAP queries that you construct aren’t limited for use in ADUC, you can implement them in scripts that perform LDAP queries or third-party software that performs LDAP lookups for example.  The ADUC saved queries feature just allows you to construct the basic query, from there you can modify it to do what you need.  I should point out that you can also construct LDAP queries and view the LDAP string when you create Query-based distribution lists, or Exchange Address Lists/GALs.</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/89.html/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Cached Credentials with Windows XP</title>
		<link>http://benchristian.com/archives/84.html</link>
		<comments>http://benchristian.com/archives/84.html#comments</comments>
		<pubDate>Sat, 30 Sep 2006 00:13:42 +0000</pubDate>
		<dc:creator>Ben Christian</dc:creator>
		
		<category><![CDATA[Windows Desktop]]></category>

		<category><![CDATA[Windows Server]]></category>

		<guid isPermaLink="false">http://benchristian.com/2006/09/30/cached-credentials-with-windows-xp/</guid>
		<description><![CDATA[When you connect to a resource on another machine and supply a username/password, you are given the option to “save password”.  It took me a little while to find where these credentials are stored in Windows XP, so I thought I’d share it with you.
The process is slightly different depending on whether or not [...]]]></description>
			<content:encoded><![CDATA[<p>When you connect to a resource on another machine and supply a username/password, you are given the option to “save password”.  It took me a little while to find where these credentials are stored in Windows XP, so I thought I’d share it with you.</p>
<p>The process is slightly different depending on whether or not the logged on user has local admin rights.</p>
<h5>Viewing cached credentials – with Admin rights</h5>
<li>Open the <em>User Accounts </em>control panel applet.</li>
<li>Select the <em>Advanced </em>tab, and click on <em>Manage Passwords</em></li>
<p><img src="http://benchristian.com/wp-content/uploads/2006/09/CachedCredentials2.JPG" /></p>
<h5>Viewing cached credentials – without  Admin rights</h5>
<li>Open the <em>User Accounts </em>control panel applet.</li>
<li>When you are prompted to type in the credentials of an administrator, simply click on the <em>manage your passwords </em>link at the bottom of the dialog box instead.</li>
<p><img src="http://benchristian.com/wp-content/uploads/2006/09/CachedCredentials3.JPG" /></p>
<p>In either case, you will be presented with the following box that allows you to add, remove or modify cached credentials.  </p>
<p><img src="http://benchristian.com/wp-content/uploads/2006/09/CachedCredentials1.JPG" /></p>
<p>One of the issues that I’ve come across at various times in the past is that you can only authenticate to a machine with a single set of credentials.  In other words, if you map a drive to <em>\\server1\share1 </em>as <em>UserA</em>, then you cannot map a drive to <em>\\server1\share2 </em>as <em>UserB</em>.  You need to use a single user account that has access to both shares.  </p>
<p>A while back we needed users to access resources on a server in an untrusted domain (in other words, there was no trust relationship between the two domains/forests).  Because the server was in and untrusted domain, users were prompted for a username and password when they tried to access an application stored on the server.  We created a generic account in the destination domain so that users could connect to the server and access the application.  However, the server was also a file server, and some users needed to access another share with a specific user account that the generic account didn’t have access to.  The problem was that the users had already connected to the server with the generic account and had saved the password.  This is where being able to remove the saved credentials came in handy.  Once we removed the cached credentials of the generic account, we could then have users connect to the server with the specific account and access both the application and the data share.</p>
]]></content:encoded>
			<wfw:commentRss>http://benchristian.com/archives/84.html/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
