Configure WANem via PowerShell

Written by Ingmar Verheij on June 11th, 2012. Posted in PowerShell

If you want to simulate a WAN connection (lower bandwidth, add delay, jitter, etc.) then WANem is a solution that is (relatively) easy to use and free.

 

Configuring the WAN emulator is done via a webpage, but unfortunately there are no API’s exposed to automate the configuration.

Since I needed to automate the configuration of the WAN emulator I wrote a PowerShell script. You can find the PowerShell scrip below.

PowerShell: Query Cisco (Catalyst 4500) Flow Control statistics

Written by Ingmar Verheij on June 1st, 2012. Posted in PowerShell

Last week I attended E2EVC in Vienna, a non-commercial,virtualization community Event, and attended a session of Saša Mašić about an issue he had at a customer. In short, the problems where caused by a switch that couldn’t process IP packets because it overflowed, and therefore Ethernet flow control temporarily stopped the transmission of some attached devices. Although I’m no network expert I do know this might be a serious issue. After reading this article, you might agree.

If you’re looking for the PowerShell script, scroll to the bottom.

RxPause and TxPause

This week I  was asked to troubleshoot performance issues at a customer and got informed that the core switches (Cisco Catalyst 4500) might be over capacity. A quick look in the flow control statistics (# show flowcontrol) indicated there where send numerous RxPause and TxPause packages, a sign Flow Control has been active.

Using objects as key in HashTable

Written by Ingmar Verheij on March 20th, 2012. Posted in VB.Net

A HashTable can be used to store a collection of key/value pairs. The key object is used to uniquely identify the key/value pair which makes is easy to store data like a database.

The type of the key object which is added to the HashTable is variable. It can be an integer, a string, a GUID etc. Because of the nature of a GUID (a globally unique identifier) it is an ideal candidate for a key object.

If you want to use a combination of two (or more) GUIDS as a key object you can create a class object, but there is a caveat.

DataSet.ReadXML throws DirectoryNotFoundException

Written by Ingmar Verheij on March 14th, 2012. Posted in VB.Net

A .NET application that reads a dataset from an XML using the DataSet.ReadXML method might throw the exception : System.IO.DirectoryNotFoundException: Could not find a part of the path ‘<path of XML file>’.

According to MSDN this exception is thrown when when “part of a file or directory cannot be found” .However, this exception is not only thrown when a file cannot be found on the disk. The exception is also thrown when the structure of the XML is invalid (for instance because you didn’t close a node)

Set DCOM remote access via PowerShell

Written by Ingmar Verheij on March 9th, 2012. Posted in PowerShell

If you want to use the Delivery Services Console (the management console of Citrix XenApp 6.x) from a remote machine, you need to enable remote access in DCOM (as described in CTX131829).

You can automate this via PowerShell using the script found below.

Donate