header image

Archive for August, 2008

New PowerShell book

Posted by: | August 20, 2008 | No Comment |

Manning, the publishers that brought you Bruce Payette’s PowerShell in Action have released another PowerShell book under their Manning Early Access Program (MEAP).  This one is called PowerShell in Practice. To Quote ‘This book is written to answer the question "How can PowerShell make my job as an administrator easier?"‘ The book is available at […]

under: PowerShell original

AD logon hours

Posted by: | August 18, 2008 | No Comment |

Finally got round to sorting out how to set logon hours in AD accounts. # deny logon at all times$user = [ADSI]"LDAP://cn=Joe Bloggs,ou=Test,dc=Manticore,dc=org"[byte[]]$hours = @(0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0)$user.logonhours[0] = $hours$user.setinfo() Use [ADSI] to get a user account.  Create a byte array. The logon hours are stored as an array of 21 bytes, 3 bytes per day, 1 bit […]

under: PowerShell and Active Directory


Posted by: | August 18, 2008 | No Comment |

One improvement to Get-Service that appears in PowerShell 2 CTP 2 is that you can work with the services on a remote computer Get-Service -ComputerName csdc1 retrieves the services on a remote machine so now we can do this $s = Get-Service -ComputerName csdc1 -Name netlogon$s.Start() Makes admin even easier with PowerShell – especially as […]

under: PowerShell original

Enough is Enough

Posted by: | August 17, 2008 | No Comment |

For the SECOND time today I have had to waste my time clearing up comments that some selfish idiot has plastered on numerous posts. The comments aren’t about the posts but are adverts that I am not prepared to tolerate. I have stopped accepting comments directly on the blog for the time being.  I have […]

under: Rant

Loop speed

Posted by: | August 15, 2008 | No Comment |

My post regarding Brandon’s research on foreach – http://richardsiddaway.spaces.live.com/blog/cns!43CFA46A74CF3E96!1600.entry started my thinking about the other looping mechanisms.  Was there any speed differences there? Intuitively I thought there probably wasn’t much difference but decided to test. I ran the following four tests. for($j=0;$j -le 10; $j++){Measure-Command -Expression {for($i=0;$i -le 50000; $i++){$i*9834}}} for($j=0;$j -le 10; $j++){Measure-Command -Expression […]

under: PowerShell original


Posted by: | August 13, 2008 | No Comment |

If you have been using PowerShell for awhile you will know that there is a foreach-object cmdlet aliased as  foreach (or even the  abomination of %) and there is a foreach() PowerShell language statement. Brandon blogged about the differences – the comments are well worth reading http://bsonposh.com/archives/327#comments   Share this post :   Technorati Tags: […]

under: PowerShell original

Vista: I like this

Posted by: | August 11, 2008 | No Comment |

One of the things I like about Vista (and there are some things I don’t like) is how it remembers the settings for external monitors and projectors. I often need to be working on a few documents simultaneously so the ability to add an external monitor to my laptop quickly is really useful. Plug in […]

under: General IT Matters

MMMUG September

Posted by: | August 11, 2008 | No Comment |

  From Nathan – MMMUG leader Here are the details of our September MMMUG meeting. This event will be held in London at the MSFT offices in Cardinal Place near Victoria. This month we have a exciting session led by John Stewart-Murray from Dialogic. John will be introducing telephony to us as IT Pros. We […]

under: IT Community

UK User Group

Posted by: | August 11, 2008 | No Comment |

The UK User group will have its next physical meeting on 23 September in Reading.  Details to follow.   Share this post :   Technorati Tags: PowerShell,user Group

under: PowerShell User Group

PowerShell Modules

Posted by: | August 10, 2008 | No Comment |

Modules are feature added to PowerShell in CTP 2. They can contain scripts, functions or dlls containing cmdlets or providers. The documentation for modules has been a bit sparse up to now but a post by james has opened up modules – http://blogs.msdn.com/mediaandmicrocode/archive/2008/08/10/microcode-all-about-modules-windows-powershell-ctp2.aspx.   Share this post :   Technorati Tags: PowerShell,CTP2,Modules

under: PowerShell original

« Newer Posts - Older Posts »