Category Archives: Windows Server 2008 R2

BITS posts

BITS is the Background Intelligent Transfer Service.  I’ve started a series of posts on using the PowerShell BITS cmdlets on my IT Knowledge Exchange blog 1  http://itknowledgeexchange.techtarget.com/powershell/bits/ 2 http://itknowledgeexchange.techtarget.com/powershell/download-multiple-files-by-bits/ 3 http://itknowledgeexchange.techtarget.com/powershell/upload-through-bits/ More to follow

Posted in BITS, PowerShell V2, Windows Server 2008 R2 | Leave a comment

Remoting between PowerShell v3 CTP 2 and PowerShell v2

One of the questions on tonight’s Live Meeting concerned the compatibility between remoting on PowerShell v2 and PowerShell v3 CTP 2 The difference is that v3 uses a WSMAN 3.0 stack but v2 uses 2.0 I used two machines: Windows … Continue reading

Posted in PowerShell V2, PowerShell V3, Windows 7, Windows Server 2008 R2 | 6 Comments

AD account Expiry date

In many organisations AD accounts for temporary works are set to expiry when their contract ends.  Its also a good practice to put an expiry date on any one who is leaving – that way you know their account won’t … Continue reading

Posted in PowerShell and Active Directory, Windows Server 2008 R2 | Leave a comment

Using AccountManagement classes to set local accounts expiry

This is a little more verbose than the WinNT example function set-expirydate { [CmdletBinding(SupportsShouldProcess=$true)] param ( [parameter(ValueFromPipeline=$true, ValueFromPipelineByPropertyName=$true)] [string]$computer, [parameter(ValueFromPipeline=$true, ValueFromPipelineByPropertyName=$true)] [string]$id ) BEGIN {Add-Type -AssemblyName System.DirectoryServices.AccountManagement} PROCESS { switch ($computer){ “.” {$computer = $env:computername} “localhost” {$computer = $env:computername} } … Continue reading

Posted in IT Security, PowerShell and Active Directory, Windows 7, Windows Server 2008, Windows Server 2008 R2 | Leave a comment

Setting local account expiry dates

Setting expiry dates on AD accounts is a common occurrence and is well documented. Setting expiry dates on local accounts is also possible $user = [adsi]“WinNT://./Test1, user” $expirydate = (Get-Date).AddDays(2) $user.Put(“AccountExpirationDate”, $expirydate) $user.SetInfo() $user.RefreshCache() $user | Format-List * This uses … Continue reading

Posted in IT Security, PowerShell and Active Directory, Windows 7, Windows Server 2008, Windows Server 2008 R2 | Leave a comment

Windows SysInternals Administrators Reference

Windows SysInternals Administrators Reference Title: Windows SysInternals Administrators Reference Publisher: Microsoft Press ISBN: 978-0-7356-5672-7 The SysInternals tool set – http://technet.microsoft.com/en-us/sysinternals/default.aspx  – should be one of a Windows administrator’s best friends. You may not need them every day but when you do … Continue reading

Posted in Books, Technology, Windows 7, Windows Server 2008, Windows Server 2008 R2 | Leave a comment

Network Connection Ids

Yesterday I was looking at changing a Network connection id (the name that shows in Network and Sharing Center when you look at the adapters). I kept getting an error – either COM or number of arguments depending if I … Continue reading

Posted in PowerShell and WMI, Windows 7, Windows Server 2008 R2 | Leave a comment

Networking pains

Last week my wireless router decided that it had enough and wasn’t going to work any more. This was annoying because I was due to give a user group presentation that night. I got a new router up and working … Continue reading

Posted in Virtualisation, Windows Server 2008 R2 | Leave a comment

Active Directory snapshots I

One of the useful, but often overlooked, features of Windows 2008 & 200 R2 is the ability to take snapshots of your AD database.  These can be then mounted and accessed in parallel with your live AD.  Its possible to … Continue reading

Posted in PowerShell and Active Directory, Windows Server 2008 R2 | Leave a comment

PAM 0.5–additional info

The reliability and stability metrics are enable by default on Windows 7. On Windows 2008 R2 need to enable them via GPO. Look for Configure Reliability WMI Providers (and enable) in Computer Configuration – Policies – Administrative Templates – Windows … Continue reading

Posted in PowerShell and WMI, PowerShell V2, Windows Server 2008 R2 | Leave a comment