Watermark-based Power Budget Enforcement

This page has software to enforce a given sustained power budget at a PDU supplying power to a group of servers. 
This distributed software comprises the following components. Code running on the PDU (or on behalf of the PDU elsewhere, 
as is the case in our prototype) monitors the power usages of individual servers and employs a watermark to enforce 
the specified power budget. A violation of the watermark causes messages sent to user-space daemons running on 
individual servers that are responsible for changing the DVFS state of their CPUs as prescribed in these messages. 
Individual servers must run a modified Xen kernel (see below) to allow these user-space daemons to change DVFS states. 

Current servers have the capability to throttle the CPU by exploiting: 

(i)  Dynamic Voltage and Frequency Scaling (DVFS) states (MSR: IA32_PERF_CTL, 0x199)
(ii) Clock Throttling states (MSR: IA32_CLOCK_MODULATION, 0x19a)

=============================================
Determining the DVFS states of your system:
=============================================

The voltages and frequencies used in the code below are
specific to our server. For your server, you can obtain voltages and
frequencies by reading the appropriate MSR registers.

The code for obtaining voltage and frequency for any Intel processor 
will be provided soon on this Web page.

=========================
Power monitoring and enforcer on PDU 
=========================

DOWNLOAD THE CODE HERE: 
	PowerBudget.tar.gz

TO COMPILE:
	make -f Makefile.rdvfs rdvfs_client

TO RUN: 
	./rdvfs_client watermark watermark_time power_budget  time_limit

======================================
Power budget enforcer on a server
======================================

DOWNLOAD THE CODE HERE: 
	rdvfs_server.tar.gz

TO COMPILE:
        make -f Makefile.rdvfs rdvfs_server 

TO RUN:
	./rdfvfs_server

================================
Xen patch to enable MSR writes 
================================

Make sure this patch is applied to the Xen kernel running on individual servers: 
Xen patch