Sysadmins of the North
Share now!





Tag Archives for " PowerShell "

Software deployment through WDS

In my environment, I had to set up a new Windows Deployment Services (WDS) configuration for Windows 8.1 Enterprise. To roll out in our office (some 20+ workstations). I wanted to install some additional software at the same time, without using Microsoft Deployment Workbench, because I find the interface too slow. The solution? Read on…

Continue reading
PowerShell 5.0

PowerShell: find all files owned by a particular user

Find all files from one owner in Windows using PowerShell

In Windows, you sometimes need to find all files owned by a specific user. Recursively on your Windows Server NTFS file system. PowerShell has some nice cmdlets and features to automate this task for you. Here you’ll find example PowerShell scripts to find and list files owned by a specific user…

Continue reading

Disk Cleanup in Windows Server

Over time, as your Windows Server runs longer, more and more disk space is eaten. Simply gone! Investigating the disk usage leaves you clueless; there are no large log files, crash dumps, or there is no software to be removed. Where did that space go?

The answer: Windows Updates, Service Pack, and hotfix installations.

Continue reading
Image of a phone book. Domain Name Servers (DNS) are the Internet's equivalent of a phone book

WMI/netsh to add DNS servers on network adapters

How to add DNS servers – or resolvers – to a Windows Server network adapter, or interface using WMI and the netsh command. This one is quite old but may come in handy sometimes. In this example we use Google’s Public DNS server addresses and localhost to add as DNS Servers on our server.

Continue reading

.svc WCF web service returns 404 Not Found on IIS 8

When a Windows Communications Foundation (WCF) web service returns a 404 Not Found error, after installing the HTTP-Activation feature in IIS, you might need to add an extra Handler to your IIS configuration.

Continue reading

How to install the Web-WebSockets feature in IIS using PowerShell

How to install WebSocket Protocol support in IIS through PowerShell‘s Install-WindowsFeature cmdlet. Simply install and enable support for the WebSocket protocol on Windows Server IIS.

Continue reading

Forfiles: How to delete files recursively on Windows Server

The Forfiles command on Windows selects and executes a command on a file or set of files. Forfiles is ideal for batch processing through scripts. For instance on Windows Server systems. With Forfiles, you can run a command on or pass arguments to multiple files. For example, you could run the type command on all files in a tree with the .txt extension. Or you could execute every batch file (*.bat) on drive C, with the file name “Myinput.txt” as the first argument.

Continue reading

Add websites and application pools to IIS 7.5, 8.0 with PowerShell, in a for loop

How to use PowerShell to create websites and application pools in IIS… A client of the company I work for wanted to quickly add 60 sub-domains to his website. But, the sub-domains had to be created as self contained IIS websites, and running in their own application pools. Luckily, the client wanted 60 consecutive sub-domain names, e.g. “sub01.example.com”, “sub02.example.com”, …, … up till “sub60.example.com”. This made our task a bit easier, because we could easily script this in PowerShell

Continue reading

Windows Server logo small

Microsoft Deployment Workbench: silent installation of various applications

Silently deploy applications through Windows Deployment Services (WDS) / Microsoft Deployment Workbench, or the command line. Sometimes you just can’t find the correct command parameter – or switch – for silent, unattended software installations. Unattended, silent installation of software is ideal in an automated deployment installation of Windows Server or Windows 7, 8 & 8.1 client computers, through Windows Deployment Services (WDS).

Continue reading
Skip to content