Tag Archives: FileSystem

Get Top Level Folder Usage

This is too long to tweet, even written as a one liner. But this will search a folder for top level subfolders and return the file usage for each. $folder="S:\" dir $folder | where {$_.psIscontainer} | foreach { $stat= dir … Continue reading

Posted in PowerShell v2.0 | Tagged , , | 5 Comments

Friday the 13 Script Blocks

In celebration of Friday the 13th and to help ward off any triskaidekaphobia I thought I’d offer up 13 PowerShell scriptblocks. These are scriptblocks that might solve a legitimate business need like finding how long a server has been running … Continue reading

Posted in PowerShell v2.0, Scripting, Windows 7, Windows Server, WMI | Tagged , , , , , , | 2 Comments

Objects are the answer

As I usually do, I was helping out in the forums at ScriptingAnswers.com. A member had several variables that he wanted to show as a group. As is almost always the case, the answer in PowerShell is object. I talk … Continue reading

Posted in PowerShell v2.0, Scripting | Tagged , , , , | Comments Off

New File Shortcut

I’ve been looking at the File Server Resource Manager (FSRM) feature in Windows Server 2008 R2 a lot lately. One very nice part of FSRM is the ability to schedule typical file management tasks. One of the examples from the … Continue reading

Posted in PowerShell v2.0, Scripting, Windows Server | Tagged , , , , , , | 2 Comments

Get Disk Quota

During a recent class I was teaching, a student asked about a way to get disk quota reports from Windows file servers.  I knew there was a WMI class, Win32_DiskQuota, and had some old VBScript files. However, they were pretty … Continue reading

Posted in PowerShell v2.0, Scripting, Windows Server, WMI | Tagged , , , , | 4 Comments