Electrical and Computer Engineering Department  Fairfield University MASTERS THESIS DEFENSE 

54
Fairfield University Electrical and Computer Engineering Electrical and Computer Engineering Department Department Fairfield University Fairfield University MASTERS THESIS DEFENSE MASTERS THESIS DEFENSE Project: Project: The Initium Remote Job The Initium Remote Job Submission Screensaver Submission Screensaver By By Francisco Castellanos Francisco Castellanos Advisor: Professor Douglas A. Lyon, Ph.D. Advisor: Professor Douglas A. Lyon, Ph.D.

description

Electrical and Computer Engineering Department  Fairfield University MASTERS THESIS DEFENSE  Project: The Initium Remote Job Submission Screensaver By Francisco Castellanos Advisor: Professor Douglas A. Lyon, Ph.D. Outline Overview of a grid system Problem statement - PowerPoint PPT Presentation

Transcript of Electrical and Computer Engineering Department  Fairfield University MASTERS THESIS DEFENSE 

Page 1: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Electrical and Computer Engineering Department  Electrical and Computer Engineering Department 

Fairfield UniversityFairfield University  MASTERS THESIS DEFENSE MASTERS THESIS DEFENSE 

  

Project:Project: The Initium Remote Job The Initium Remote Job Submission ScreensaverSubmission Screensaver

ByBy  

Francisco CastellanosFrancisco Castellanos

Advisor: Professor Douglas A. Lyon, Ph.D.Advisor: Professor Douglas A. Lyon, Ph.D.

Page 2: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 3: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

What is grid computing?What is grid computing?

• It is a parallel computing model

Page 4: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Why use grid computing?Why use grid computing?

• It takes advantage networked computers

• It executes tasks in parallel

• It is FAST

Page 5: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Task 1

Task 2

Task 3

Task 4

Task ..

Task n Network 2

Network 1

Page 6: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Basic Research GoalBasic Research Goal

• Make grid computing a little easier

Page 7: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

What is a screen saver?What is a screen saver?

• A program that wakes up when the computer is idle.

• A program that terminates when the computer is busy.

Page 8: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Why use a screen saver?Why use a screen saver?

• Screensavers are a minimal invasive technology that can be used to volunteer CPU cycles.

• Typically, computers are used between 40 and 60 hours out of a 168-hour week. (~ 35% utilization).

Page 9: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 10: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Problem StatementProblem Statement

• Given a Network Of Workstations (NOW)

• Find a way of doing grid computing that is easier

• Subject to the constraints:– non-invasive process– Portable solution

Page 11: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Task 1

Task 2

Task 3

Task ..

Task nNetwork

Compute ServersLookup ServerWeb Server

The Initium RJS System

Page 12: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Problem StatementProblem Statement

• Idleness detection

• Minimize intrusion into the desktop.

• Portable screensaver

Page 13: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Lookup ServerUser PC

Inactive Invoke SS

Invoke CSRegister with LUS

No

Yes

ScreensaverScreensaver PC is still InactiveTerminate

CS

Yes

No

Page 14: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

CSCS

Jobs to execute

Execute Job

Yes

No

Send Answer

Send Job

Lookup Server

Page 15: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Motivation

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 16: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

MotivationMotivation

• Use otherwise idle resources

• Inspired by SETI

• A Java-based screen saver for grid computing is NEW.

Page 17: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Motivation

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 18: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ApproachApproach

Intrusion Minimization

Screensaver Portability

Screensaver Deployment

Screensaver Integration with IRJS middleware

User-PC quiet time detection

Page 19: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Motivation

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 20: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Inactivity DetectionUser-PC Inactivity Detection

• This process is a platform-specific activity.• SaverBeans Screensaver SDK framework,

under the Java.net group.

ProcessingUser Inactivity

Idleness

User Activity

Page 21: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

SaverBeans SDK:

• Java-based framework.

• Provides native subroutines to invoke Java methods in the screensaver.

Page 22: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

…public class RJSsaver extends SimpleScreensaver {

public void init(){…}

public void paint( Graphics g ) {…}

public void destroy() {…}

}

Page 23: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

public void init() {

iCount = iCount + 1;

if (iCount < 2){

startComputeServer();

launchLogMonitor();

}

}

Page 24: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

Page 25: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

Lookup ServerUser PC

Inactive Invoke SS

Invoke CSRegister with LUS

No

Yes

Page 26: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

Page 27: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

User-PC Quite Time DetectionUser-PC Quite Time Detection

Page 28: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ApproachApproach

Intrusion Minimization

Screensaver Portability

Screensaver Deployment

Screensaver Integration with IRJS middleware

User-PC quiescence detection

Page 29: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Intrusion MinimizationIntrusion Minimization

• Resource restoration to its initial state.

• Cleanup and communication with LUS.

Processing

User Inactivity

Idleness

User Activity

Processing Jobs

Join the grid

Page 30: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Intrusion MinimizationIntrusion Minimization

SaverBeans SDK destroy method:protected void destroy(){

cal= Calendar.getInstance();

killFile.mkdir();

System.out.println("CS Stoping at "+ cal.getTime().toString());

}

Page 31: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Intrusion MinimizationIntrusion Minimization

Task 1

Task 2

Task 3

Task 4

Task ..

Task n

CS 1

CS 2

CS 3

CS 4

CS ..

CS n

Page 32: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Intrusion MinimizationIntrusion Minimization

Leasing Process:

ProcessingJob

Available

Job Completion

Send signal

Available Busy/Avail. Dead

No response

Send job

Send response

Page 33: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ApproachApproach

Intrusion Minimization

Screensaver Portability

Screensaver Deployment

Screensaver Integration with IRJS middleware

User-PC quiescence detection

Page 34: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver PortabilityScreensaver Portability

Macintosh Solution:

• Creation of a Objective C program as the screensaver.

• Invokes Java Classes.

Page 35: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver PortabilityScreensaver Portability

(void)animateOneFrame { …

if(i==0){

NSLog(@" First time   %d      SS start now", i);

//Call to java class to start CS

[NSClassFromString(@"RunCS")

newWithSignature:@"(Ljava/lang/String;)",@"start"];

}

Page 36: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver PortabilityScreensaver Portability

(void)stopAnimation

{

//Call to java class to stop CS [NSClassFromString(@"RunCS")

newWithSignature:@"(Ljava/lang/String;)",@"stop"];

NSLog(@"SS  stop now %d  ", i); }

Page 37: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ApproachApproach

Intrusion Minimization

Screensaver Portability

Screensaver Deployment

Screensaver Integration with IRJS middleware

User-PC quiescence detection

Page 38: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver DeploymentScreensaver Deployment

Involved:

• Screensaver Installer

• Java Web Start

• Configuration

Page 39: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver DeploymentScreensaver Deployment

1 . D o w n lo ad an d lo ad J W S s creen s av er in s t aller

W e b Se rv e r 1 W e b Se rv e r 2

Lo o k u p Se rv e r

B eam o v er s creen s av er d is t rib u t ab le f iles , an d in s t all an d co n figu re SS

U s e r PC / CS

L au n ch C o m p u t e Serv er an d d is co v er t o L U S

E xecu t e s creen s av er an d d o w n lo ad an d lau n ch J W S C o m p u t e Serv er

P u s h co m p u t ab le jo b s t o b e execu t ed

4

3

21

6

P u ll J N L P lin k s fo r co m p u t ab le jo b s

5

Page 40: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver DeploymentScreensaver DeploymentOperating System Identification:public static boolean isWindows(String str) { if (isWindows()) { String os =

getOsName().toLowerCase(); if (os.indexOf(str) > -1) return

true; } return false; }public static boolean isWindowsXp() { return isWindows("xp"); }

Page 41: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver DeploymentScreensaver Deployment

Beam Over Screensaver resources:

public static void downloadScreenSaverJar(File outputJarFile, String urlStr) throws IOException {

URL screenSaverUrl = getResourceUrl(urlStr);

UrlUtils.getUrl(screenSaverUrl, outputJarFile);

}

Page 42: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver DeploymentScreensaver DeploymentConfiguration:• Win: Version sensitive directories

– For Windows 98: C:/windows/system/.– For Windows NT: C:/winnt/system/.– For other version: C:/windows/sytem32/.

• Unix:– Xscreensaver Configuration + User dir

• Mac:– Location. (~/Library/Screensavers/)

Page 43: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver DeploymentScreensaver Deployment

Page 44: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ApproachApproach

Intrusion Minimization

Screensaver Portability

Screensaver Deployment

Screensaver Integration with IRJS middleware

User-PC quiescence detection

Page 45: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver IRJS IntegrationScreensaver IRJS Integration

Submitting Jobs to the IRJS System:

• Written in Java

• Main() method in class to execute

• Independent of user input

• Do not use any GUI

• Deployed as Java Web Start

• Output is written to .jar file.

Page 46: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver IRJS IntegrationScreensaver IRJS Integration

public class FractalsJob_1 {

public static void main(String[] args) {

Point from = new Point(0, 0);

Point to = new Point(400, from.y + 100);

Utils.computeStrip(from, to, "Fractals_out1.ppm.jar");

}

}

Page 47: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver IRJS IntegrationScreensaver IRJS Integration

Page 48: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Screensaver IRJS IntegrationScreensaver IRJS Integration

Page 49: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 50: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

OutlineOutline

• Overview of a grid system

• Problem statement

• Approach to solve the problem

• Execution

• Project Demonstration

• Conclusion

Page 51: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ConclusionConclusion

Experiment #Experiment

Desc. Computers Number of Jobs Total Processing Time

1 One CS A 8 2m 53 sec

2 Two CS(s) A, B 8 1m 7 sec

3 Three CS(s) A, B, C 8 1 m 2 sec

4 Four CS(s) A, B, C, D 8 50 sec

Experimental Results:

Page 52: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ConclusionConclusionIRJS System Experimental Results

0

20

40

60

80

100

120

140

160

180

200

1 2 3 4

Compute Servers

To

tal P

rocessin

g T

ime S

ec. .

Page 53: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

ConclusionConclusion

Future Work :

• Mac implementation with SaverBeans

• Tasks-resource matching. Current: first-come first-serve

• Improved interface to submit jobs to IRJS.

• Job partitioning. Current: manual

Page 54: Electrical and Computer Engineering Department   Fairfield University MASTERS THESIS DEFENSE 

Fairfield University

Q/AQ/A