Quick study of MII Server utilization. We have two servers running MII applicaiton. This report contains data for one server only
Initial steps include: 1. Setting up working directory 2. Clearning memory 3. Loading data into R
# setting working directory and removing all objects from memory
setwd("C:/Users/singhvp/OneDrive - Kennametal Inc- 2/R/MII")
rm(list=ls())
library(lubridate)
package ‘lubridate’ was built under R version 3.2.5
Attaching package: ‘lubridate’
The following object is masked from ‘package:base’:
date
# reading data files from 3 different sites
df = read.csv("ChartData.csv", header=TRUE, stringsAsFactors = FALSE)
In next step, we would like to take a sneek peak of what this data looks like We can do that by running str() and summary() functions
str(df)
'data.frame': 904 obs. of 3 variables:
$ Date: chr "4-Oct-16" "4-Oct-16" "4-Oct-16" "4-Oct-16" ...
$ Time: chr "12:00 AM" "1:00 AM" "2:00 AM" "3:00 AM" ...
$ Uti : num 75.5 76.2 76.4 76.1 76 ...
summary(df)
Date Time Uti
Length:904 Length:904 Min. :13.07
Class :character Class :character 1st Qu.:40.77
Mode :character Mode :character Median :76.21
Mean :59.29
3rd Qu.:78.08
Max. :81.79
Looking at data frame df, we know we need to convert Date to right format and break the data into two chunks - before upgrade and after upgrade
Mr. Barry informed upgrade happened on Oct 23, 2016. So we will divide data in two chunks, one before the upgrade and another after upgrade to analyze them separately
df$Date = as.Date(df$Date, "%d-%b-%y")
df$Uti = round(df[,'Uti'],1) # to limit decimal values
df1 = subset(df, df$Date > "2016-10-23")
df2 = subset(df, df$Date <= "2016-10-23")
To ensure if Dates are formatted properly, we will run str() again
str(df)
'data.frame': 904 obs. of 3 variables:
$ Date: Date, format: "2016-10-04" "2016-10-04" "2016-10-04" "2016-10-04" ...
$ Time: chr "12:00 AM" "1:00 AM" "2:00 AM" "3:00 AM" ...
$ Uti : num 75.5 76.2 76.4 76.1 76 76 76 76.1 76.2 76.4 ...
Now the data is in right format, lets analyze if we see improvement in server utilization
Before upgrade:
boxplot(df2$Uti, axes = FALSE, staplewax = 1, outline = FALSE)
text(y=boxplot.stats(df2$Uti)$stats, labels=boxplot.stats(df2$Uti)$stats, x = 1.25)
After Upgrade
So we see a significant decrease in memory utilization after we doubled the server capacity. This is good news for all production sites using MII