ADVERTISE HERE

VM Load Generator

Title: VM Load Generator
Author(s): Xtravirt (Paul Davey)
Target Audience: Technical - Novice
Current Revision: 1.0 April 2008
First Published: 1 April 2008
Products: Perl, VBscript
UID: XD10061
Information
Title: 
VM Load Generator
Author(s): 
Xtravirt (Paul Davey)
Target Audience: 
Technical - Novice
First Published: 
1 April 2008
Products: 
Perl, VBscript
UID: 
XD10061

Scripts to generate a load under a Windows or Linux VM

1.0 Overview

These could be used for stress testing your ESX Servers  One is VBscript for Windows VM's and the other is Perl for *nix (Unix/Linux) VM's.  Once you've started the .vbs one you can stop it by killing the wscript process under Windows Task Manager. 

cpubusy.pl

#!/usr/bin/perl

$goal = 2181818;
while (TRUE) {
for ($i=0; $i<=$goal; $i++) {
$x = 0.000001;
$y = sin($x);
$y = $y + 0.00001;
}
next;
$y = $y + 0.01;
}

cpubusy.vbs

Dim goal
Dim before
Dim x
Dim y
Dim i
goal = 2181818

Do While True
before = Timer
For i = 0 to goal
x = 0.000001
y = sin(x)
y = y + 0.00001
Next
y = y + 0.01
Loop

References
References: 
  1. Nil
References
  1. Nil
Tags
capacity
ESX
load generator
perl
vbscript
VMware
Capacity Planning
Management

Spotlight:

Microsoft Volume Licensing in Virtualized Environments

If you are a Microsoft volume licensing customer then this paper is a 'must have'

Tape Backup Integration with VMware Data Recovery (VDR)

Move VDR backup data to tape the easy way with Powershell

Beginners Guide to Managing VMware using PowerShell

Release the power...go forth and manage VMware using Microsoft's PowerShell

Technology Exchange:

Paul Davey, Xtravirt CTO - Blog

virtualboy - Matt McSpirit on Windows Server & Virtualisation

Simon Long - The Slog

ICT-Freak – VMware, Windows, Citrix, Linux, Scripting...

Virtu-Al – Virtually everything is poshable

Download the FREE SolarWinds VM Monitor for Instant Visibility into VMware!

Add3 – Technology Driven Consultancy

Dan Eason is Virtually Insane

<!--[if gte mso 9]> Normal 0 false false false EN-GB X-NONE X-NONE MicrosoftInternetExplorer4 <![endif]--><!--[if gte mso 9]> <![endif]--><!-- /* Font Definitions */ @font-face {font-family:"Cambria Math"; panose-1:2 4 5 3 5 4 6 3 2 4; mso-font-charset:1; mso-generic-font-family:roman; mso-font-format:other; mso-font-pitch:variable; mso-font-signature:0 0 0 0 0 0;} @font-face {font-family:Calibri; panose-1:2 15 5 2 2 2 4 3 2 4; mso-font-charset:0; mso-generic-font-family:swiss; mso-font-pitch:variable; mso-font-signature:-520092929 1073786111 9 0 415 0;} /* Style Definitions */ p.MsoNormal, li.MsoNormal, div.MsoNormal {mso-style-unhide:no; mso-style-qformat:yes; mso-style-parent:""; margin:0cm; margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-fareast-font-family:Calibri; mso-fareast-theme-font:minor-latin;} .MsoChpDefault {mso-style-type:export-only; mso-default-props:yes; font-size:10.0pt; mso-ansi-font-size:10.0pt; mso-bidi-font-size:10.0pt;} @page Section1 {size:612.0pt 792.0pt; margin:72.0pt 72.0pt 72.0pt 72.0pt; mso-header-margin:36.0pt; mso-footer-margin:36.0pt; mso-paper-source:0;} div.Section1 {page:Section1;} --><!--[if gte mso 10]> <! /* Style Definitions */ table.MsoNormalTable {mso-style-name:"Table Normal"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-qformat:yes; mso-style-parent:""; mso-padding-alt:0cm 5.4pt 0cm 5.4pt; mso-para-margin:0cm; mso-para-margin-bottom:.0001pt; mso-pagination:widow-orphan; font-size:11.0pt; font-family:"Calibri","sans-serif"; mso-ascii-font-family:Calibri; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Times New Roman"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:Calibri; mso-hansi-theme-font:minor-latin; mso-bidi-font-family:"Times New Roman"; mso-bidi-theme-font:minor-bidi;} --> <!--[endif]-->

ICT-Freak – VMware, Windows, Citrix, Linux, Scripting...